Bugfix: fixStack not always called when window receives focus

The primary symptom is that the wrong window is focused next when the current
window is closed. Most easily triggered by quickly letting <super> go when
navigation to the window (from far away).

I'm not sure why the fixStack call was conditioned in the first place?

Probably regression after: 8d3ae51728
This commit is contained in:
Ole Jørgen Brønner
2018-05-17 22:24:12 +02:00
parent acb383249e
commit b703bbb0b0
+3 -1
View File
@@ -1189,7 +1189,8 @@ function focus_handler(meta_window, user_data) {
}
let space = spaces.spaceOfWindow(meta_window);
ensureViewport(meta_window, space) !== undefined && fixStack(space, space.indexOf(meta_window));
ensureViewport(meta_window, space);
fixStack(space, space.indexOf(meta_window));
}
let focus_wrapper = utils.dynamic_function_ref('focus_handler', Me);
@@ -1241,6 +1242,7 @@ let showWrapper = utils.dynamic_function_ref('showHandler', Me);
stack, not the mru, when auto choosing focus after closing a window.
*/
function fixStack(space, around) {
utils.debug("stack", "fix stack");
let mru = global.display.get_tab_list(Meta.TabList.NORMAL,
space.workspace);