diff options
author | Tony Crisci <tony@dubstepdish.com> | 2018-04-02 22:37:21 -0400 |
---|---|---|
committer | Tony Crisci <tony@dubstepdish.com> | 2018-04-02 22:37:21 -0400 |
commit | 2992b72d61933568476e2bf4baf573e714f9ed40 (patch) | |
tree | 0682e081d94d73ef2b4b9a7f8d1646c11bb33b8e /sway/tree/view.c | |
parent | fix more close segfaults (diff) | |
download | sway-2992b72d61933568476e2bf4baf573e714f9ed40.tar.gz sway-2992b72d61933568476e2bf4baf573e714f9ed40.tar.zst sway-2992b72d61933568476e2bf4baf573e714f9ed40.zip |
change reap container approach
Diffstat (limited to 'sway/tree/view.c')
-rw-r--r-- | sway/tree/view.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/sway/tree/view.c b/sway/tree/view.c index 4e695b5f..eeadc5d8 100644 --- a/sway/tree/view.c +++ b/sway/tree/view.c | |||
@@ -78,14 +78,12 @@ void view_close(struct sway_view *view) { | |||
78 | } | 78 | } |
79 | } | 79 | } |
80 | 80 | ||
81 | struct sway_container *container_view_destroy(struct sway_container *view) { | 81 | void container_view_destroy(struct sway_container *view) { |
82 | if (!view) { | 82 | if (!view) { |
83 | return NULL; | 83 | return; |
84 | } | 84 | } |
85 | wlr_log(L_DEBUG, "Destroying view '%s'", view->name); | 85 | wlr_log(L_DEBUG, "Destroying view '%s'", view->name); |
86 | struct sway_container *parent = container_destroy(view); | 86 | container_destroy(view); |
87 | arrange_windows(&root_container, -1, -1); | ||
88 | return parent; | ||
89 | } | 87 | } |
90 | 88 | ||
91 | void view_damage_whole(struct sway_view *view) { | 89 | void view_damage_whole(struct sway_view *view) { |
@@ -164,6 +162,8 @@ void view_unmap(struct sway_view *view) { | |||
164 | 162 | ||
165 | view->swayc = NULL; | 163 | view->swayc = NULL; |
166 | view->surface = NULL; | 164 | view->surface = NULL; |
165 | |||
166 | arrange_windows(&root_container, -1, -1); | ||
167 | } | 167 | } |
168 | 168 | ||
169 | void view_update_position(struct sway_view *view, double ox, double oy) { | 169 | void view_update_position(struct sway_view *view, double ox, double oy) { |