aboutsummaryrefslogtreecommitdiff
path: root/sway/commands/move.c
diff options
context:
space:
mode:
authorD.B <thejan.2009@gmail.com>2016-10-10 20:44:09 +0200
committerD.B <thejan.2009@gmail.com>2016-10-11 09:16:59 +0200
commit571321a1d84a1eb2867fbdc39f7f828aa2c64a01 (patch)
treead61090d261ccec47efc36b19f2b7266a01c1bdc /sway/commands/move.c
parent0ddc4279d1f4e6e161c36eae31fa32c950ad0c71 (diff)
add workspace_layout, ensure ws is always L_HORIZ
Add swayc_change_layout function, which changes either layout or workspace_layout, depending on the container type. Workspace being always L_HORIZ makes this much more i3-compatible.
Diffstat (limited to 'sway/commands/move.c')
-rw-r--r--sway/commands/move.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sway/commands/move.c b/sway/commands/move.c
index 48e9d562..4819d9ef 100644
--- a/sway/commands/move.c
+++ b/sway/commands/move.c
@@ -37,7 +37,7 @@ struct cmd_results *cmd_move(int argc, char **argv) {
if (!view->children || view->children->length == 0) {
return cmd_results_new(CMD_FAILURE, "move", "Cannot move an empty workspace");
}
- view = new_container(view, view->layout);
+ view = new_container(view, view->workspace_layout);
} if (view->type != C_CONTAINER && view->type != C_VIEW) {
return cmd_results_new(CMD_FAILURE, "move", "Can only move containers and views.");
}
@@ -65,7 +65,7 @@ struct cmd_results *cmd_move(int argc, char **argv) {
if (!view->children || view->children->length == 0) {
return cmd_results_new(CMD_FAILURE, "move", "Cannot move an empty workspace");
}
- view = new_container(view, view->layout);
+ view = new_container(view, view->workspace_layout);
} else if (view->type != C_CONTAINER && view->type != C_VIEW) {
return cmd_results_new(CMD_FAILURE, "move", "Can only move containers and views.");
} else if (!(output = output_by_name(argv[3], &abs_pos))) {