]> git.saurik.com Git - wxWidgets.git/blobdiff - src/motif/toplevel.cpp
compilation fix for Mac and reformatted the code
[wxWidgets.git] / src / motif / toplevel.cpp
index 8b54b2175c7239e9f0ce93f74166dd698d1123a5..9ce63d5fd62e94464337a4092f330885ade4129e 100644 (file)
@@ -66,8 +66,6 @@ static void wxTLWEventHandler( Widget wid,
 
 void wxTopLevelWindowMotif::PreDestroy()
 {
-    wxTopLevelWindows.DeleteObject(this);
-
     if ( (GetWindowStyleFlag() & wxDIALOG_MODAL) != wxDIALOG_MODAL )
         wxModelessWindows.DeleteObject(this);
 
@@ -90,17 +88,6 @@ void wxTopLevelWindowMotif::PreDestroy()
 wxTopLevelWindowMotif::~wxTopLevelWindowMotif()
 {
     SetMainWidget( (WXWidget)0 );
-
-    // If this is the last top-level window, exit.
-    if (wxTheApp && (wxTopLevelWindows.GetCount() == 0))
-    {
-        wxTheApp->SetTopWindow(NULL);
-
-        if (wxTheApp->GetExitOnFrameDelete())
-        {
-            wxTheApp->ExitMainLoop();
-        }
-    }
 }
 
 void wxTopLevelWindowMotif::Init()