diff options
author | Shawn Rutledge <shawn.rutledge@qt.io> | 2016-07-14 11:17:54 +0200 |
---|---|---|
committer | Shawn Rutledge <shawn.rutledge@qt.io> | 2016-07-15 13:26:56 +0000 |
commit | 288c1425d6e3ac200dd8e687f13de6ce4a41260b (patch) | |
tree | 78cba9a5ffd2416f0c2a703c8ec16e02b221275b /src/quick/items/qquickevents.cpp | |
parent | 6ce37a1eed9a41b036872bbbac2a5e73c6cbf9eb (diff) |
QQuickWindow: keep a collection of devices which own event instances
That will allow the event instances to hold state, even between events.
So now every QQuickWindow has its own set of them, per device.
Hopefully that means we won't have any trouble delivering events in parallel
in case each window has its own thread. Otherwise maybe it's slightly
wasteful in multi-window apps.
Change-Id: I766b580e1c177255905cc04b5de7d33ae503c6fd
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
Diffstat (limited to 'src/quick/items/qquickevents.cpp')
-rw-r--r-- | src/quick/items/qquickevents.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/quick/items/qquickevents.cpp b/src/quick/items/qquickevents.cpp index 4f677e841c..911cc9a52c 100644 --- a/src/quick/items/qquickevents.cpp +++ b/src/quick/items/qquickevents.cpp @@ -450,8 +450,8 @@ Item { to expose the event to QML, the same as is done with QQuickMouseEvent, QQuickTouchPoint, QQuickKeyEvent, etc. Since only one event can be delivered at a time, this class is effectively a singleton. We don't worry - about the QObject overhead because we never dynamically create and destroy - objects of this type. + about the QObject overhead because the instances are long-lived: we don't + dynamically create and destroy objects of this type for each event. */ /*! |