// virtual bool Destroy();
virtual bool Show(bool show = true);
- void SetModal(bool flag);
+ // return true if we're showing the dialog modally
virtual bool IsModal() const;
- // For now, same as Show(TRUE) but returns return code
+ // show the dialog modally and return the value passed to EndModal()
virtual int ShowModal();
+
+ virtual void ShowWindowModal();
// may be called to terminate the dialog with the given return code
virtual void EndModal(int retCode);
// implementation
// --------------
+ wxDialogModality GetModality() const;
+
+#if wxOSX_USE_COCOA
+ virtual void ModalFinishedCallback(void* WXUNUSED(panel), int WXUNUSED(returnCode)) {}
+#endif
+
+protected:
// show modal dialog and enter modal loop
void DoShowModal();
+
+ // show modal dialog and enter modal loop
+ void DoShowWindowModal();
-protected:
// mac also takes command-period as cancel
virtual bool IsEscapeKey(const wxKeyEvent& event);
+ // needed for cleanup on the Cocoa side.
+ void EndWindowModal();
+
+ wxDialogModality m_modality;
+
private:
void Init();
-
- bool m_isModalStyle;
};
#endif