From 4c035dc1e38d1a47718bfea8e6921289da68296a Mon Sep 17 00:00:00 2001
From: Simon McVittie <[EMAIL REDACTED]>
Date: Thu, 8 Jun 2023 15:14:19 +0100
Subject: [PATCH] testevdev: Add another laptop touchpad
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
This was reported by Rémi Bernon as an example of older SDL's non-udev
code path going wrong for touchpads when the invoking user happens to
be in the input group, which I believe was fixed by fdd945f2.
Signed-off-by: Simon McVittie <smcv@collabora.com>
---
test/testevdev.c | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
diff --git a/test/testevdev.c b/test/testevdev.c
index 936f10bc5682..80a4f73c3ead 100644
--- a/test/testevdev.c
+++ b/test/testevdev.c
@@ -800,6 +800,26 @@ static const GuessTest guess_tests[] =
/* POINTER, BUTTONPAD */
.props = { 0x05 },
},
+ {
+ .name = "DELL08AF:00 (Dell XPS laptop touchpad)",
+ .bus_type = 0x18,
+ .vendor_id = 0x6cb,
+ .product_id = 0x76af,
+ .version = 0x100,
+ .ev = { 0x0b },
+ .expected = SDL_UDEV_DEVICE_TOUCHPAD,
+ /* X, Y, multitouch */
+ .abs = { 0x03, 0x00, 0x00, 0x00, 0x00, 0x80, 0xe0, 0x02 },
+ .keys = {
+ /* 0x00-0xff */ ZEROx8, ZEROx8, ZEROx8, ZEROx8,
+ /* Left mouse button */
+ /* 0x100 */ 0x00, 0x00, 0x01, 0x00, ZEROx4,
+ /* BTN_TOOL_FINGER and some multitouch gestures */
+ /* 0x140 */ 0x20, 0xe5
+ },
+ /* POINTER, BUTTONPAD */
+ .props = { 0x05 },
+ },
{
.name = "TPPS/2 Elan TrackPoint (Thinkpad X280)",
.bus_type = 0x0011, /* BUS_I8042 */