Commit a8581795 authored by Olivier Fourdan's avatar Olivier Fourdan
Browse files

xwayland: Fix LeaveNotify for relative pointer

Since commit 20c78f38

, we use the relative pointer for enter/leave

However, sprite_check_lost_focus() which verifies whether the pointer has
left an Xwayland surface still explicitly check for the absolute

As a result, no LeaveNotify event is emitted anymore now when the
pointer crosses from an Xwayland surface to a Wayland native one.

Make sure to check the last slave device against get_pointer_event() as
well, not just the absolute pointer.
Signed-off-by: default avatarOlivier Fourdan <>
Acked-by: Martin Peres's avatarMartin Peres <>
Acked-by: Roman Gilg's avatarRoman Gilg <>
Tested-by: Roman Gilg's avatarRoman Gilg <>
Reviewed-by: Peter Hutterer's avatarPeter Hutterer <>
Fixes: 20c78f38 - xwayland: use get_pointer_device() for enter/leave
                  handling too
(cherry picked from commit d7391f38)
parent f20dc979
Pipeline #284060 passed with stages
in 1 minute and 52 seconds
......@@ -2652,7 +2652,7 @@ sprite_check_lost_focus(SpritePtr sprite, WindowPtr window)
* devices so we can find out the xwl_seat, but those don't actually own
* their sprite, so the match doesn't mean a lot.
if (master->lastSlave != xwl_seat->pointer)
if (master->lastSlave != get_pointer_device(xwl_seat))
return FALSE;
if (xwl_seat->focus_window != NULL &&
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment