diff options
author | Morten Johan Sørvig <morten.sorvig@theqtcompany.com> | 2015-06-30 13:18:57 +0200 |
---|---|---|
committer | Jake Petroules <jake.petroules@theqtcompany.com> | 2015-10-13 22:57:12 +0000 |
commit | b63c3d4d9a8917a84cf24439a0f75a17df0aafee (patch) | |
tree | 51503e1d3fa91bf9772f3ddea12bf26702f0fbe4 /src/platformsupport/eventdispatchers/qeventdispatcher_cf_p.h | |
parent | 967e4f258cd39991fd2d0ac3753544900d51fbc2 (diff) |
Make the CoreFoundation event dispatcher depend on QtCore only
In anticipation of moving it to QtCore.
The call to QWindowSystemInterface::sendWindowSystemEvents() has been
moved to QIOSEventDispatcher by making processPostedEvents() virtual.
Change-Id: I9e03be4153a9f5f34e9a0ac942cdff572a44c318
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
Diffstat (limited to 'src/platformsupport/eventdispatchers/qeventdispatcher_cf_p.h')
-rw-r--r-- | src/platformsupport/eventdispatchers/qeventdispatcher_cf_p.h | 30 |
1 files changed, 16 insertions, 14 deletions
diff --git a/src/platformsupport/eventdispatchers/qeventdispatcher_cf_p.h b/src/platformsupport/eventdispatchers/qeventdispatcher_cf_p.h index 1cd9ae4ebf..2fe5dea3d8 100644 --- a/src/platformsupport/eventdispatchers/qeventdispatcher_cf_p.h +++ b/src/platformsupport/eventdispatchers/qeventdispatcher_cf_p.h @@ -101,7 +101,7 @@ template <class T = QEventDispatcherCoreFoundation> class RunLoopSource { public: - typedef void (T::*CallbackFunction) (); + typedef bool (T::*CallbackFunction)(); enum { kHighestPriority = 0 } RunLoopSourcePriority; @@ -221,18 +221,8 @@ public: void interrupt(); void flush(); -private: - RunLoopSource<> m_postedEventsRunLoopSource; - RunLoopObserver<> m_runLoopActivityObserver; - - RunLoopModeTracker *m_runLoopModeTracker; - - QTimerInfoList m_timerInfoList; - CFRunLoopTimerRef m_runLoopTimer; - CFRunLoopTimerRef m_blockedRunLoopTimer; - bool m_overdueTimerScheduled; - - QCFSocketNotifier m_cfSocketNotifier; +protected: + virtual bool processPostedEvents(); struct ProcessEventsState { @@ -251,7 +241,19 @@ private: ProcessEventsState m_processEvents; - void processPostedEvents(); +private: + RunLoopSource<> m_postedEventsRunLoopSource; + RunLoopObserver<> m_runLoopActivityObserver; + + RunLoopModeTracker *m_runLoopModeTracker; + + QTimerInfoList m_timerInfoList; + CFRunLoopTimerRef m_runLoopTimer; + CFRunLoopTimerRef m_blockedRunLoopTimer; + bool m_overdueTimerScheduled; + + QCFSocketNotifier m_cfSocketNotifier; + void processTimers(CFRunLoopTimerRef); void handleRunLoopActivity(CFRunLoopActivity activity); |