aboutsummaryrefslogtreecommitdiffstats
path: root/src/quick/items/qquickflickable_p.h
diff options
context:
space:
mode:
authorMatt Vogt <matthew.vogt@jollamobile.com>2012-11-29 08:35:00 +1000
committerThe Qt Project <gerrit-noreply@qt-project.org>2012-11-29 06:39:10 +0100
commitd02131e743597b9bd3070d986c61a1c91ea8317a (patch)
tree03f747e256d3c9d86891786aadee79673a509dbe /src/quick/items/qquickflickable_p.h
parentb68d7ab0a52ea9e94a3e62767357e0c735727969 (diff)
Fix mouse event distribution for Flickable with pressDelay
If an item responds to mouse events but does not accept them, it can prevent the events from being processed by the correct item further up the parent chain. For example, a text item inside a mouse area can wrongly consume a press event, so that the following release event does not yield a click when processed by the mouse area. Rather than speculatively assigning the mouse grab to items during event filter processing, change Flickable to retain the grab for the duration of the pressDelay and to release it during replay of the press event. Change-Id: Ied12b9643838a984c7026978047465c2830e55e4 Reviewed-by: Martin Jones <martin.jones@jollamobile.com>
Diffstat (limited to 'src/quick/items/qquickflickable_p.h')
-rw-r--r--src/quick/items/qquickflickable_p.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/quick/items/qquickflickable_p.h b/src/quick/items/qquickflickable_p.h
index a97af9ce50..d5f97ad963 100644
--- a/src/quick/items/qquickflickable_p.h
+++ b/src/quick/items/qquickflickable_p.h
@@ -257,7 +257,7 @@ protected:
virtual void geometryChanged(const QRectF &newGeometry,
const QRectF &oldGeometry);
void mouseUngrabEvent();
- bool sendMouseEvent(QMouseEvent *event);
+ bool sendMouseEvent(QQuickItem *item, QMouseEvent *event);
bool xflick() const;
bool yflick() const;