#include "wx/osx/private.h"
#include "wx/evtloop.h"
-extern wxList wxModalDialogs;
-
void wxDialog::EndWindowModal()
{
// Nothing to do for now.
}
-void wxDialog::ShowWindowModal()
+void wxDialog::DoShowWindowModal()
{
// If someone wants to add support for this to wxOSX Carbon, here would
// be the place to start: http://trac.wxwidgets.org/ticket/9459
// Unfortunately, supporting sheets in Carbon isn't as straightforward
// as with Cocoa, so it will probably take some tweaking.
- wxDialogBase::ShowWindowModal();
+
+ m_modality = wxDIALOG_MODALITY_APP_MODAL;
+ ShowModal();
+ SendWindowModalDialogEvent ( wxEVT_WINDOW_MODAL_DIALOG_CLOSED );
}
void wxDialog::DoShowModal()
{
- wxCHECK_RET( !IsModal(), wxT("DoShowModal() called twice") );
-
- wxModalDialogs.Append(this);
SetFocus() ;