aboutsummaryrefslogtreecommitdiffstats
path: root/sway/commands/move.c
diff options
context:
space:
mode:
Diffstat (limited to 'sway/commands/move.c')
-rw-r--r--sway/commands/move.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/sway/commands/move.c b/sway/commands/move.c
index 6fd66f28..2a1993ae 100644
--- a/sway/commands/move.c
+++ b/sway/commands/move.c
@@ -131,6 +131,7 @@ static void container_move_to_container_from_direction(
131 container, index); 131 container, index);
132 } 132 }
133 container->width = container->height = 0; 133 container->width = container->height = 0;
134 container->width_fraction = container->height_fraction = 0;
134 } 135 }
135 return; 136 return;
136 } 137 }
@@ -142,6 +143,7 @@ static void container_move_to_container_from_direction(
142 0 : destination->children->length; 143 0 : destination->children->length;
143 container_insert_child(destination, container, index); 144 container_insert_child(destination, container, index);
144 container->width = container->height = 0; 145 container->width = container->height = 0;
146 container->width_fraction = container->height_fraction = 0;
145 return; 147 return;
146 } 148 }
147 149
@@ -163,6 +165,7 @@ static void container_move_to_workspace_from_direction(
163 struct sway_container *container, struct sway_workspace *workspace, 165 struct sway_container *container, struct sway_workspace *workspace,
164 enum wlr_direction move_dir) { 166 enum wlr_direction move_dir) {
165 container->width = container->height = 0; 167 container->width = container->height = 0;
168 container->width_fraction = container->height_fraction = 0;
166 169
167 if (is_parallel(workspace->layout, move_dir)) { 170 if (is_parallel(workspace->layout, move_dir)) {
168 sway_log(SWAY_DEBUG, "Reparenting container (parallel)"); 171 sway_log(SWAY_DEBUG, "Reparenting container (parallel)");
@@ -206,7 +209,7 @@ static void container_move_to_workspace(struct sway_container *container,
206 } else { 209 } else {
207 container_detach(container); 210 container_detach(container);
208 container->width = container->height = 0; 211 container->width = container->height = 0;
209 container->saved_width = container->saved_height = 0; 212 container->width_fraction = container->height_fraction = 0;
210 workspace_add_tiling(workspace, container); 213 workspace_add_tiling(workspace, container);
211 container_update_representation(container); 214 container_update_representation(container);
212 } 215 }
@@ -234,7 +237,7 @@ static void container_move_to_container(struct sway_container *container,
234 container_detach(container); 237 container_detach(container);
235 container_remove_gaps(container); 238 container_remove_gaps(container);
236 container->width = container->height = 0; 239 container->width = container->height = 0;
237 container->saved_width = container->saved_height = 0; 240 container->width_fraction = container->height_fraction = 0;
238 241
239 if (destination->view) { 242 if (destination->view) {
240 container_add_sibling(destination, container, 1); 243 container_add_sibling(destination, container, 1);