From: Peter Hutterer Date: Sun, 4 Jan 2015 22:36:00 +0000 (+1000) Subject: tools: print device capabilities in event-debug X-Git-Tag: 0.8.0~21 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f11cd30f0088a0f921bc03ed4fe683db5797c13f;p=platform%2Fupstream%2Flibinput.git tools: print device capabilities in event-debug Signed-off-by: Peter Hutterer --- 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);