Add "OSX" prefix to wxCFEventLoop::DoRun() and DoStop() methods.
Just rename these methods to avoid clashes with DoRun() that will be added to the base class soon, no real changes. This is done in preparation for improving nested event loops support, see #10258. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@74331 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -25,9 +25,8 @@ public:
|
|||||||
protected:
|
protected:
|
||||||
virtual int DoDispatchTimeout(unsigned long timeout);
|
virtual int DoDispatchTimeout(unsigned long timeout);
|
||||||
|
|
||||||
virtual void DoRun();
|
virtual void OSXDoRun();
|
||||||
|
virtual void OSXDoStop();
|
||||||
virtual void DoStop();
|
|
||||||
|
|
||||||
virtual CFRunLoopRef CFGetCurrentRunLoop() const;
|
virtual CFRunLoopRef CFGetCurrentRunLoop() const;
|
||||||
};
|
};
|
||||||
|
@@ -29,9 +29,8 @@ public:
|
|||||||
protected:
|
protected:
|
||||||
virtual int DoDispatchTimeout(unsigned long timeout);
|
virtual int DoDispatchTimeout(unsigned long timeout);
|
||||||
|
|
||||||
virtual void DoRun();
|
virtual void OSXDoRun();
|
||||||
|
virtual void OSXDoStop();
|
||||||
virtual void DoStop();
|
|
||||||
|
|
||||||
virtual CFRunLoopRef CFGetCurrentRunLoop() const;
|
virtual CFRunLoopRef CFGetCurrentRunLoop() const;
|
||||||
|
|
||||||
|
@@ -77,9 +77,8 @@ protected:
|
|||||||
|
|
||||||
virtual int DoDispatchTimeout(unsigned long timeout);
|
virtual int DoDispatchTimeout(unsigned long timeout);
|
||||||
|
|
||||||
virtual void DoRun();
|
virtual void OSXDoRun();
|
||||||
|
virtual void OSXDoStop();
|
||||||
virtual void DoStop();
|
|
||||||
|
|
||||||
// should we exit the loop?
|
// should we exit the loop?
|
||||||
bool m_shouldExit;
|
bool m_shouldExit;
|
||||||
|
@@ -30,9 +30,8 @@ public:
|
|||||||
wxModalEventLoop(WXWindow modalNativeWindow);
|
wxModalEventLoop(WXWindow modalNativeWindow);
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
virtual void DoRun();
|
virtual void OSXDoRun();
|
||||||
|
virtual void OSXDoStop();
|
||||||
virtual void DoStop();
|
|
||||||
|
|
||||||
// (in case) the modal window for this event loop
|
// (in case) the modal window for this event loop
|
||||||
wxNonOwnedWindow* m_modalWindow;
|
wxNonOwnedWindow* m_modalWindow;
|
||||||
|
@@ -93,13 +93,13 @@ void wxGUIEventLoop::WakeUp()
|
|||||||
kEventPriorityHigh );
|
kEventPriorityHigh );
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxGUIEventLoop::DoRun()
|
void wxGUIEventLoop::OSXDoRun()
|
||||||
{
|
{
|
||||||
wxMacAutoreleasePool autoreleasepool;
|
wxMacAutoreleasePool autoreleasepool;
|
||||||
RunApplicationEventLoop();
|
RunApplicationEventLoop();
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxGUIEventLoop::DoStop()
|
void wxGUIEventLoop::OSXDoStop()
|
||||||
{
|
{
|
||||||
QuitApplicationEventLoop();
|
QuitApplicationEventLoop();
|
||||||
}
|
}
|
||||||
@@ -127,7 +127,7 @@ wxModalEventLoop::wxModalEventLoop(WXWindow modalNativeWindow)
|
|||||||
|
|
||||||
// END move into a evtloop_osx.cpp
|
// END move into a evtloop_osx.cpp
|
||||||
|
|
||||||
void wxModalEventLoop::DoRun()
|
void wxModalEventLoop::OSXDoRun()
|
||||||
{
|
{
|
||||||
wxWindowDisabler disabler(m_modalWindow);
|
wxWindowDisabler disabler(m_modalWindow);
|
||||||
wxMacAutoreleasePool autoreleasepool;
|
wxMacAutoreleasePool autoreleasepool;
|
||||||
@@ -163,7 +163,7 @@ void wxModalEventLoop::DoRun()
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxModalEventLoop::DoStop()
|
void wxModalEventLoop::OSXDoStop()
|
||||||
{
|
{
|
||||||
wxMacAutoreleasePool autoreleasepool;
|
wxMacAutoreleasePool autoreleasepool;
|
||||||
QuitAppModalLoopForWindow(m_modalNativeWindow);
|
QuitAppModalLoopForWindow(m_modalNativeWindow);
|
||||||
|
@@ -240,13 +240,13 @@ int wxGUIEventLoop::DoDispatchTimeout(unsigned long timeout)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxGUIEventLoop::DoRun()
|
void wxGUIEventLoop::OSXDoRun()
|
||||||
{
|
{
|
||||||
wxMacAutoreleasePool autoreleasepool;
|
wxMacAutoreleasePool autoreleasepool;
|
||||||
[NSApp run];
|
[NSApp run];
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxGUIEventLoop::DoStop()
|
void wxGUIEventLoop::OSXDoStop()
|
||||||
{
|
{
|
||||||
// only calling stop: is not enough when called from a runloop-observer,
|
// only calling stop: is not enough when called from a runloop-observer,
|
||||||
// therefore add a dummy event, to make sure the runloop gets another round
|
// therefore add a dummy event, to make sure the runloop gets another round
|
||||||
@@ -305,7 +305,7 @@ wxModalEventLoop::wxModalEventLoop(WXWindow modalNativeWindow)
|
|||||||
|
|
||||||
// END move into a evtloop_osx.cpp
|
// END move into a evtloop_osx.cpp
|
||||||
|
|
||||||
void wxModalEventLoop::DoRun()
|
void wxModalEventLoop::OSXDoRun()
|
||||||
{
|
{
|
||||||
wxMacAutoreleasePool pool;
|
wxMacAutoreleasePool pool;
|
||||||
|
|
||||||
@@ -324,7 +324,7 @@ void wxModalEventLoop::DoRun()
|
|||||||
[NSApp runModalForWindow:m_modalNativeWindow];
|
[NSApp runModalForWindow:m_modalNativeWindow];
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxModalEventLoop::DoStop()
|
void wxModalEventLoop::OSXDoStop()
|
||||||
{
|
{
|
||||||
[NSApp abortModal];
|
[NSApp abortModal];
|
||||||
}
|
}
|
||||||
|
@@ -364,7 +364,7 @@ int wxCFEventLoop::DoDispatchTimeout(unsigned long timeout)
|
|||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxCFEventLoop::DoRun()
|
void wxCFEventLoop::OSXDoRun()
|
||||||
{
|
{
|
||||||
for ( ;; )
|
for ( ;; )
|
||||||
{
|
{
|
||||||
@@ -385,7 +385,7 @@ void wxCFEventLoop::DoRun()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxCFEventLoop::DoStop()
|
void wxCFEventLoop::OSXDoStop()
|
||||||
{
|
{
|
||||||
CFRunLoopStop(CFGetCurrentRunLoop());
|
CFRunLoopStop(CFGetCurrentRunLoop());
|
||||||
}
|
}
|
||||||
@@ -414,7 +414,7 @@ int wxCFEventLoop::Run()
|
|||||||
{
|
{
|
||||||
#endif // wxUSE_EXCEPTIONS
|
#endif // wxUSE_EXCEPTIONS
|
||||||
|
|
||||||
DoRun();
|
OSXDoRun();
|
||||||
|
|
||||||
#if wxUSE_EXCEPTIONS
|
#if wxUSE_EXCEPTIONS
|
||||||
// exit the outer loop as well
|
// exit the outer loop as well
|
||||||
@@ -452,7 +452,7 @@ void wxCFEventLoop::Exit(int rc)
|
|||||||
{
|
{
|
||||||
m_exitcode = rc;
|
m_exitcode = rc;
|
||||||
m_shouldExit = true;
|
m_shouldExit = true;
|
||||||
DoStop();
|
OSXDoStop();
|
||||||
}
|
}
|
||||||
|
|
||||||
wxCFEventLoopPauseIdleEvents::wxCFEventLoopPauseIdleEvents()
|
wxCFEventLoopPauseIdleEvents::wxCFEventLoopPauseIdleEvents()
|
||||||
|
@@ -83,7 +83,7 @@ wxGUIEventLoop::wxGUIEventLoop()
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxGUIEventLoop::DoRun()
|
void wxGUIEventLoop::OSXDoRun()
|
||||||
{
|
{
|
||||||
if ( IsMain() )
|
if ( IsMain() )
|
||||||
{
|
{
|
||||||
@@ -93,7 +93,7 @@ void wxGUIEventLoop::DoRun()
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
wxCFEventLoop::DoRun();
|
wxCFEventLoop::OSXDoRun();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -102,9 +102,9 @@ int wxGUIEventLoop::DoDispatchTimeout(unsigned long timeout)
|
|||||||
return wxCFEventLoop::DoDispatchTimeout(timeout);
|
return wxCFEventLoop::DoDispatchTimeout(timeout);
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxGUIEventLoop::DoStop()
|
void wxGUIEventLoop::OSXDoStop()
|
||||||
{
|
{
|
||||||
return wxCFEventLoop::DoStop();
|
return wxCFEventLoop::OSXDoStop();
|
||||||
}
|
}
|
||||||
|
|
||||||
CFRunLoopRef wxGUIEventLoop::CFGetCurrentRunLoop() const
|
CFRunLoopRef wxGUIEventLoop::CFGetCurrentRunLoop() const
|
||||||
@@ -136,12 +136,12 @@ wxModalEventLoop::wxModalEventLoop(WXWindow modalNativeWindow)
|
|||||||
// END move into a evtloop_osx.cpp
|
// END move into a evtloop_osx.cpp
|
||||||
|
|
||||||
|
|
||||||
void wxModalEventLoop::DoRun()
|
void wxModalEventLoop::OSXDoRun()
|
||||||
{
|
{
|
||||||
// presentModalViewController:animated:
|
// presentModalViewController:animated:
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxModalEventLoop::DoStop()
|
void wxModalEventLoop::OSXDoStop()
|
||||||
{
|
{
|
||||||
// (void)dismissModalViewControllerAnimated:(BOOL)animated
|
// (void)dismissModalViewControllerAnimated:(BOOL)animated
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user