summaryrefslogtreecommitdiffstats
path: root/src/plugins
diff options
context:
space:
mode:
authorTor Arne Vestbø <tor.arne.vestbo@qt.io>2018-04-09 15:46:14 +0200
committerTor Arne Vestbø <tor.arne.vestbo@qt.io>2018-05-29 10:53:10 +0000
commitdc55000140f394af74d1ca40fa9804e780b867e5 (patch)
treebf21d8f20eec1ca0a0a2225c59acb21c193af00b /src/plugins
parent6b98d9767022465d2ee239fe023b2ceb67d36911 (diff)
iOS: Don't assume our UIWindow is a QUIWindow
Change-Id: I6494e4a476273b131aedcf409abdb1ffffa5b62e Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io> (cherry picked from commit ab9b026d2734321f1d5a06b79f97107a867687c3)
Diffstat (limited to 'src/plugins')
-rw-r--r--src/plugins/platforms/ios/quiview.mm3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/plugins/platforms/ios/quiview.mm b/src/plugins/platforms/ios/quiview.mm
index 29afae7176..8db36705c0 100644
--- a/src/plugins/platforms/ios/quiview.mm
+++ b/src/plugins/platforms/ios/quiview.mm
@@ -440,7 +440,8 @@ Q_LOGGING_CATEGORY(lcQpaTablet, "qt.qpa.input.tablet")
if (m_activeTouches.isEmpty())
return;
- if (!static_cast<QUIWindow *>(self.window).sendingEvent) {
+ if ([self.window isKindOfClass:[QUIWindow class]] &&
+ !static_cast<QUIWindow *>(self.window).sendingEvent) {
// The event is likely delivered as part of delayed touch delivery, via
// _UIGestureEnvironmentSortAndSendDelayedTouches, due to one of the two
// _UISystemGestureGateGestureRecognizer instances on the top level window