diff options
author | Shawn Rutledge <shawn.rutledge@qt.io> | 2020-03-26 16:50:40 +0100 |
---|---|---|
committer | Shawn Rutledge <shawn.rutledge@qt.io> | 2020-06-23 17:44:03 +0200 |
commit | d0ae3a312a03c118a1aa25a4c6c0352375d569fc (patch) | |
tree | 01df3e8ea22c8a1ecd969a6e9e6d7014c635da9f /src/quick/items/qquickitem.cpp | |
parent | d5d6a56809032796444fe63c220a2e940ce237c0 (diff) |
Remove QQuickPointerDevice in favor of QPointingDevice
...and generally deal with changes immediately required after adding
QInputDevice and QPointingDevice.
Also fixed a few usages of deprecated accessors that weren't taken
care of in 212c2bffbb041aee0e3c9a7f0551ef151ed2d3ad.
Task-number: QTBUG-46412
Task-number: QTBUG-69433
Task-number: QTBUG-72167
Change-Id: I93a2643162878afa216556f10808fd92e0b20071
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
Diffstat (limited to 'src/quick/items/qquickitem.cpp')
-rw-r--r-- | src/quick/items/qquickitem.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/quick/items/qquickitem.cpp b/src/quick/items/qquickitem.cpp index 620f6fe798..9598fb1c8e 100644 --- a/src/quick/items/qquickitem.cpp +++ b/src/quick/items/qquickitem.cpp @@ -54,6 +54,7 @@ #include <QtGui/qguiapplication.h> #include <QtGui/qstylehints.h> #include <QtGui/private/qguiapplication_p.h> +#include <QtGui/private/qpointingdevice_p.h> #include <QtGui/qinputmethod.h> #include <QtCore/qcoreevent.h> #include <QtCore/private/qnumeric_p.h> @@ -69,6 +70,7 @@ #include <QtQuick/private/qquickaccessibleattached_p.h> #include <QtQuick/private/qquickhoverhandler_p.h> #include <QtQuick/private/qquickpointerhandler_p.h> +#include <QtQuick/private/qquickpointerhandler_p_p.h> #include <private/qv4engine_p.h> #include <private/qv4object_p.h> @@ -5260,7 +5262,7 @@ bool QQuickItemPrivate::anyPointerHandlerWants(QQuickEventPoint *point) const bool QQuickItemPrivate::handlePointerEvent(QQuickPointerEvent *event, bool avoidExclusiveGrabber) { bool delivered = false; - QVector<QQuickPointerHandler *> &eventDeliveryTargets = event->device()->eventDeliveryTargets(); + QVector<QObject *> &eventDeliveryTargets = QQuickPointerHandlerPrivate::deviceDeliveryTargets(event->device()); if (extra.isAllocated()) { for (QQuickPointerHandler *handler : extra->pointerHandlers) { if ((!avoidExclusiveGrabber || !event->hasExclusiveGrabber(handler)) && !eventDeliveryTargets.contains(handler)) { @@ -7633,7 +7635,7 @@ void QQuickItem::grabMouse() bool fromTouch = windowPriv->isDeliveringTouchAsMouse(); auto point = fromTouch ? windowPriv->pointerEventInstance(windowPriv->touchMouseDevice)->pointById(windowPriv->touchMouseId) : - windowPriv->pointerEventInstance(QQuickPointerDevice::genericMouseDevice())->point(0); + windowPriv->pointerEventInstance(QPointingDevice::primaryPointingDevice())->point(0); if (point) point->setGrabberItem(this); } |