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: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/2791>
This commit is contained in:
Carlos Garnacho 2023-01-16 15:18:15 +01:00
parent 0fff52ee28
commit 909eaa117d

View File

@ -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