]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk1/app.cpp
added untyped Sort() for compatibility
[wxWidgets.git] / src / gtk1 / app.cpp
index f51c92ff70b5cde5de6ec7a15ba0471bdcd92de7..22643c5c5e3b6aae2b61ef60e8e038815fb21606 100644 (file)
@@ -323,30 +323,14 @@ void wxApp::CommonInit(void)
 
   wxInitializeResourceSystem();
 
-  // For PostScript printing
-#if wxUSE_POSTSCRIPT
-/* Now done in wxPostScriptModule
-  wxInitializePrintSetupData();
-  wxThePrintPaperDatabase = new wxPrintPaperDatabase;
-  wxThePrintPaperDatabase->CreateDatabase();
- */
-#endif
-
-
-/*
-  wxBitmap::InitStandardHandlers();
-
-  g_globalCursor = new wxCursor;
-*/
+  wxImage::InitStandardHandlers();
+  
+//  g_globalCursor = new wxCursor;
 }
 
 void wxApp::CommonCleanUp(void)
 {
   wxDELETE(wxTheColourDatabase);
-/* Now done in wxPostScriptModule
-  wxDELETE(wxThePrintPaperDatabase);
-  wxDELETE(wxThePrintSetupData);
- */
   wxDELETE(wxTheFontNameDirectory);
   wxDeleteStockObjects();
 
@@ -357,6 +341,8 @@ void wxApp::CommonCleanUp(void)
   wxDeleteStockLists();
 
   wxCleanUpResourceSystem();
+  
+  wxImage::CleanUpHandlers();
 
   wxSystemSettings::Done();
 }
@@ -376,13 +362,14 @@ int wxEntry( int argc, char *argv[] )
 
   wxClassInfo::InitializeClasses();
 
-#if (WXDEBUG && wxUSE_MEMORY_TRACING) || wxUSE_DEBUG_CONTEXT
+  /* Debug stream no longer used
+#if (defined(__WXDEBUG__) && wxUSE_MEMORY_TRACING) || wxUSE_DEBUG_CONTEXT
 
   streambuf* sBuf = new wxDebugStreamBuf;
   ostream* oStr = new ostream(sBuf) ;
   wxDebugContext::SetStream(oStr, sBuf);
-
 #endif
+*/
 
   if (!wxTheApp)
   {
@@ -459,25 +446,26 @@ int wxEntry( int argc, char *argv[] )
 
   wxDELETE(wxTheApp);
 
-  wxLog *oldLog = wxLog::SetActiveTarget( NULL );
-  if (oldLog) delete oldLog;
-  
   wxClassInfo::CleanUpClasses();
   
   delete[] wxBuffer;
   
-#if (WXDEBUG && wxUSE_MEMORY_TRACING) || wxUSE_DEBUG_CONTEXT
+#if (defined(__WXDEBUG__) && wxUSE_MEMORY_TRACING) || wxUSE_DEBUG_CONTEXT
   
   if (wxDebugContext::CountObjectsLeft() > 0)
   {
-    wxTrace("There were memory leaks.\n");
+    wxLogDebug("There were memory leaks.\n");
     wxDebugContext::Dump();
     wxDebugContext::PrintStatistics();
   }
-  wxDebugContext::SetStream(NULL, NULL);
+//  wxDebugContext::SetStream(NULL, NULL);
   
 #endif
 
+  wxLog *oldLog = wxLog::SetActiveTarget( NULL );
+  if (oldLog) delete oldLog;
+
+
   return retValue;
 }