Skip to content

x11: Defer ClutterStage focus actor change until window is focused

Carlos Garnacho requested to merge carlosg/mutter:wip/x11-focus-change-fix into main

If we happen to be changing focus to a window while taking focus away from Clutter widgetry, we would unintendedly trigger reentrance in a way that the old focused window remained in focus, by asking to focus the default focus window in an untimely manner.

To handle this reentrancy, delay dropping the Clutter key focus until the window focus changed, so that the focus change will look up the default focused window in the workspace, and find the up to date one.

Fixes: ae102ee3 ("x11: Refactor ClutterStage key focus management")

Merge request reports