summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarlos Garnacho <carlosg@gnome.org>2015-01-09 17:11:51 +0100
committerCarlos Garnacho <carlosg@gnome.org>2016-04-05 18:56:35 +0200
commit4c4e4c29cb850cd131e4b3870dbec8f7a1f20142 (patch)
tree98dc31c4808c13fdcd50ad5d85161e77025abe95
parentafbf5f507775fb993cc8b2ebcfc6b66d6872e3b2 (diff)
downloadclutter-4c4e4c29cb850cd131e4b3870dbec8f7a1f20142.tar.gz
evdev: Map LIBINPUT_DEVICE_CAP_TABLET to CLUTTER_TABLET_DEVICE
This is so tablet devices have the correct ClutterInputDeviceType
-rw-r--r--clutter/evdev/clutter-input-device-evdev.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/clutter/evdev/clutter-input-device-evdev.c b/clutter/evdev/clutter-input-device-evdev.c
index 6e9c92520..c41b524a8 100644
--- a/clutter/evdev/clutter-input-device-evdev.c
+++ b/clutter/evdev/clutter-input-device-evdev.c
@@ -203,6 +203,8 @@ _clutter_input_device_evdev_determine_type (struct libinput_device *ldev)
*/
if (libinput_device_config_tap_get_finger_count (ldev) > 0)
return CLUTTER_TOUCHPAD_DEVICE;
+ else if (libinput_device_has_capability (ldev, LIBINPUT_DEVICE_CAP_TABLET_TOOL))
+ return CLUTTER_TABLET_DEVICE;
else if (libinput_device_has_capability (ldev, LIBINPUT_DEVICE_CAP_POINTER))
return CLUTTER_POINTER_DEVICE;
else if (libinput_device_has_capability (ldev, LIBINPUT_DEVICE_CAP_TOUCH))