Fix rootston input on HiDPI outputs in wayland backend

This commit is contained in:
emersion 2017-12-15 16:28:04 +01:00
parent 51db087210
commit 51bbcc0fbf
No known key found for this signature in database
GPG key ID: 0FDE7BE0E88F5E48

View file

@ -59,11 +59,11 @@ static void pointer_handle_motion(void *data, struct wl_pointer *wl_pointer,
&box.width, &box.height); &box.width, &box.height);
box.x = wl_fixed_to_int(surface_x); box.x = wl_fixed_to_int(surface_x);
box.y = wl_fixed_to_int(surface_y); box.y = wl_fixed_to_int(surface_y);
struct wlr_box transformed;
struct wlr_box transformed;
wlr_box_transform(&box, wlr_output->transform, &transformed); wlr_box_transform(&box, wlr_output->transform, &transformed);
box.x /= wlr_output->scale; transformed.x /= wlr_output->scale;
box.y /= wlr_output->scale; transformed.y /= wlr_output->scale;
struct wlr_box layout_box; struct wlr_box layout_box;
wlr_wl_output_layout_get_box(wlr_wl_pointer->current_output->backend, wlr_wl_output_layout_get_box(wlr_wl_pointer->current_output->backend,