mirror of
https://github.com/niri-wm/niri.git
synced 2026-06-22 02:01:55 +07:00
Allow disabling tap-and-drag (#1107)
* Allow disabling tap-and-drag Similar to https://github.com/YaLTeR/niri/pull/1088, this adds a new touchpad `drag` configuration option that configures tap-and-drag behavior. Currently tap-and-drag is always enabled when the `tap` setting is enabled, but other compositors allow setting this separately. * Update wiki/Configuration:-Input.md --------- Co-authored-by: Ivan Molodetskikh <yalterz@gmail.com>
This commit is contained in:
@@ -3334,6 +3334,13 @@ pub fn apply_libinput_settings(config: &niri_config::Input, device: &mut input::
|
||||
let _ = device.config_left_handed_set(c.left_handed);
|
||||
let _ = device.config_middle_emulation_set_enabled(c.middle_emulation);
|
||||
|
||||
if let Some(drag) = c.drag {
|
||||
let _ = device.config_tap_set_drag_enabled(drag);
|
||||
} else {
|
||||
let default = device.config_tap_default_drag_enabled();
|
||||
let _ = device.config_tap_set_drag_enabled(default);
|
||||
}
|
||||
|
||||
if let Some(accel_profile) = c.accel_profile {
|
||||
let _ = device.config_accel_set_profile(accel_profile.into());
|
||||
} else if let Some(default) = device.config_accel_default_profile() {
|
||||
|
||||
Reference in New Issue
Block a user