mirror of
https://codeberg.org/dwl/dwl.git
synced 2026-09-21 22:59:10 +00:00
don't run axis bindings when locked
This commit is contained in:
@@ -663,16 +663,18 @@ axisnotify(struct wl_listener *listener, void *data)
|
|||||||
|
|
||||||
wlr_idle_notifier_v1_notify_activity(idle_notifier, seat);
|
wlr_idle_notifier_v1_notify_activity(idle_notifier, seat);
|
||||||
|
|
||||||
if (event->orientation == WL_POINTER_AXIS_VERTICAL_SCROLL)
|
if (!locked) {
|
||||||
adir = event->delta > 0 ? AxisDown : AxisUp;
|
if (event->orientation == WL_POINTER_AXIS_VERTICAL_SCROLL)
|
||||||
else
|
adir = event->delta > 0 ? AxisDown : AxisUp;
|
||||||
adir = event->delta > 0 ? AxisRight : AxisLeft;
|
else
|
||||||
keyboard = wlr_seat_get_keyboard(seat);
|
adir = event->delta > 0 ? AxisRight : AxisLeft;
|
||||||
mods = keyboard ? wlr_keyboard_get_modifiers(keyboard) : 0;
|
keyboard = wlr_seat_get_keyboard(seat);
|
||||||
for (a = axes; a < END(axes); a++) {
|
mods = keyboard ? wlr_keyboard_get_modifiers(keyboard) : 0;
|
||||||
if (CLEANMASK(mods) == CLEANMASK(a->mod) && adir == a->dir && a->func) {
|
for (a = axes; a < END(axes); a++) {
|
||||||
a->func(&a->arg);
|
if (CLEANMASK(mods) == CLEANMASK(a->mod) && adir == a->dir && a->func) {
|
||||||
return;
|
a->func(&a->arg);
|
||||||
|
return;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user