From 909eaa117de382639b8c6728621b1aeb14989bec Mon Sep 17 00:00:00 2001 From: Carlos Garnacho Date: Mon, 16 Jan 2023 15:18:15 +0100 Subject: [PATCH] core: Delete _MUTTER_NEEDS_FRAME property when destroying frame If the window is unmapped or otherwise unmanaged while still existing, we would fail to let the frames client follow up in destroying the frame for the window. Delete the _MUTTER_NEEDS_FRAME property, so that the frames client can react to meta_window_destroy_frame(), this avoids stale invisible frame windows for clients that simply unmap windows to reuse them later. Part-of: --- src/core/frame.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/core/frame.c b/src/core/frame.c index a61d41de2..470f5d174 100644 --- a/src/core/frame.c +++ b/src/core/frame.c @@ -211,6 +211,10 @@ meta_window_destroy_frame (MetaWindow *window) window->reparents_pending += 1; } + XDeleteProperty (x11_display->xdisplay, + window->xwindow, + x11_display->atom__MUTTER_NEEDS_FRAME); + meta_x11_error_trap_pop (x11_display); /* Ensure focus is restored after the unmap/map events triggered