diff options
Diffstat (limited to 'src/quick/handlers')
-rw-r--r-- | src/quick/handlers/qquickwheelhandler.cpp | 4 | ||||
-rw-r--r-- | src/quick/handlers/qquickwheelhandler_p.h | 2 | ||||
-rw-r--r-- | src/quick/handlers/qquickwheelhandler_p_p.h | 1 |
3 files changed, 5 insertions, 2 deletions
diff --git a/src/quick/handlers/qquickwheelhandler.cpp b/src/quick/handlers/qquickwheelhandler.cpp index 563bf16b49..414a41f2cd 100644 --- a/src/quick/handlers/qquickwheelhandler.cpp +++ b/src/quick/handlers/qquickwheelhandler.cpp @@ -405,7 +405,9 @@ void QQuickWheelHandler::handleEventPoint(QPointerEvent *ev, QEventPoint &point) event->angleDelta().y()) / 8; d->rotation += angleDelta; emit rotationChanged(); - emit wheel(*event); + + d->wheelEvent.reset(event); + emit wheel(&d->wheelEvent); if (!d->propertyName.isEmpty() && target()) { QQuickItem *t = target(); // writing target()'s property is done via QMetaProperty::write() so that any registered interceptors can react. diff --git a/src/quick/handlers/qquickwheelhandler_p.h b/src/quick/handlers/qquickwheelhandler_p.h index 25390dc4c4..cbc9c4328c 100644 --- a/src/quick/handlers/qquickwheelhandler_p.h +++ b/src/quick/handlers/qquickwheelhandler_p.h @@ -103,7 +103,7 @@ public: void setTargetTransformAroundCursor(bool ttac); Q_SIGNALS: - void wheel(const QWheelEvent &event); + void wheel(QQuickWheelEvent *event); void orientationChanged(); void invertibleChanged(); diff --git a/src/quick/handlers/qquickwheelhandler_p_p.h b/src/quick/handlers/qquickwheelhandler_p_p.h index d35e04c51b..b18f83cb16 100644 --- a/src/quick/handlers/qquickwheelhandler_p_p.h +++ b/src/quick/handlers/qquickwheelhandler_p_p.h @@ -80,6 +80,7 @@ public: mutable bool metaPropertyDirty = true; bool invertible = true; bool targetTransformAroundCursor = true; + QQuickWheelEvent wheelEvent; }; QT_END_NAMESPACE |