mirror of
https://gitlab.freedesktop.org/libinput/libinput.git
synced 2025-12-28 20:10:08 +01:00
touchpad: mark USB touchpads as internal by default
External touchpads using USB are vanishingly few, built-in touchpads that use USB are comparatively common. So let's default to internal, for vendors like Logitech and Wacom that only make external touchpads we have special conditions in place anyway. Fixes #664 Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
parent
ea7a88d213
commit
b6e8aef4fb
1 changed files with 3 additions and 10 deletions
|
|
@ -2729,22 +2729,15 @@ evdev_tag_touchpad(struct evdev_device *device,
|
|||
/* The hwdb is the authority on integration, these heuristics are
|
||||
* the fallback only (they precede the hwdb too).
|
||||
*
|
||||
* Simple approach: USB is unknown, with the exception
|
||||
* of Apple where internal touchpads are connected over USB and it
|
||||
* doesn't have external USB touchpads anyway.
|
||||
*
|
||||
* Simple approach:
|
||||
* Bluetooth touchpads are considered external, anything else is
|
||||
* internal.
|
||||
* internal. Except the ones from some vendors that only make external
|
||||
* touchpads.
|
||||
*/
|
||||
bustype = libevdev_get_id_bustype(device->evdev);
|
||||
vendor = libevdev_get_id_vendor(device->evdev);
|
||||
|
||||
switch (bustype) {
|
||||
case BUS_USB:
|
||||
if (evdev_device_has_model_quirk(device,
|
||||
QUIRK_MODEL_APPLE_TOUCHPAD))
|
||||
evdev_tag_touchpad_internal(device);
|
||||
break;
|
||||
case BUS_BLUETOOTH:
|
||||
evdev_tag_touchpad_external(device);
|
||||
break;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue