touchpad: a touchpad with only one button is a clickpad
authorPeter Hutterer <peter.hutterer@who-t.net>
Wed, 14 Apr 2021 05:18:13 +0000 (15:18 +1000)
committerPeter Hutterer <peter.hutterer@who-t.net>
Wed, 21 Apr 2021 00:15:42 +0000 (00:15 +0000)
commit467266bbb4cd208ecf163a6461bad1e47b5e6872
treefa35ea75de909b149641d93835b9b813609f3d8e
parent16d5d78a4d369286ec0136e0a4310ab0f4536add
touchpad: a touchpad with only one button is a clickpad

There is only one touchpad with a physical left button but no right button and
that is the old Apple touchpad, discontinued in 2008. Not a huge number of
those left, I assume.

So let's change our assumptions because these days the vast majority of
touchpads are clickpads - any touchpad that only has a left button is treated
as clickpad, even where the kernel doesn't set the INPUT_PROP_BUTTONPAD.

We do need to check for BTN_LEFT as well though, because Wacom touchpads (i.e.
the touch part of non-integrated Wacom tablets) don't have a left button
either.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
src/evdev-mt-touchpad-buttons.c
test/test-touchpad-buttons.c