]> git.saurik.com Git - wxWidgets.git/commitdiff
Fixes Bug [ 930200 ] Async does not work
authorRobin Dunn <robin@alldunn.com>
Tue, 27 Apr 2004 20:02:41 +0000 (20:02 +0000)
committerRobin Dunn <robin@alldunn.com>
Tue, 27 Apr 2004 20:02:41 +0000 (20:02 +0000)
Because the wxConsoleAppTraits was being created for GUI apps
wxExecute would fail if the wxEXEC_ASYNC flags was used.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@26991 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/common/appbase.cpp

index a0d2dd9157fbff0cf04af1c9b52d9a3a33363c11..2917c634c1060ff2b873d6214c96f9bfdb6eb7d9 100644 (file)
@@ -109,6 +109,13 @@ wxAppConsole::wxAppConsole()
 
 #ifdef __WXDEBUG__
     SetTraceMasks();
 
 #ifdef __WXDEBUG__
     SetTraceMasks();
+#if wxUSE_UNICODE
+    // In unicode mode the SetTraceMasks call can cause an apptraits to be
+    // created, but since we are still in the constructor the wrong kind will
+    // be created for GUI apps.  Destroy it so it can be created again later.
+    delete m_traits;
+    m_traits = NULL;
+#endif
 #endif
 }
 
 #endif
 }