mirror of
https://gitlab.freedesktop.org/libinput/libinput.git
synced 2025-12-25 11:40:06 +01:00
touchpad: add a model tag to mark touchpads with visible marker
We used to mark dell touchpads this way but let's make this more generic. Nothing else used the dell touchpad model flag, so we can simply replace it. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Reviewed-by: Hans de Goede <hdegoede@redhat.com>
This commit is contained in:
parent
7b3e583abe
commit
43ba2dbb30
6 changed files with 6 additions and 8 deletions
|
|
@ -569,10 +569,8 @@ tp_init_softbuttons(struct tp_dispatch *tp,
|
|||
*
|
||||
* On touchpads with visible markings we reduce the size of the
|
||||
* middle button since users have a visual guide.
|
||||
*
|
||||
* All Dell touchpads appear to have a middle marker.
|
||||
*/
|
||||
if (tp->device->model_flags & EVDEV_MODEL_DELL_TOUCHPAD) {
|
||||
if (tp->device->model_flags & EVDEV_MODEL_TOUCHPAD_VISIBLE_MARKER) {
|
||||
mm.x = width/2 - 5; /* 10mm wide */
|
||||
edges = evdev_device_mm_to_units(device, &mm);
|
||||
mb_le = edges.x;
|
||||
|
|
|
|||
|
|
@ -2201,7 +2201,7 @@ evdev_read_model_flags(struct evdev_device *device)
|
|||
MODEL(CYAPA),
|
||||
MODEL(HP_STREAM11_TOUCHPAD),
|
||||
MODEL(LENOVO_T450_TOUCHPAD),
|
||||
MODEL(DELL_TOUCHPAD),
|
||||
MODEL(TOUCHPAD_VISIBLE_MARKER),
|
||||
MODEL(TRACKBALL),
|
||||
MODEL(APPLE_MAGICMOUSE),
|
||||
MODEL(HP8510_TOUCHPAD),
|
||||
|
|
|
|||
|
|
@ -116,7 +116,7 @@ enum evdev_device_model {
|
|||
EVDEV_MODEL_CYAPA = (1 << 15),
|
||||
EVDEV_MODEL_HP_STREAM11_TOUCHPAD = (1 << 16),
|
||||
EVDEV_MODEL_LENOVO_T450_TOUCHPAD= (1 << 17),
|
||||
EVDEV_MODEL_DELL_TOUCHPAD = (1 << 18),
|
||||
EVDEV_MODEL_TOUCHPAD_VISIBLE_MARKER = (1 << 18),
|
||||
EVDEV_MODEL_TRACKBALL = (1 << 19),
|
||||
EVDEV_MODEL_APPLE_MAGICMOUSE = (1 << 20),
|
||||
EVDEV_MODEL_HP8510_TOUCHPAD = (1 << 21),
|
||||
|
|
|
|||
|
|
@ -106,7 +106,7 @@ static const char udev_rule[] =
|
|||
"ENV{ID_INPUT_TOUCHPAD}==\"\", GOTO=\"touchpad_end\"\n"
|
||||
"\n"
|
||||
"ATTRS{name}==\"litest AlpsPS/2 ALPS DualPoint TouchPad\","
|
||||
" ENV{LIBINPUT_MODEL_DELL_TOUCHPAD}=\"1\"\n"
|
||||
" ENV{LIBINPUT_MODEL_TOUCHPAD_VISIBLE_MARKER}=\"1\"\n"
|
||||
"\n"
|
||||
"LABEL=\"touchpad_end\"";
|
||||
|
||||
|
|
|
|||
|
|
@ -92,7 +92,7 @@ static const char udev_rule[] =
|
|||
"ENV{ID_INPUT_TOUCHPAD}==\"\", GOTO=\"touchpad_end\"\n"
|
||||
"\n"
|
||||
"ATTRS{name}==\"litest DLL0704:01 06CB:76AD Touchpad\","
|
||||
" ENV{LIBINPUT_MODEL_DELL_TOUCHPAD}=\"1\"\n"
|
||||
" ENV{LIBINPUT_MODEL_TOUCHPAD_VISIBLE_MARKER}=\"1\"\n"
|
||||
"\n"
|
||||
"LABEL=\"touchpad_end\"";
|
||||
|
||||
|
|
|
|||
|
|
@ -53,7 +53,7 @@ libinput:mouse:input:b0003v06A3p0CD5*
|
|||
##########################################
|
||||
libinput:name:SynPS/2 Synaptics TouchPad:dmi:*svnDellInc.:*
|
||||
libinput:name:* Touchpad:dmi:*svnDellInc.:*
|
||||
LIBINPUT_MODEL_DELL_TOUCHPAD=1
|
||||
LIBINPUT_MODEL_TOUCHPAD_VISIBLE_MARKER=1
|
||||
|
||||
##########################################
|
||||
# Elantech
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue