// Created: 01.06.01
// RCS-ID: $Id$
// Copyright: (c) 2001 Vadim Zeitlin <zeitlin@dptmaths.ens-cachan.fr>
-// License: wxWindows license
+// License: wxWindows licence
///////////////////////////////////////////////////////////////////////////////
// ============================================================================
// wxEventLoop implementation
// ============================================================================
+wxEventLoop *wxEventLoop::ms_activeLoop = NULL;
+
// ----------------------------------------------------------------------------
// wxEventLoop running and exiting
// ----------------------------------------------------------------------------
wxCHECK_MSG( !IsRunning(), -1, _T("can't reenter a message loop") );
m_impl = new wxEventLoopImpl;
+
+ wxEventLoop *oldLoop = ms_activeLoop;
+ ms_activeLoop = this;
for ( ;; )
{
delete m_impl;
m_impl = NULL;
+ ms_activeLoop = oldLoop;
+
return exitcode;
}