From e3ef3e59f82ab8224722279f40359a116b10d479 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Kristian=20H=C3=B8gsberg?= Date: Sun, 21 Dec 2008 19:30:01 -0500 Subject: [PATCH] Oops, fix compilation. --- wayland-system-compositor.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/wayland-system-compositor.c b/wayland-system-compositor.c index a394893..43fb1b1 100644 --- a/wayland-system-compositor.c +++ b/wayland-system-compositor.c @@ -588,8 +588,8 @@ pick_surface(struct wlsc_input_device *device, int32_t *sx, int32_t *sy) struct egl_surface, link); /* Transform to surface coordinates. */ - *sx = (x - es->map.x) * es->width / es->map.width; - *sy = (y - es->map.y) * es->height / es->map.height; + *sx = (device->x - es->map.x) * es->width / es->map.width; + *sy = (device->y - es->map.y) * es->height / es->map.height; } return NULL; @@ -615,13 +615,13 @@ notify_motion(struct wlsc_input_device *device, int x, int y) if (y >= ec->height) y = ec->height - 1; + device->x = x; + device->y = y; es = pick_surface(device, &sx, &sy); if (es) wl_surface_post_event(&es->base, &device->base, WL_INPUT_MOTION, x, y, sx, sy); - device->x = x; - device->y = y; device->pointer_surface->map.x = x - hotspot_x; device->pointer_surface->map.y = y - hotspot_y; -- 2.7.4