]> git.saurik.com Git - wxWidgets.git/blobdiff - src/msw/app.cpp
smoother time estimation updates in wxProgressDialog (patch 992813)
[wxWidgets.git] / src / msw / app.cpp
index 72221a117c387f2092d9bc663ce380d22cabd77c..bcbe186896958c81903345463ae4909ec1e29836 100644 (file)
@@ -185,7 +185,7 @@ void wxGUIAppTraits::AfterChildWaitLoop(void *dataOrig)
 {
     wxEndBusyCursor();
 
-    const ChildWaitLoopData * const data = (ChildWaitLoopData *)dataOrig;
+    ChildWaitLoopData * const data = (ChildWaitLoopData *)dataOrig;
 
     delete data->wd;
 
@@ -193,6 +193,9 @@ void wxGUIAppTraits::AfterChildWaitLoop(void *dataOrig)
     // the other windows reenabled, the activation is going to return to the
     // window which had had it before
     data->winActive->Destroy();
+
+    // also delete the temporary data object itself
+    delete data;
 }
 
 bool wxGUIAppTraits::DoMessageFromThreadWait()
@@ -625,8 +628,7 @@ void wxApp::OnQueryEndSession(wxCloseEvent& event)
 /* static */
 int wxApp::GetComCtl32Version()
 {
-//FIX ME FOR DIGITALMARS!!
-#if defined(__WXMICROWIN__) || defined(__WXWINCE__) || defined(__DIGITALMARS__)
+#if defined(__WXMICROWIN__) || defined(__WXWINCE__)
     return 0;
 #else
     // cache the result
@@ -800,3 +802,33 @@ terminate the program,\r\n\
 }
 
 #endif // wxUSE_EXCEPTIONS
+
+// ----------------------------------------------------------------------------
+// deprecated event loop functions
+// ----------------------------------------------------------------------------
+
+#if WXWIN_COMPATIBILITY_2_4
+
+#include "wx/evtloop.h"
+
+void wxApp::DoMessage(WXMSG *pMsg)
+{
+    wxEventLoop *evtLoop = wxEventLoop::GetActive();
+    if ( evtLoop )
+        evtLoop->ProcessMessage(pMsg);
+}
+
+bool wxApp::DoMessage()
+{
+    wxEventLoop *evtLoop = wxEventLoop::GetActive();
+    return evtLoop ? evtLoop->Dispatch() : false;
+}
+
+bool wxApp::ProcessMessage(WXMSG* pMsg)
+{
+    wxEventLoop *evtLoop = wxEventLoop::GetActive();
+    return evtLoop && evtLoop->PreProcessMessage(pMsg);
+}
+
+#endif // WXWIN_COMPATIBILITY_2_4
+