aboutsummaryrefslogtreecommitdiffstats
path: root/src/quick/handlers/qquicktaphandler.cpp
diff options
context:
space:
mode:
authorShawn Rutledge <shawn.rutledge@qt.io>2017-04-18 09:52:29 +0200
committerShawn Rutledge <shawn.rutledge@qt.io>2017-04-21 13:30:15 +0000
commitdbcc38455369f15920d0e18c9be8d909010d5af8 (patch)
tree87939522ad229af6b6462fa952e2604115908bc6 /src/quick/handlers/qquicktaphandler.cpp
parent11034bd4ab4163797ae9e0dffd110217d2aafdaa (diff)
TapHandler:wants: don't setPressed(false) unless pointId matches
This fixes the multibuttons manual test: the first button would see that a second point was pressed, and that it didn't want it, because it's outside the bounds. This is not a good reason to discontinue responding to the first touchpoint, which is the one it was first interested in. Change-Id: I7004a667873f235d3dda84b4261113d37d911763 Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
Diffstat (limited to 'src/quick/handlers/qquicktaphandler.cpp')
-rw-r--r--src/quick/handlers/qquicktaphandler.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/quick/handlers/qquicktaphandler.cpp b/src/quick/handlers/qquicktaphandler.cpp
index 00bc3e27f0..85188700d9 100644
--- a/src/quick/handlers/qquicktaphandler.cpp
+++ b/src/quick/handlers/qquicktaphandler.cpp
@@ -138,7 +138,7 @@ bool QQuickTapHandler::wantsEventPoint(QQuickEventPoint *point)
// so onGrabChanged(this, CancelGrabExclusive, point) and setPressed(false) will be called.
// But when m_gesturePolicy is DragThreshold, we don't get an exclusive grab, but
// we still don't want to be pressed anymore.
- if (!ret)
+ if (!ret && point->pointId() == pointId())
setPressed(false, true, point);
return ret;
}