backend/wayland: handle high-res scroll events

Receive high-resolution scroll events from the parent compositor using
a Wayland listiner and emit the appropiate wlr_pointer signal.
This commit is contained in:
José Expósito 2021-09-20 19:47:07 +02:00
parent d18b85c88a
commit e5932867f1
3 changed files with 36 additions and 10 deletions

View file

@ -211,7 +211,7 @@ static void registry_global(void *data, struct wl_registry *registry,
&wl_compositor_interface, 4);
} else if (strcmp(iface, wl_seat_interface.name) == 0) {
struct wl_seat *wl_seat = wl_registry_bind(registry, name,
&wl_seat_interface, 5);
&wl_seat_interface, version < 8 ? version : 8);
if (!create_wl_seat(wl_seat, wl)) {
wl_seat_destroy(wl_seat);
}