X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/937013e0fd914d4c42f9f5ec98da665986b93dfa..f2a18fbec6f74bcb7957392f6e71982c8ca54568:/src/motif/evtloop.cpp diff --git a/src/motif/evtloop.cpp b/src/motif/evtloop.cpp index fa1db8c84c..a3994827f8 100644 --- a/src/motif/evtloop.cpp +++ b/src/motif/evtloop.cpp @@ -20,11 +20,6 @@ // For compilers that support precompilation, includes "wx.h". #include "wx/wxprec.h" -#ifdef __VMS -#define XtParent XTPARENT -#define XtDisplay XTDISPLAY -#endif - #ifndef WX_PRECOMP #include "wx/event.h" #include "wx/app.h" @@ -33,6 +28,7 @@ #endif //WX_PRECOMP #include "wx/evtloop.h" +#include "wx/thread.h" #ifdef __VMS__ #pragma message disable nosimpint @@ -141,6 +137,20 @@ void wxGUIEventLoop::Exit(int rc) ::wxBreakDispatch(); } +bool wxGUIEventLoop::YieldFor(long eventsToProcess) +{ + m_isInsideYield = true; + m_eventsToProcessInsideYield = eventsToProcess; + + while (wxTheApp && wxTheApp->Pending()) + // TODO: implement event filtering using the eventsToProcess mask + wxTheApp->Dispatch(); + + m_isInsideYield = false; + + return true; +} + // ---------------------------------------------------------------------------- // wxEventLoop message processing dispatching // ----------------------------------------------------------------------------