From 55cb27fd15bf2923e705c983a30c547d32c9a9e9 Mon Sep 17 00:00:00 2001 From: Joshua Ashton Date: Tue, 1 Feb 2022 21:50:06 +0000 Subject: [PATCH] steamcompmgr: Fix X's idea of interactive focus Always update X's idea of focus, but still dirty the it being outdated so we can resolve that globally later. Only affecting X and not the WL idea of focus here, we always want to think the window is focused. but our real presenting focus and input focus can be elsewhere. --- src/steamcompmgr.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/steamcompmgr.cpp b/src/steamcompmgr.cpp index fdf18cb..e855bc8 100644 --- a/src/steamcompmgr.cpp +++ b/src/steamcompmgr.cpp @@ -2072,6 +2072,15 @@ found:; out->focusWindow = focus; else out->outdatedInteractiveFocus = true; + + // Always update X's idea of focus, but still dirty + // the it being outdated so we can resolve that globally later. + // + // Only affecting X and not the WL idea of focus here, + // we always want to think the window is focused. + // but our real presenting focus and input focus can be elsewhere. + if ( !globalFocus ) + out->focusWindow = focus; } out->overrideWindow = override_focus;