mirror of
https://github.com/brl/mutter.git
synced 2024-11-12 17:27:03 -05:00
MetaWaylandSeat: correct logic to set the current / focused surface
The current surface refers to the surface right below the pointer (according to the pick performed by clutter), while the focus surface is the one receiving events. They can be out of sync in case of grabs, in which case we should keep trying to focus the current surface. https://bugzilla.gnome.org/show_bug.cgi?id=706077
This commit is contained in:
parent
0e098249b1
commit
2f3a5f2001
@ -507,14 +507,14 @@ meta_wayland_seat_repick (MetaWaylandSeat *seat,
|
||||
surface = meta_shaped_texture_get_wayland_surface (shaped_texture);
|
||||
}
|
||||
|
||||
if (surface != pointer->current)
|
||||
pointer->current = surface;
|
||||
if (surface != pointer->focus)
|
||||
{
|
||||
const MetaWaylandPointerGrabInterface *interface =
|
||||
pointer->grab->interface;
|
||||
interface->focus (pointer->grab,
|
||||
surface,
|
||||
pointer->current_x, pointer->current_y);
|
||||
pointer->current = surface;
|
||||
}
|
||||
|
||||
if (pointer->grab->focus)
|
||||
|
Loading…
Reference in New Issue
Block a user