From 8c4610721a117d5d50fc72fb75e41a6727d93b2d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Florian=20M=C3=BCllner?= Date: Wed, 7 May 2014 23:22:41 +0200 Subject: [PATCH] window: Fix delayed mouse mode on X Using meta_stack_get_default_focus_window_at_point() is unreliable when used with the overlay windows or popups. Instead, we can just look up the MetaWindow for the client window that XIQueryPointer returns. https://bugzilla.gnome.org/show_bug.cgi?id=730541 --- src/core/display.c | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/src/core/display.c b/src/core/display.c index 435d9d9..b7688e6 100644 --- a/src/core/display.c +++ b/src/core/display.c @@ -1703,17 +1703,7 @@ window_focus_on_pointer_rest_callback (gpointer data) { return TRUE; } - /* Explicitly check for the overlay window, as get_focus_window_at_point() - * may return windows that extend underneath the chrome (like - * override-redirect or DESKTOP windows) - */ - if (child == meta_get_overlay_window (screen)) - goto out; - - window = - meta_stack_get_default_focus_window_at_point (screen->stack, - screen->active_workspace, - None, root_x, root_y); + window = meta_display_lookup_x_window (display, child); if (window == NULL) goto out; -- 2.1.0