From: Kristian Høgsberg Date: Wed, 13 Apr 2011 15:52:54 +0000 (-0400) Subject: Only invoke shell button bindings if there's a pointer focus surface X-Git-Tag: upstream/0.1.8~3503 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=10f097e8dd174ec6f06cf4498aa2b27c2173c314;p=profile%2Fivi%2Fweston-ivi-shell.git Only invoke shell button bindings if there's a pointer focus surface --- diff --git a/compositor/shell.c b/compositor/shell.c index c480e9a..c842b97 100644 --- a/compositor/shell.c +++ b/compositor/shell.c @@ -671,6 +671,9 @@ move_binding(struct wl_input_device *device, uint32_t time, struct wlsc_surface *surface = (struct wlsc_surface *) device->pointer_focus; + if (surface == NULL) + return; + shell_move(NULL, (struct wl_shell *) &compositor->shell, &surface->surface, device, time); @@ -686,6 +689,9 @@ resize_binding(struct wl_input_device *device, uint32_t time, uint32_t edges = 0; int32_t x, y; + if (surface == NULL) + return; + x = device->grab_x - surface->x; y = device->grab_y - surface->y;