diff options
Diffstat (limited to 'plugins/mouse/msd-mouse-manager.c')
-rw-r--r-- | plugins/mouse/msd-mouse-manager.c | 35 |
1 files changed, 29 insertions, 6 deletions
diff --git a/plugins/mouse/msd-mouse-manager.c b/plugins/mouse/msd-mouse-manager.c index bed7d88..80d19f2 100644 --- a/plugins/mouse/msd-mouse-manager.c +++ b/plugins/mouse/msd-mouse-manager.c @@ -710,12 +710,12 @@ get_touchpad_handedness (MsdMouseManager *manager, } static void -set_tap_to_click (XDeviceInfo *device_info, - gboolean state, - gboolean left_handed, - gint one_finger_tap, - gint two_finger_tap, - gint three_finger_tap) +set_tap_to_click_synaptics (XDeviceInfo *device_info, + gboolean state, + gboolean left_handed, + gint one_finger_tap, + gint two_finger_tap, + gint three_finger_tap) { XDevice *device; int format, rc; @@ -765,6 +765,29 @@ set_tap_to_click (XDeviceInfo *device_info, } static void +set_tap_to_click_libinput (XDeviceInfo *device_info, + gboolean state) +{ + touchpad_set_bool (device_info, "libinput Tapping Enabled", 0, state); +} + +static void +set_tap_to_click (XDeviceInfo *device_info, + gboolean state, + gboolean left_handed, + gint one_finger_tap, + gint two_finger_tap, + gint three_finger_tap) +{ + if (property_from_name ("Synaptics Tap Action")) + set_tap_to_click_synaptics (device_info, state, left_handed, + one_finger_tap, two_finger_tap, three_finger_tap); + + if (property_from_name ("libinput Tapping Enabled")) + set_tap_to_click_libinput (device_info, state); +} + +static void set_tap_to_click_all (MsdMouseManager *manager) { int numdevices, i; |