summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarlos Garnacho <carlosg@gnome.org>2014-10-20 18:41:22 +0200
committerCarlos Garnacho <carlosg@gnome.org>2014-10-23 16:53:44 +0200
commit7c5989c978ed6ca0fc0e86b5642ae122bef0a814 (patch)
tree68476c666cf03aad87e55c8f58d1e909aad586aa
parent8819d9ce66a33f73f84d9105091302420b1d498c (diff)
downloadmutter-7c5989c978ed6ca0fc0e86b5642ae122bef0a814.tar.gz
wayland: Avoid MetaWindow call on non window-backed surfaces
Crossing events may also be gotten on subsurfaces. https://bugzilla.gnome.org/show_bug.cgi?id=738890
-rw-r--r--src/wayland/meta-wayland-pointer.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/wayland/meta-wayland-pointer.c b/src/wayland/meta-wayland-pointer.c
index 9f6c264d9..b7a36f571 100644
--- a/src/wayland/meta-wayland-pointer.c
+++ b/src/wayland/meta-wayland-pointer.c
@@ -518,10 +518,11 @@ meta_wayland_pointer_set_focus (MetaWaylandPointer *pointer,
clutter_input_device_get_coords (pointer->device, NULL, &pos);
- meta_window_handle_enter (pointer->focus_surface->window,
- /* XXX -- can we reliably get a timestamp for setting focus? */
- clutter_get_current_event_time (),
- pos.x, pos.y);
+ if (pointer->focus_surface->window)
+ meta_window_handle_enter (pointer->focus_surface->window,
+ /* XXX -- can we reliably get a timestamp for setting focus? */
+ clutter_get_current_event_time (),
+ pos.x, pos.y);
move_resources_for_client (&pointer->focus_resource_list,
&pointer->resource_list,