// Author: Vadim Zeitlin
// Modified by:
// Created: 2006-01-12
-// RCS-ID: $Id$
// Copyright: (c) 2006 Vadim Zeitlin <vadim@wxwindows.org>
// Licence: wxWindows licence
///////////////////////////////////////////////////////////////////////////////
void wxGUIEventLoop::OSXDoRun()
{
wxMacAutoreleasePool autoreleasepool;
- RunApplicationEventLoop();
+
+ while (!m_shouldExit)
+ {
+ RunApplicationEventLoop();
+ }
+
+ // Force enclosing event loop to temporarily exit and check
+ // if it should be stopped.
+ QuitApplicationEventLoop();
}
void wxGUIEventLoop::OSXDoStop()