subcompositor: consider mapping after adding

ec8b49c93f calls subsurface_consider_map()
too early. Instead, call it after emitting new_subsurface signal to let
compositors receive a map event.
This commit is contained in:
Kirill Primak 2022-09-12 19:03:35 +03:00 committed by Simon Ser
parent 3abedaf211
commit 42ae1e75aa
1 changed files with 1 additions and 2 deletions

View File

@ -367,6 +367,7 @@ void subsurface_handle_parent_commit(struct wlr_subsurface *subsurface) {
subsurface->added = true;
wl_signal_emit_mutable(&subsurface->parent->events.new_subsurface,
subsurface);
subsurface_consider_map(subsurface, true);
}
}
@ -414,8 +415,6 @@ static struct wlr_subsurface *subsurface_create(struct wlr_surface *surface,
surface->role_data = subsurface;
subsurface_consider_map(subsurface, true);
return subsurface;
}