summaryrefslogtreecommitdiffstats
path: root/sway
diff options
context:
space:
mode:
Diffstat (limited to 'sway')
-rw-r--r--sway/tree/view.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/sway/tree/view.c b/sway/tree/view.c
index cb36f123..2ca0dbbb 100644
--- a/sway/tree/view.c
+++ b/sway/tree/view.c
@@ -542,14 +542,16 @@ void view_map(struct sway_view *view, struct wlr_surface *wlr_surface) {
542struct sway_container *view_unmap(struct sway_view *view) { 542struct sway_container *view_unmap(struct sway_view *view) {
543 wl_signal_emit(&view->events.unmap, view); 543 wl_signal_emit(&view->events.unmap, view);
544 544
545 wl_list_remove(&view->surface_new_subsurface.link);
546 wl_list_remove(&view->container_reparent.link);
547
545 if (view->is_fullscreen) { 548 if (view->is_fullscreen) {
546 struct sway_container *ws = container_parent(view->swayc, C_WORKSPACE); 549 struct sway_container *ws = container_parent(view->swayc, C_WORKSPACE);
547 ws->sway_workspace->fullscreen = NULL; 550 ws->sway_workspace->fullscreen = NULL;
551 container_destroy(view->swayc);
552 return ws;
548 } 553 }
549 554
550 wl_list_remove(&view->surface_new_subsurface.link);
551 wl_list_remove(&view->container_reparent.link);
552
553 return container_destroy(view->swayc); 555 return container_destroy(view->swayc);
554} 556}
555 557