From f11cd30f0088a0f921bc03ed4fe683db5797c13f Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Mon, 5 Jan 2015 08:36:00 +1000 Subject: [PATCH] tools: print device capabilities in event-debug Signed-off-by: Peter Hutterer --- tools/event-debug.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/tools/event-debug.c b/tools/event-debug.c index 5750bcac..8fbea24a 100644 --- a/tools/event-debug.c +++ b/tools/event-debug.c @@ -130,6 +130,17 @@ print_device_notify(struct libinput_event *ev) libinput_seat_get_physical_name(seat), libinput_seat_get_logical_name(seat)); + printf(" cap:"); + if (libinput_device_has_capability(dev, + LIBINPUT_DEVICE_CAP_KEYBOARD)) + printf("k"); + if (libinput_device_has_capability(dev, + LIBINPUT_DEVICE_CAP_POINTER)) + printf("p"); + if (libinput_device_has_capability(dev, + LIBINPUT_DEVICE_CAP_TOUCH)) + printf("t"); + if (libinput_device_get_size(dev, &w, &h) == 0) printf("\tsize %.2f/%.2fmm", w, h); -- 2.34.1