x11-display: Handle mapped XIDs per type
Starting from commit 7713006f5
, during X11 disposition we also unmanage the
windows using the xids hash table values list.
However, this is also populated by the X11 Meta barrier implementation and then
contains both Windows and Barriers.
So when going through the values list, check whether we're handling a window or
a barrier and based on that, unmanage or destroy it.
Fixes https://gitlab.gnome.org/GNOME/mutter/issues/624
https://gitlab.gnome.org/GNOME/mutter/merge_requests/605
This commit is contained in:
parent
e94a0fced9
commit
0487d672ed
@ -99,7 +99,6 @@ static void
|
||||
meta_x11_display_unmanage_windows (MetaX11Display *x11_display)
|
||||
{
|
||||
GList *windows, *l;
|
||||
MetaWindow *window;
|
||||
|
||||
if (!x11_display->xids)
|
||||
return;
|
||||
@ -109,10 +108,18 @@ meta_x11_display_unmanage_windows (MetaX11Display *x11_display)
|
||||
|
||||
for (l = windows; l; l = l->next)
|
||||
{
|
||||
window = l->data;
|
||||
if (META_IS_WINDOW (l->data))
|
||||
{
|
||||
MetaWindow *window = l->data;
|
||||
|
||||
if (!window->unmanaging)
|
||||
meta_window_unmanage (window, META_CURRENT_TIME);
|
||||
}
|
||||
else if (META_IS_BARRIER (l->data))
|
||||
meta_barrier_destroy (META_BARRIER (l->data));
|
||||
else
|
||||
g_assert_not_reached ();
|
||||
}
|
||||
g_list_free_full (windows, g_object_unref);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user