mirror of
https://codeberg.org/dwl/dwl.git
synced 2026-04-05 07:15:31 -04:00
update to only support one scroll direction, sym void pointer
This commit is contained in:
parent
c038104eee
commit
ccfab6e26f
1 changed files with 2 additions and 6 deletions
8
dwl.c
8
dwl.c
|
|
@ -988,13 +988,9 @@ createnotify(struct wl_listener *listener, void *data)
|
||||||
double
|
double
|
||||||
libinput_event_pointer_get_scroll_value(struct libinput_event_pointer* event, enum libinput_pointer_axis axis)
|
libinput_event_pointer_get_scroll_value(struct libinput_event_pointer* event, enum libinput_pointer_axis axis)
|
||||||
{
|
{
|
||||||
void* sym = dlsym(RTLD_NEXT, "libinput_event_pointer_get_scroll_value");
|
void *sym = dlsym(RTLD_NEXT, "libinput_event_pointer_get_scroll_value");
|
||||||
hooked_axis_t hooked = *(hooked_axis_t*)(&sym);
|
hooked_axis_t hooked = *(hooked_axis_t*)(&sym);
|
||||||
if (axis == LIBINPUT_POINTER_AXIS_SCROLL_HORIZONTAL) {
|
return hooked(event, axis) * scroll_factor;
|
||||||
return hooked(event, axis) * scroll_factor;
|
|
||||||
} else {
|
|
||||||
return hooked(event, axis) * scroll_factor;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue