]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk1/dialog.cpp
missing commit
[wxWidgets.git] / src / gtk1 / dialog.cpp
index 1646b771cbde9e447009f9106e0277dae0739e08..c760fe0de2699bfc316d3d2d5bf6fa0e6a93c2d7 100644 (file)
@@ -19,6 +19,7 @@
 #endif // WX_PRECOMP
 
 #include "wx/evtloop.h"
+#include "wx/modalhook.h"
 
 #include <gdk/gdk.h>
 #include <gtk/gtk.h>
@@ -137,7 +138,7 @@ void wxDialog::OnCloseWindow(wxCloseEvent& WXUNUSED(event))
 
     s_closing.Append(this);
 
-    wxCommandEvent cancelEvent(wxEVT_COMMAND_BUTTON_CLICKED, wxID_CANCEL);
+    wxCommandEvent cancelEvent(wxEVT_BUTTON, wxID_CANCEL);
     cancelEvent.SetEventObject( this );
     HandleWindowEvent(cancelEvent);
     s_closing.DeleteObject(this);
@@ -182,6 +183,8 @@ void wxDialog::SetModal( bool WXUNUSED(flag) )
 
 int wxDialog::ShowModal()
 {
+    WX_HOOK_MODAL_DIALOG();
+
     if (IsModal())
     {
        wxFAIL_MSG( wxT("wxDialog:ShowModal called twice") );