mirror of
https://github.com/brl/mutter.git
synced 2024-11-10 07:56:14 -05:00
xwayland: Check MetaDndBridge focus_window when updating X11 proxy window
We are keeping accounting of the focus window as seen by the DnD bridge right here, so use it instead of the MetaWaylandDragGrab focus as it may lag behind the real focus (i.e. till the drag source notices the window and sends XdndEnter to it). This leads to the window trying to be repositioned more often than necessary when the drag source takes long to send the XdndEnter client message, and maybe not repositioned at all if the pointer leaves the surface while no XdndEnter message was received. https://bugzilla.gnome.org/show_bug.cgi?id=763246
This commit is contained in:
parent
21b2eff334
commit
572610d01e
@ -1359,11 +1359,11 @@ repick_drop_surface (MetaWaylandCompositor *compositor,
|
||||
MetaWaylandSurface *focus = NULL;
|
||||
|
||||
focus = pick_drop_surface (compositor, event);
|
||||
dnd->focus_surface = focus;
|
||||
|
||||
if (meta_wayland_drag_grab_get_focus (drag_grab) == focus)
|
||||
if (dnd->focus_surface == focus)
|
||||
return;
|
||||
|
||||
dnd->focus_surface = focus;
|
||||
|
||||
if (focus &&
|
||||
focus->window->client_type == META_WINDOW_CLIENT_TYPE_WAYLAND)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user