wayland/subsurface: Hold surface reference in placement ops
Will be necessary with the next commit. Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3737>
This commit is contained in:
parent
ba93fcd30f
commit
ad22833cc3
@ -318,7 +318,7 @@ get_subsurface_placement_op (MetaWaylandSurface *surface,
|
|||||||
GNode *sibling_node;
|
GNode *sibling_node;
|
||||||
|
|
||||||
op->placement = placement;
|
op->placement = placement;
|
||||||
op->surface = surface;
|
op->surface = g_object_ref (surface);
|
||||||
|
|
||||||
g_node_unlink (surface->committed_state.subsurface_branch_node);
|
g_node_unlink (surface->committed_state.subsurface_branch_node);
|
||||||
|
|
||||||
@ -352,6 +352,7 @@ get_subsurface_placement_op (MetaWaylandSurface *surface,
|
|||||||
void
|
void
|
||||||
meta_wayland_subsurface_destroy_placement_op (MetaWaylandSubsurfacePlacementOp *op)
|
meta_wayland_subsurface_destroy_placement_op (MetaWaylandSubsurfacePlacementOp *op)
|
||||||
{
|
{
|
||||||
|
g_clear_object (&op->surface);
|
||||||
g_clear_object (&op->sibling);
|
g_clear_object (&op->sibling);
|
||||||
g_free (op);
|
g_free (op);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user