From dad57ad0a0afe3fe249b0d39df5e511efe4960c0 Mon Sep 17 00:00:00 2001 From: Jarek Janik Date: Wed, 11 Oct 2023 03:37:00 +0200 Subject: [PATCH] Fix "Toggle raise and lower" functionality Fix "Toggle raise and lower" functionality for a case when there are windows in higher layers present on the same desktop; a window that is being acted upon could never be top-most in such a case, which prevented it from being lowered by "Toggle raise and lower" action. Checking if a window is top-most now uses unconstrained_stacking_order list, which reflects user-requested stacking window order, but doesn't know anything about layers, and that in turn allows any window that user has raised most recently to be lowered by "Toggle raise and lower" (even if this window is not actually top-most, because of windows in higher layers). BUG: 440540 --- src/layers.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/layers.cpp b/src/layers.cpp index b7d7759c04..a476a472ea 100644 --- a/src/layers.cpp +++ b/src/layers.cpp @@ -290,7 +290,7 @@ void Workspace::raiseOrLowerWindow(Window *window) const Window *topmost = topWindowOnDesktop(VirtualDesktopManager::self()->currentDesktop(), - options->isSeparateScreenFocus() ? window->output() : nullptr); + options->isSeparateScreenFocus() ? window->output() : nullptr, true); if (window == topmost) { lowerWindow(window);