From 7073f6ffa1dfbf06ff1304529d788ed80a1633f2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kristian=20H=C3=B8gsberg?= Date: Mon, 14 Oct 2013 15:28:01 -0700 Subject: [PATCH] evdev: Stop looking for pointer buttons when we get to BTN_JOYSTICK We don't want to mark a touchscreen as a button device just because it exposes the BTN_TOUCH and BTN_TOOL buttons. --- src/evdev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/evdev.c b/src/evdev.c index 48e5470d..e9235d9b 100644 --- a/src/evdev.c +++ b/src/evdev.c @@ -524,7 +524,7 @@ evdev_handle_device(struct evdev_device *device) break; } } - for (i = BTN_MISC; i < KEY_OK; i++) { + for (i = BTN_MISC; i < BTN_JOYSTICK; i++) { if (TEST_BIT(key_bits, i)) { device->caps |= EVDEV_BUTTON; break;