qt5base-lts/tests/auto/gui/kernel
Shawn Rutledge 6589f2ed0c Introduce QInputDevice hierarchy; replace QTouchDevice
We have seen during the Qt 5 series that QMouseEvent::source() does
not provide enough information: if it is synthesized, it could have
come from any device for which mouse events are synthesized, not only
from a touchscreen. By providing in every QInputEvent as complete
information about the actual source device as possible, we will enable
very fine-tuned behavior in the object that handles each event.

Further, we would like to support multiple keyboards, pointing devices,
and named groups of devices that are known as "seats" in Wayland.

In Qt 5, QPA plugins registered each touchscreen as it was discovered.
Now we extend this pattern to all input devices.  This new requirement
can be implemented gradually; for now, if a QTWSI input event is
received wtihout a device pointer, a default "core" device will be
created on-the-fly, and a warning emitted.

In Qt 5, QTouchEvent::TouchPoint::id() was forced to be unique even when
multiple devices were in use simultaneously. Now that each event
identifies the device it came from, this hack is no longer needed.

A stub of the new QPointerEvent is added; it will be developed further
in subsequent patches.

[ChangeLog][QtGui][QInputEvent] Every QInputEvent now carries a pointer
to an instance of QInputDevice, or the subclass QPointingDevice in case
of mouse, touch and tablet events. Each platform plugin is expected to
create the device instances, register them, and provide valid pointers
with all input events. If this is not done, warnings are emitted and
default devices are created as necessary. When the device has accurate
information, it provides the opportunity to fine-tune behavior depending
on device type and capabilities: for example if a QMouseEvent is
synthesized from a touchscreen, the recipient can see which touchscreen
it came from. Each device also has a seatName to distinguish users on
multi-user windowing systems. Touchpoint IDs are no longer unique on
their own, but the combination of ID and device is.

Fixes: QTBUG-46412
Fixes: QTBUG-72167
Task-number: QTBUG-69433
Task-number: QTBUG-52430
Change-Id: I933fb2b86182efa722037b7a33e404c5daf5292a
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
2020-06-16 22:06:56 +02:00
..
noqteventloop Remove winrt 2020-06-06 20:25:49 +02:00
qaction Merge remote-tracking branch 'origin/5.15' into dev 2020-04-08 20:11:39 +02:00
qactiongroup Merge remote-tracking branch 'origin/5.15' into dev 2020-04-08 20:11:39 +02:00
qaddpostroutine Merge remote-tracking branch 'origin/5.15' into dev 2020-04-08 20:11:39 +02:00
qbackingstore Regenerate projects one last time before merge 2020-02-12 17:30:49 +00:00
qclipboard Remove winrt 2020-06-06 20:25:49 +02:00
qcursor cmake: add gui/kernel tests 2019-10-31 09:49:30 +00:00
qdrag Remove deprecated members from several QtGui classes 2020-04-27 12:21:29 +02:00
qevent cmake: add gui/kernel tests 2019-10-31 09:49:30 +00:00
qfileopenevent cmake: add gui/kernel tests 2019-10-31 09:49:30 +00:00
qguiapplication Introduce QInputDevice hierarchy; replace QTouchDevice 2020-06-16 22:06:56 +02:00
qguieventdispatcher Remove winrt 2020-06-06 20:25:49 +02:00
qguieventloop Remove winrt 2020-06-06 20:25:49 +02:00
qguimetatype Get rid of QMatrix 2020-02-28 08:57:57 +01:00
qguitimer Regenerate projects one last time before merge 2020-02-12 17:30:49 +00:00
qguivariant Get rid of QMatrix 2020-02-28 08:57:57 +01:00
qhighdpiscaling Merge remote-tracking branch 'origin/5.15' into dev 2020-04-08 20:11:39 +02:00
qinputmethod Regenerate projects one last time before merge 2020-02-12 17:30:49 +00:00
qkeyevent Merge remote-tracking branch 'origin/dev' into wip/cmake 2019-11-19 13:53:21 +01:00
qkeysequence Regenerate projects one last time before merge 2020-02-12 17:30:49 +00:00
qmouseevent Replace calls to deprecated QEvent accessor functions 2020-06-08 19:11:51 +02:00
qmouseevent_modal Merge remote-tracking branch 'origin/5.15' into dev 2020-02-13 18:31:40 +01:00
qopenglwindow Remove winrt 2020-06-06 20:25:49 +02:00
qpalette Merge remote-tracking branch 'origin/dev' into merge-dev 2020-01-24 13:17:33 +01:00
qpixelformat cmake: add gui/kernel tests 2019-10-31 09:49:30 +00:00
qrasterwindow Regenerate projects one last time before merge 2020-02-12 17:30:49 +00:00
qscreen Remove QScreen::orientationUpdateMask 2020-05-07 13:48:08 +00:00
qshortcut Merge remote-tracking branch 'origin/5.15' into dev 2020-04-08 20:11:39 +02:00
qsurfaceformat Regenerate projects one last time before merge 2020-02-12 17:30:49 +00:00
qtouchevent Introduce QInputDevice hierarchy; replace QTouchDevice 2020-06-16 22:06:56 +02:00
qwindow Introduce QInputDevice hierarchy; replace QTouchDevice 2020-06-16 22:06:56 +02:00
CMakeLists.txt Remove winrt 2020-06-06 20:25:49 +02:00
kernel.pro Remove winrt 2020-06-06 20:25:49 +02:00