commit 5c042c55ce83cf21a5d3e6a85357c778651b28d6
parent e9ac0492b7ec55d34d9209f2ff3e08de5c014d65
Author: Drew DeVault <sir@cmpwn.com>
Date: Sun, 6 Nov 2016 09:03:59 -0700
Merge pull request #966 from thejan2009/layout-toggle
Change layout toggle to default on horizontal split
Diffstat:
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/sway/commands/layout.c b/sway/commands/layout.c
@@ -49,10 +49,10 @@ struct cmd_results *cmd_layout(int argc, char **argv) {
} else if (strcasecmp(argv[0], "splitv") == 0) {
parent->layout = L_VERT;
} else if (strcasecmp(argv[0], "toggle") == 0 && argc == 2 && strcasecmp(argv[1], "split") == 0) {
- if (parent->layout == L_VERT) {
- parent->layout = L_HORIZ;
- } else {
+ if (parent->layout == L_HORIZ) {
parent->layout = L_VERT;
+ } else {
+ parent->layout = L_HORIZ;
}
}
}