]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
hwdb: add ID_INPUT_TRACKBALL as additional identifier (#3872)
authorPeter Hutterer <peter.hutterer@who-t.net>
Wed, 3 Aug 2016 10:34:56 +0000 (20:34 +1000)
committerLennart Poettering <lennart@poettering.net>
Wed, 3 Aug 2016 10:34:56 +0000 (12:34 +0200)
Whether a device is a trackball or not is a physical property so we should
store this globally, in one place. The new property must be set in addition to
ID_INPUT_MOUSE, otherwise existing clients won't detect the device.

No actual code changes required, the default match rule is simply checking for
"Trackball" in the name (in a few versions), other entries need to be added
manually.

hwdb/70-mouse.hwdb

index a5b39dc41e787c51bcfba43bd6bbf03ff1f968b2..b68c01066e63e02cbfd1e2b519a584c9a732ac52 100644 (file)
 #   udevadm info /dev/input/eventXX.
 #
 # Allowed properties are:
+#    ID_INPUT_TRACKBALL
 #    MOUSE_DPI
 #    MOUSE_WHEEL_CLICK_ANGLE
 #
 #########################################
+#         ID_INPUT_TRACKBALL            #
+#########################################
+#
+# Specified *in additition* to ID_INPUT_MOUSE if the device is a trackball.
+# Removing ID_INPUT_MOUSE will break backwards compatibility.
+#
+#########################################
 #               MOUSE_DPI               #
 #########################################
 #
 # Sort by brand, type (usb, bluetooth), DPI, frequency.
 # For mice with switchable resolution, sort by the starred entry.
 
+##########################################
+# Generic
+##########################################
+mouse:*:name:*Trackball*:
+mouse:*:name:*trackball*:
+mouse:*:name:*TrackBall*:
+ ID_INPUT_TRACKBALL=1
+
 ##########################################
 # Apple
 ##########################################
@@ -231,6 +247,7 @@ mouse:usb:v04b3p310c:name:USB Optical Mouse:
 # Logitech M570 trackball
 mouse:usb:v046dp1028:name:Logitech M570:
  MOUSE_DPI=540@167
+ ID_INPUT_TRACKBALL=1
 
 # Logitech USB-PS/2 M-BZ96C
 mouse:usb:v046dpc045:name:Logitech USB-PS/2 Optical Mouse: