+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;
+}
+