tools: print the device in all measure tools
authorPeter Hutterer <peter.hutterer@who-t.net>
Thu, 30 Nov 2017 04:21:22 +0000 (14:21 +1000)
committerPeter Hutterer <peter.hutterer@who-t.net>
Thu, 14 Dec 2017 05:50:52 +0000 (15:50 +1000)
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit 0b8372962b425437ac7d1248cffccf4a7890a556)

tools/libinput-measure-touch-size
tools/libinput-measure-touchpad-pressure

index b7aa0e990b84e18967c01a8cdf46637e8ea5d1ca..f6097498277978613d8ebfd29c3b46a6ddcf1988 100755 (executable)
@@ -186,6 +186,9 @@ class Device(object):
             self.path = path
 
         self.device = evdev.InputDevice(self.path)
+
+        print("Using {}: {}\n".format(self.device.name, self.path))
+
         # capabilities returns a dict with the EV_* codes as key,
         # each of which is a list of tuples of (code, AbsInfo)
         #
index 052d64d35c8c0ad62939016b6ec9a523925c8c46..83ae224eaa868940b13c63477d3f92e6a3cfc04b 100755 (executable)
@@ -145,6 +145,9 @@ class Device(object):
             self.path = path
 
         self.device = evdev.InputDevice(self.path)
+
+        print("Using {}: {}\n".format(self.device.name, self.path))
+
         # capabilities rturns a dict with the EV_* codes as key,
         # each of which is a list of tuples of (code, AbsInfo)
         #