summaryrefslogtreecommitdiffstats
path: root/src/corelib/kernel/qobjectdefs.h
diff options
context:
space:
mode:
authorGatis Paeglis <gatis.paeglis@qt.io>2017-05-29 17:32:46 +0200
committerGatis Paeglis <gatis.paeglis@qt.io>2017-07-13 11:30:40 +0000
commit7499d4404f9eb7223674cd0523f35eff1be7c1c9 (patch)
tree6b89754be808b1d99efb4394f0d7fd738780e088 /src/corelib/kernel/qobjectdefs.h
parent545458cb77c532500f859764f78eaf35b49c8005 (diff)
xcb: don't keep objects for disconnected touch devices
... as XI2 reuses device ids and we might end up with some bogus objects in m_touchDevices (the same touch device after reconnecting might have a new device id). With this patch, m_touchDevices is handled similarly to tablets and scolling devices. This patch also removes unnecessary calls to X (XIQueryDevice). We already have device information available for all devices when populating m_touchDevices list, so calling XIQueryDevice again for every device id (which we haven't already concluded to be a tablet device) is a redundant round trip to X. For consistency with other device types, extend touch device data structure to store the necessary device details, instead of holding pointers to XIDeviceInfo. And allocate touch device objects on stack instead of heap, also for the consistency reasons (this way we won't need to special case m_touchDevices when running some management task on _all_ devices, e.g. removing a device with id=n when it was disconnected). Change-Id: I9f6edfaf24da911dd21ec45cd48dfdd6d0dcdf8b Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Diffstat (limited to 'src/corelib/kernel/qobjectdefs.h')
0 files changed, 0 insertions, 0 deletions