summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorShawn Rutledge <shawn.rutledge@qt.io>2017-05-11 20:36:51 +0200
committerJani Heikkinen <jani.heikkinen@qt.io>2017-05-20 06:04:36 +0000
commit96f6ba5f562073f508cd8569ac354592fdd48f4a (patch)
tree7925674b0163523e40d43c4eed3db0eb7815d240
parent5f49b2b3bb30678a26341e1f45e0cfd6a6fd2c57 (diff)
Revert "Temporarily restore QQuickPointerDevice::pointerEvent() accessor"v5.9.0-rc2v5.9.0-rc1v5.9.0
This reverts commit ee6b07b3ce8ba80632868181d45d96253acb1064. This is to be integrated after the qtlocation change to remove the dependency on this private function. Task-number: QTBUG-57253 Change-Id: I756681fb2595d1326b7e5206bac57ccc318c0a46 Reviewed-by: Liang Qi <liang.qi@qt.io>
-rw-r--r--src/quick/items/qquickevents_p_p.h7
-rw-r--r--src/quick/items/qquickwindow.cpp5
2 files changed, 1 insertions, 11 deletions
diff --git a/src/quick/items/qquickevents_p_p.h b/src/quick/items/qquickevents_p_p.h
index 323ecfa4ff..3735d68a85 100644
--- a/src/quick/items/qquickevents_p_p.h
+++ b/src/quick/items/qquickevents_p_p.h
@@ -501,7 +501,6 @@ public:
: m_deviceType(devType), m_pointerType(pType), m_capabilities(caps)
, m_maximumTouchPoints(maxPoints), m_buttonCount(buttonCount), m_name(name)
, m_uniqueId(QPointingDeviceUniqueId::fromNumericId(uniqueId))
- , m_event(nullptr)
{
}
@@ -514,8 +513,6 @@ public:
QString name() const { return m_name; }
QPointingDeviceUniqueId uniqueId() const { return m_uniqueId; }
- QQuickPointerEvent *pointerEvent() const { return m_event; } // deprecated
-
static QQuickPointerDevice *touchDevice(QTouchDevice *d);
static QList<QQuickPointerDevice *> touchDevices();
static QQuickPointerDevice *genericMouseDevice();
@@ -530,10 +527,6 @@ private:
QString m_name;
QPointingDeviceUniqueId m_uniqueId;
- // the event instance used last time within the context of one window
- QQuickPointerEvent *m_event; // deprecated
- friend class QQuickWindowPrivate; // not needed after removing the above
-
Q_DISABLE_COPY(QQuickPointerDevice)
};
diff --git a/src/quick/items/qquickwindow.cpp b/src/quick/items/qquickwindow.cpp
index 816c057ab0..c441cfc357 100644
--- a/src/quick/items/qquickwindow.cpp
+++ b/src/quick/items/qquickwindow.cpp
@@ -2117,10 +2117,8 @@ QQuickPointerEvent *QQuickWindowPrivate::pointerEventInstance(QQuickPointerDevic
{
// the list of devices should be very small so a linear search should be ok
for (QQuickPointerEvent *e: pointerEventInstances) {
- if (e->device() == device) {
- device->m_event = e;
+ if (e->device() == device)
return e;
- }
}
QQuickPointerEvent *ev = nullptr;
@@ -2138,7 +2136,6 @@ QQuickPointerEvent *QQuickWindowPrivate::pointerEventInstance(QQuickPointerDevic
break;
}
pointerEventInstances << ev;
- device->m_event = ev;
return ev;
}