mirror of
https://github.com/brl/mutter.git
synced 2024-11-26 01:50:42 -05:00
wayland/legacy-xdg-shell: Cache frame callbacks if toplevel is unmanaged
A toplevel window can be unmanaged without the client knowing it (e.g. a
modal dialog being unmapped together with its parent. When this has
happened, take frame callbacks queued on a commit and cache them on the
generic surface queue. If the toplevel is to be remapped because the
surface was reassigned the toplevel role, the cached frame callbacks
will be queued on the surface actor and dispatched accordingly.
https://gitlab.gnome.org/GNOME/mutter/issues/240
(cherry picked from commit a740f50cd7
)
This commit is contained in:
parent
58cc091134
commit
30820ab19e
@ -598,11 +598,18 @@ meta_wayland_zxdg_toplevel_v6_commit (MetaWaylandSurfaceRole *surface_role,
|
|||||||
MetaWaylandSurfaceRoleClass *surface_role_class;
|
MetaWaylandSurfaceRoleClass *surface_role_class;
|
||||||
MetaWaylandSurface *surface =
|
MetaWaylandSurface *surface =
|
||||||
meta_wayland_surface_role_get_surface (surface_role);
|
meta_wayland_surface_role_get_surface (surface_role);
|
||||||
MetaWindow *window = surface->window;
|
MetaWindow *window;
|
||||||
MetaRectangle window_geometry;
|
MetaRectangle window_geometry;
|
||||||
MetaRectangle old_geometry;
|
MetaRectangle old_geometry;
|
||||||
gboolean geometry_changed;
|
gboolean geometry_changed;
|
||||||
|
|
||||||
|
window = surface->window;
|
||||||
|
if (!window)
|
||||||
|
{
|
||||||
|
meta_wayland_surface_cache_pending_frame_callbacks (surface, pending);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
old_geometry = xdg_surface_priv->geometry;
|
old_geometry = xdg_surface_priv->geometry;
|
||||||
|
|
||||||
surface_role_class =
|
surface_role_class =
|
||||||
|
Loading…
Reference in New Issue
Block a user