X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/655719367ac5e131d9642e5783f3ecf64d1a3385..71cc158eaabaeac51b6219a9df8eac06b96c794b:/src/mac/carbon/msgdlg.cpp diff --git a/src/mac/carbon/msgdlg.cpp b/src/mac/carbon/msgdlg.cpp index 73548ad9f2..e0f43288d4 100644 --- a/src/mac/carbon/msgdlg.cpp +++ b/src/mac/carbon/msgdlg.cpp @@ -9,10 +9,12 @@ // Licence: wxWindows licence ///////////////////////////////////////////////////////////////////////////// -#ifdef __GNUG__ +#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) #pragma implementation "msgdlg.h" #endif +#include "wx/wxprec.h" + #include "wx/app.h" #include "wx/msgdlg.h" #include "wx/intl.h" @@ -61,6 +63,7 @@ int wxMessageDialog::ShowModal() param.movable = true; param.flags = 0 ; + param.version = kStdCFStringAlertVersionOne ; bool skipDialog = false ; @@ -72,7 +75,7 @@ int wxMessageDialog::ShowModal() param.cancelText = (CFStringRef) kAlertDefaultCancelText; param.otherText = cfNoString ; param.helpButton = false ; - param.defaultButton = kAlertStdAlertOKButton; + param.defaultButton = m_dialogStyle & wxNO_DEFAULT ? kAlertStdAlertOtherButton : kAlertStdAlertOKButton; param.cancelButton = kAlertStdAlertCancelButton; } else @@ -81,7 +84,7 @@ int wxMessageDialog::ShowModal() param.cancelText = NULL; param.otherText = cfNoString ; param.helpButton = false ; - param.defaultButton = kAlertStdAlertOKButton; + param.defaultButton = m_dialogStyle & wxNO_DEFAULT ? kAlertStdAlertOtherButton : kAlertStdAlertOKButton; param.cancelButton = 0; } }