diff options
author | Richard Moe Gustavsen <richard.gustavsen@nokia.com> | 2009-10-13 12:54:39 (GMT) |
---|---|---|
committer | Richard Moe Gustavsen <richard.gustavsen@nokia.com> | 2009-10-13 12:55:59 (GMT) |
commit | be3d1e0a4fc2c39ba87f4f065942bd3418fb351e (patch) | |
tree | e9c1ebefb1303273633e47fccb75b547d6610c07 /src/gui | |
parent | 0d2fd0077258ca125ee6f4e00cefd3f5ed1fff15 (diff) | |
download | Qt-be3d1e0a4fc2c39ba87f4f065942bd3418fb351e.zip Qt-be3d1e0a4fc2c39ba87f4f065942bd3418fb351e.tar.gz Qt-be3d1e0a4fc2c39ba87f4f065942bd3418fb351e.tar.bz2 |
Mac: small bugfix to the mac gesture implementation
Make sure that we cancel the pan gesture if the user starts
to press several fingers on the trackpad, and the gesture has
not yet got a chance to start
Rev-By: trustme
Diffstat (limited to 'src/gui')
-rw-r--r-- | src/gui/kernel/qmacgesturerecognizer_mac.mm | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/gui/kernel/qmacgesturerecognizer_mac.mm b/src/gui/kernel/qmacgesturerecognizer_mac.mm index 210d00b..7b19a54 100644 --- a/src/gui/kernel/qmacgesturerecognizer_mac.mm +++ b/src/gui/kernel/qmacgesturerecognizer_mac.mm @@ -223,6 +223,12 @@ QMacPanGestureRecognizer::filterEvent(QGesture *gesture, QObject *target, QEvent _lastPos = p; return QGestureRecognizer::GestureTriggered; } + } else if (_panTimer.isActive()) { + // I only want to cancel the pan if the user is pressing + // more than one finger, and the pan hasn't started yet: + _panCanceled = true; + _panTimer.stop(); + return QGestureRecognizer::NotGesture; } break;} case QEvent::Timer: { |