]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk/toplevel.cpp
Moved wxConsoleAppTraits::CreateEventLoop from baseunix.cpp to evtloopunix.cpp,
[wxWidgets.git] / src / gtk / toplevel.cpp
index 89a57919786cbf241a16d0aaea8e008ca3c272b8..76c8b4ce1cc6a9accdaf37efa1df915128da0bf7 100644 (file)
@@ -682,8 +682,12 @@ bool wxTopLevelWindowGTK::Create( wxWindow *parent,
 wxTopLevelWindowGTK::~wxTopLevelWindowGTK()
 {
 #if wxUSE_LIBHILDON
-    hildon_program_remove_window(wxTheApp->GetHildonProgram(),
-                                 HILDON_WINDOW(m_widget));
+    // it can also be a (standard) dialog
+    if ( HILDON_IS_WINDOW(m_widget) )
+    {
+        hildon_program_remove_window(wxTheApp->GetHildonProgram(),
+                                     HILDON_WINDOW(m_widget));
+    }
 #endif // wxUSE_LIBHILDON
 
     if (m_grabbed)