From 5e95e2df615d160666ce567705b60d39ededfc6f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20=C5=81o=C5=9B?= Date: Thu, 3 Oct 2024 07:39:57 +0200 Subject: [PATCH] Enable touchscreen discovery on VxWorks Change-Id: I350551c398608b52c8478499aa21303916b77afa Reviewed-by: Karim Pinter Reviewed-by: Laszlo Agocs --- .../devicediscovery/qdevicediscovery_vxworks.cpp | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/platformsupport/devicediscovery/qdevicediscovery_vxworks.cpp b/src/platformsupport/devicediscovery/qdevicediscovery_vxworks.cpp index 7fbfd9b0126..6b119ed4d8d 100644 --- a/src/platformsupport/devicediscovery/qdevicediscovery_vxworks.cpp +++ b/src/platformsupport/devicediscovery/qdevicediscovery_vxworks.cpp @@ -79,12 +79,20 @@ bool QDeviceDiscoveryVxWorks::checkDeviceType(const QString &device) } if (m_types & Device_Mouse) { - if ((devCap & EV_DEV_REL) && (devCap & EV_DEV_KEY)) { + if ((devCap & EV_DEV_REL) && (devCap & EV_DEV_KEY) && !(devCap & EV_DEV_ABS)) { qCDebug(lcDD) << "DeviceDiscovery found mouse at" << device; QT_CLOSE(fd); return true; } } + + if ((m_types & (Device_Touchpad | Device_Touchscreen))) { + if ((m_types & Device_Touchscreen) && (devCap & EV_DEV_ABS && (devCap & EV_DEV_KEY))) { + qCDebug(lcDD) << "DeviceDiscovery found touchscreen at" << device; + QT_CLOSE(fd); + return true; + } + } } QT_CLOSE(fd);