diff options
author | Peter Hutterer <peter.hutterer@who-t.net> | 2016-01-21 12:35:11 +1000 |
---|---|---|
committer | Peter Hutterer <peter.hutterer@who-t.net> | 2016-04-18 09:12:02 +1000 |
commit | b2a370694881b849c4b3ea59b53a0a9cb0f44ea0 (patch) | |
tree | d35570313861eb898fe527e6cf5703b02ea1d8c9 /test | |
parent | 61e58a4c1f78145d9b29ab0ed822c74051b545a2 (diff) |
Add the LIBINPUT_DEVICE_CAP_TABLET_PAD capability and matching interface
This interface handles the buttons on the physical tablet itself, including
the touch ring and the strip.
A notable difference to other libinput interfaces here is that we do not use
linux/input.h event codes for buttons. Instead, the buttons are merely
numbered sequentially, starting at button 1. This means:
* the API is different, instead of get_button() we have get_button_number() to
drive the point home
* there is no seat button count. pads are inherently different devices and
compositors should treat them as such. The seat button count makes sense
when you want to know how many devices have BTN_LEFT down, but it makes no
sense for buttons where all the semantics are handled by the compositor
anyway.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Jason Gerecke <jason.gerecke@wacom.com>
Reviewed-by: Carlos Garnacho <carlosg@gnome.org>
Diffstat (limited to 'test')
-rw-r--r-- | test/litest.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/test/litest.c b/test/litest.c index 67ff9375..70b4bd37 100644 --- a/test/litest.c +++ b/test/litest.c @@ -1963,6 +1963,15 @@ litest_event_type_str(struct libinput_event *event) case LIBINPUT_EVENT_TABLET_TOOL_BUTTON: str = "TABLET TOOL BUTTON"; break; + case LIBINPUT_EVENT_TABLET_PAD_BUTTON: + str = "TABLET PAD BUTTON"; + break; + case LIBINPUT_EVENT_TABLET_PAD_RING: + str = "TABLET PAD RING"; + break; + case LIBINPUT_EVENT_TABLET_PAD_STRIP: + str = "TABLET PAD STRIP"; + break; } return str; } |