From e32557131ee8d3dc464ba2ed88161e1aede4748e Mon Sep 17 00:00:00 2001 From: Daniel Stone Date: Tue, 11 Jul 2023 17:14:27 +0100 Subject: [PATCH] desktop-shell: Simplify confusing conditional The only place we ever set shsurf->fullscreen.black_view is when we're going into fullscreen, and we destroy it when we're going out of fullscreen. Hence if we do ever have a fullscreen black view, we should move it out of the way. Signed-off-by: Daniel Stone --- desktop-shell/shell.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/desktop-shell/shell.c b/desktop-shell/shell.c index 1bdb4ab1..087fa7ce 100644 --- a/desktop-shell/shell.c +++ b/desktop-shell/shell.c @@ -3664,12 +3664,8 @@ lower_fullscreen_layer(struct desktop_shell *shell, if (lowering_output && (shsurf->fullscreen_output != lowering_output)) continue; - /* We can have a non-fullscreen popup for a fullscreen surface - * in the fullscreen layer. */ - if (weston_desktop_surface_get_fullscreen(shsurf->desktop_surface) && - shsurf->fullscreen.black_view) { + if (shsurf->fullscreen.black_view) weston_view_move_to_layer(shsurf->fullscreen.black_view->view, NULL); - } /* Lower the view to the workspace layer */ weston_view_move_to_layer(view, &ws->layer.view_list);