fix crash on non-libinput pointers (e.g. X11 backend)
This commit is contained in:
parent
5f3a7887f3
commit
d94266df91
2
dwl.c
2
dwl.c
@ -899,6 +899,7 @@ createlayersurface(struct wl_listener *listener, void *data)
|
||||
void
|
||||
createpointer(struct wlr_input_device *device)
|
||||
{
|
||||
if (wlr_input_device_is_libinput(device)) {
|
||||
struct libinput_device *libinput_device = (struct libinput_device*)
|
||||
wlr_libinput_get_device_handle(device);
|
||||
|
||||
@ -907,6 +908,7 @@ createpointer(struct wlr_input_device *device)
|
||||
|
||||
if (libinput_device_config_scroll_has_natural_scroll(libinput_device))
|
||||
libinput_device_config_scroll_set_natural_scroll_enabled(libinput_device, natural_scrolling);
|
||||
}
|
||||
|
||||
/* We don't do anything special with pointers. All of our pointer handling
|
||||
* is proxied through wlr_cursor. On another compositor, you might take this
|
||||
|
Loading…
Reference in New Issue
Block a user