From 30fd16dae73fa730347d89a1d6ee8c3360de1e62 Mon Sep 17 00:00:00 2001 From: Derek Foreman Date: Thu, 8 Aug 2024 08:02:09 -0500 Subject: [PATCH] desktop-shell: check view mappedness in desktop_surface_removed A "mapped" surface need not have a primary output assigned, or be in a state such that it needs a fade out animation. The view being mapped is what we should be testing here. Signed-off-by: Derek Foreman --- desktop-shell/shell.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/desktop-shell/shell.c b/desktop-shell/shell.c index 430660f6..69e72464 100644 --- a/desktop-shell/shell.c +++ b/desktop-shell/shell.c @@ -2165,7 +2165,7 @@ desktop_surface_removed(struct weston_desktop_surface *desktop_surface, weston_desktop_surface_set_user_data(shsurf->desktop_surface, NULL); shsurf->desktop_surface = NULL; - if (weston_surface_is_mapped(surface) && + if (weston_view_is_mapped(shsurf->view) && shsurf->shell->win_close_animation_type == ANIMATION_FADE) { if (shsurf->shell->compositor->state == WESTON_COMPOSITOR_ACTIVE &&