xwayland: handle rare case of focus_in event occurring before map

This fixes a timing-dependent issue where the CLion main window was
sometimes not correctly focused at startup.
This commit is contained in:
John Lindgren 2025-06-11 15:10:10 -04:00 committed by Johan Malm
parent d7f1b021b3
commit 5a1466d355
2 changed files with 32 additions and 0 deletions

View file

@ -39,6 +39,7 @@ struct xwayland_unmanaged {
struct xwayland_view {
struct view base;
struct wlr_xwayland_surface *xwayland_surface;
bool focused_before_map;
/* Events unique to XWayland views */
struct wl_listener associate;