summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms/cocoa/qcocoaeventdispatcher.mm
diff options
context:
space:
mode:
authorTor Arne Vestbø <tor.arne.vestbo@qt.io>2017-06-26 16:29:19 +0200
committerTimur Pocheptsov <timur.pocheptsov@qt.io>2017-06-29 10:13:39 +0000
commit85cbd3517826b28b429f4239158512e14c009f9a (patch)
treea0497f02e91eb722bbfe2008345fcf5c54888dae /src/plugins/platforms/cocoa/qcocoaeventdispatcher.mm
parentc888d302bc4ae3b2970c6db188c7276b3c831cc7 (diff)
macOS: Remove workaround for queued input events to stale windows
We now track the platform window with a QPointer, so the event callbacks can (and do) check the validity of the platform window before passing them on. The window property of the NSView is also nil at the point of even delivery, if we need another way to check if the event is still valid. Task-number: QTBUG-39211 Change-Id: I6179bdb3af9606cd0abf981c0fe6cacb9a2d98ab Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Diffstat (limited to 'src/plugins/platforms/cocoa/qcocoaeventdispatcher.mm')
-rw-r--r--src/plugins/platforms/cocoa/qcocoaeventdispatcher.mm15
1 files changed, 0 insertions, 15 deletions
diff --git a/src/plugins/platforms/cocoa/qcocoaeventdispatcher.mm b/src/plugins/platforms/cocoa/qcocoaeventdispatcher.mm
index cc63213904..874d3fc24b 100644
--- a/src/plugins/platforms/cocoa/qcocoaeventdispatcher.mm
+++ b/src/plugins/platforms/cocoa/qcocoaeventdispatcher.mm
@@ -889,21 +889,6 @@ void QCocoaEventDispatcherPrivate::processPostedEvents()
}
}
-void QCocoaEventDispatcherPrivate::removeQueuedUserInputEvents(int nsWinNumber)
-{
- if (nsWinNumber) {
- int eventIndex = queuedUserInputEvents.size();
-
- while (--eventIndex >= 0) {
- NSEvent * nsevent = static_cast<NSEvent *>(queuedUserInputEvents.at(eventIndex));
- if ([nsevent windowNumber] == nsWinNumber) {
- queuedUserInputEvents.removeAt(eventIndex);
- [nsevent release];
- }
- }
- }
-}
-
void QCocoaEventDispatcherPrivate::firstLoopEntry(CFRunLoopObserverRef ref,
CFRunLoopActivity activity,
void *info)