aboutsummaryrefslogtreecommitdiffstats
path: root/sway/commands/layout.c
diff options
context:
space:
mode:
authorLibravatar Tony Crisci <tony@dubstepdish.com>2018-03-29 17:06:29 -0400
committerLibravatar Tony Crisci <tony@dubstepdish.com>2018-03-29 17:06:29 -0400
commiteca029f218fbb54ddf7316845be5d296e834358e (patch)
tree76bf346c980ad94c68797cefbd2ec4a9302dd53f /sway/commands/layout.c
parentrename container functions (diff)
downloadsway-eca029f218fbb54ddf7316845be5d296e834358e.tar.gz
sway-eca029f218fbb54ddf7316845be5d296e834358e.tar.zst
sway-eca029f218fbb54ddf7316845be5d296e834358e.zip
more renaming things
Diffstat (limited to 'sway/commands/layout.c')
-rw-r--r--sway/commands/layout.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/sway/commands/layout.c b/sway/commands/layout.c
index e10334e2..e9cfeb8f 100644
--- a/sway/commands/layout.c
+++ b/sway/commands/layout.c
@@ -26,10 +26,10 @@ struct cmd_results *cmd_layout(int argc, char **argv) {
26 // TODO: stacks and tabs 26 // TODO: stacks and tabs
27 27
28 if (strcasecmp(argv[0], "default") == 0) { 28 if (strcasecmp(argv[0], "default") == 0) {
29 swayc_change_layout(parent, parent->prev_layout); 29 container_set_layout(parent, parent->prev_layout);
30 if (parent->layout == L_NONE) { 30 if (parent->layout == L_NONE) {
31 struct sway_container *output = sway_container_parent(parent, C_OUTPUT); 31 struct sway_container *output = container_parent(parent, C_OUTPUT);
32 swayc_change_layout(parent, default_layout(output)); 32 container_set_layout(parent, container_get_default_layout(output));
33 } 33 }
34 } else { 34 } else {
35 if (parent->layout != L_TABBED && parent->layout != L_STACKED) { 35 if (parent->layout != L_TABBED && parent->layout != L_STACKED) {
@@ -37,20 +37,20 @@ struct cmd_results *cmd_layout(int argc, char **argv) {
37 } 37 }
38 38
39 if (strcasecmp(argv[0], "splith") == 0) { 39 if (strcasecmp(argv[0], "splith") == 0) {
40 swayc_change_layout(parent, L_HORIZ); 40 container_set_layout(parent, L_HORIZ);
41 } else if (strcasecmp(argv[0], "splitv") == 0) { 41 } else if (strcasecmp(argv[0], "splitv") == 0) {
42 swayc_change_layout(parent, L_VERT); 42 container_set_layout(parent, L_VERT);
43 } else if (strcasecmp(argv[0], "toggle") == 0 && argc == 2 && strcasecmp(argv[1], "split") == 0) { 43 } else if (strcasecmp(argv[0], "toggle") == 0 && argc == 2 && strcasecmp(argv[1], "split") == 0) {
44 if (parent->layout == L_HORIZ && (parent->workspace_layout == L_NONE 44 if (parent->layout == L_HORIZ && (parent->workspace_layout == L_NONE
45 || parent->workspace_layout == L_HORIZ)) { 45 || parent->workspace_layout == L_HORIZ)) {
46 swayc_change_layout(parent, L_VERT); 46 container_set_layout(parent, L_VERT);
47 } else { 47 } else {
48 swayc_change_layout(parent, L_HORIZ); 48 container_set_layout(parent, L_HORIZ);
49 } 49 }
50 } 50 }
51 } 51 }
52 52
53 arrange_windows(parent, parent->width, parent->height); 53 container_arrange_windows(parent, parent->width, parent->height);
54 54
55 return cmd_results_new(CMD_SUCCESS, NULL, NULL); 55 return cmd_results_new(CMD_SUCCESS, NULL, NULL);
56} 56}