bar/wayland: scale mouse position on mouse entry

This commit is contained in:
Daniel Eklöf 2019-07-05 10:27:33 +02:00
parent 8567257a88
commit 9b5dca52e2
No known key found for this signature in database
GPG key ID: 5BBD4992C116573F

View file

@ -149,8 +149,8 @@ wl_pointer_enter(void *data, struct wl_pointer *wl_pointer,
{ {
struct wayland_backend *backend = data; struct wayland_backend *backend = data;
backend->pointer.serial = serial; backend->pointer.serial = serial;
backend->pointer.x = wl_fixed_to_int(surface_x); backend->pointer.x = wl_fixed_to_int(surface_x) * backend->monitor->scale;
backend->pointer.y = wl_fixed_to_int(surface_y); backend->pointer.y = wl_fixed_to_int(surface_y) * backend->monitor->scale;
update_cursor_surface(backend); update_cursor_surface(backend);
} }