aboutsummaryrefslogtreecommitdiffstats
path: root/src/quick/handlers/qquickmultipointhandler.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/quick/handlers/qquickmultipointhandler.cpp')
-rw-r--r--src/quick/handlers/qquickmultipointhandler.cpp13
1 files changed, 7 insertions, 6 deletions
diff --git a/src/quick/handlers/qquickmultipointhandler.cpp b/src/quick/handlers/qquickmultipointhandler.cpp
index ff4914394c..b126b93211 100644
--- a/src/quick/handlers/qquickmultipointhandler.cpp
+++ b/src/quick/handlers/qquickmultipointhandler.cpp
@@ -298,17 +298,18 @@ void QQuickMultiPointHandler::acceptPoints(const QVector<QQuickEventPoint *> &po
bool QQuickMultiPointHandler::grabPoints(QVector<QQuickEventPoint *> points)
{
- bool canGrab = true;
+ bool allowed = true;
for (QQuickEventPoint* point : points) {
- auto grabber = point->grabberItem();
- if (grabber && (grabber->keepMouseGrab() || grabber->keepTouchGrab()))
- canGrab = false;
+ if (!canGrab(point)) {
+ allowed = false;
+ break;
+ }
}
- if (canGrab) {
+ if (allowed) {
for (QQuickEventPoint* point : points)
setExclusiveGrab(point);
}
- return canGrab;
+ return allowed;
}
QT_END_NAMESPACE