From 0557efcb231d3e252a2c980c8f1bc5efef69de24 Mon Sep 17 00:00:00 2001 From: rcaridade145 Date: Tue, 3 Mar 2020 20:51:17 +0000 Subject: workspace: Don't try to use per-workspace MRU lists as a hint for focusing A prior commit switched from focusing the topmost window as the default window to focusing the MRU window. This was done in alignment with the introduction of per-workspace MRU lists to avoid problems where the window stack was inadvertently changed when focusing windows during window switches. Now that focusing windows don't have as big an impact on the stacking order, we can revert back to focusing the top window, which is less confusing to the user. For now, leave per-workspace MRU lists, as they're a pretty good approximation of a global MRU list, and it works well enough. https://bugzilla.gnome.org/show_bug.cgi?id=620744 Based on commit https://gitlab.gnome.org/GNOME/metacity/-/commit/f628d8f8901f46fa9e00707ae9d7ccfd1e85f427 --- src/core/workspace.h | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'src/core/workspace.h') diff --git a/src/core/workspace.h b/src/core/workspace.h index 7d02861e..b8ea3c97 100644 --- a/src/core/workspace.h +++ b/src/core/workspace.h @@ -52,6 +52,17 @@ struct _MetaWorkspace MetaScreen *screen; GList *windows; + + /* The "MRU list", or "most recently used" list, is a list of + * MetaWindows ordered based on the time the the user interacted + * with the window most recently. + * + * For historical reasons, we keep an MRU list per workspace. + * It used to be used to calculate the default focused window, + * but isn't anymore, as the window next in the stacking order + * can sometimes be not the window the user interacted with last, + */ + GList *mru_list; GList *list_containing_self; -- cgit v1.2.1