aboutsummaryrefslogtreecommitdiff
path: root/sway
diff options
context:
space:
mode:
Diffstat (limited to 'sway')
-rw-r--r--sway/commands/exec_always.c4
-rw-r--r--sway/commands/focus.c5
-rw-r--r--sway/commands/kill.c2
-rw-r--r--sway/commands/layout.c4
-rw-r--r--sway/commands/reload.c2
-rw-r--r--sway/commands/workspace.c2
-rw-r--r--sway/config.c2
-rw-r--r--sway/criteria.c4
-rw-r--r--sway/desktop/layer_shell.c2
-rw-r--r--sway/desktop/output.c6
-rw-r--r--sway/desktop/wl_shell.c6
-rw-r--r--sway/desktop/xdg_shell_v6.c6
-rw-r--r--sway/desktop/xwayland.c6
-rw-r--r--sway/input/cursor.c2
-rw-r--r--sway/input/seat.c4
-rw-r--r--sway/ipc-json.c2
-rw-r--r--sway/main.c2
-rw-r--r--sway/tree/container.c10
-rw-r--r--sway/tree/layout.c6
-rw-r--r--sway/tree/view.c7
-rw-r--r--sway/tree/workspace.c4
21 files changed, 44 insertions, 44 deletions
diff --git a/sway/commands/exec_always.c b/sway/commands/exec_always.c
index 61870c51..954950e7 100644
--- a/sway/commands/exec_always.c
+++ b/sway/commands/exec_always.c
@@ -6,8 +6,8 @@
#include <unistd.h>
#include "sway/commands.h"
#include "sway/config.h"
-#include "sway/container.h"
-#include "sway/workspace.h"
+#include "sway/tree/container.h"
+#include "sway/tree/workspace.h"
#include "log.h"
#include "stringop.h"
diff --git a/sway/commands/focus.c b/sway/commands/focus.c
index f1a8078f..18e9e0bf 100644
--- a/sway/commands/focus.c
+++ b/sway/commands/focus.c
@@ -3,10 +3,11 @@
#include "log.h"
#include "sway/input/input-manager.h"
#include "sway/input/seat.h"
-#include "sway/view.h"
+#include "sway/tree/view.h"
#include "sway/commands.h"
-static bool parse_movement_direction(const char *name, enum movement_direction *out) {
+static bool parse_movement_direction(const char *name,
+ enum movement_direction *out) {
if (strcasecmp(name, "left") == 0) {
*out = MOVE_LEFT;
} else if (strcasecmp(name, "right") == 0) {
diff --git a/sway/commands/kill.c b/sway/commands/kill.c
index f408ce2a..c0faed7a 100644
--- a/sway/commands/kill.c
+++ b/sway/commands/kill.c
@@ -2,7 +2,7 @@
#include "log.h"
#include "sway/input/input-manager.h"
#include "sway/input/seat.h"
-#include "sway/view.h"
+#include "sway/tree/view.h"
#include "sway/commands.h"
struct cmd_results *cmd_kill(int argc, char **argv) {
diff --git a/sway/commands/layout.c b/sway/commands/layout.c
index b0fc5d66..2b193136 100644
--- a/sway/commands/layout.c
+++ b/sway/commands/layout.c
@@ -1,8 +1,8 @@
#include <string.h>
#include <strings.h>
#include "sway/commands.h"
-#include "sway/container.h"
-#include "sway/layout.h"
+#include "sway/tree/container.h"
+#include "sway/tree/layout.h"
#include "log.h"
struct cmd_results *cmd_layout(int argc, char **argv) {
diff --git a/sway/commands/reload.c b/sway/commands/reload.c
index d54d40db..8cef789b 100644
--- a/sway/commands/reload.c
+++ b/sway/commands/reload.c
@@ -1,6 +1,6 @@
#include "sway/commands.h"
#include "sway/config.h"
-#include "sway/layout.h"
+#include "sway/tree/layout.h"
struct cmd_results *cmd_reload(int argc, char **argv) {
struct cmd_results *error = NULL;
diff --git a/sway/commands/workspace.c b/sway/commands/workspace.c
index fa891398..8751dffe 100644
--- a/sway/commands/workspace.c
+++ b/sway/commands/workspace.c
@@ -4,7 +4,7 @@
#include "sway/commands.h"
#include "sway/config.h"
#include "sway/input/seat.h"
-#include "sway/workspace.h"
+#include "sway/tree/workspace.h"
#include "list.h"
#include "log.h"
#include "stringop.h"
diff --git a/sway/config.c b/sway/config.c
index 213e7680..0b29735a 100644
--- a/sway/config.c
+++ b/sway/config.c
@@ -24,7 +24,7 @@
#include "sway/input/seat.h"
#include "sway/commands.h"
#include "sway/config.h"
-#include "sway/layout.h"
+#include "sway/tree/layout.h"
#include "readline.h"
#include "stringop.h"
#include "list.h"
diff --git a/sway/criteria.c b/sway/criteria.c
index 2eee331c..b8b581ed 100644
--- a/sway/criteria.c
+++ b/sway/criteria.c
@@ -4,9 +4,9 @@
#include <stdbool.h>
#include <pcre.h>
#include "sway/criteria.h"
-#include "sway/container.h"
+#include "sway/tree/container.h"
#include "sway/config.h"
-#include "sway/view.h"
+#include "sway/tree/view.h"
#include "stringop.h"
#include "list.h"
#include "log.h"
diff --git a/sway/desktop/layer_shell.c b/sway/desktop/layer_shell.c
index bd62f84a..137b3260 100644
--- a/sway/desktop/layer_shell.c
+++ b/sway/desktop/layer_shell.c
@@ -7,7 +7,7 @@
#include <wlr/types/wlr_output.h>
#include <wlr/util/log.h>
#include "sway/layers.h"
-#include "sway/layout.h"
+#include "sway/tree/layout.h"
#include "sway/output.h"
#include "sway/server.h"
diff --git a/sway/desktop/output.c b/sway/desktop/output.c
index 9e7fbcc6..debda396 100644
--- a/sway/desktop/output.c
+++ b/sway/desktop/output.c
@@ -11,14 +11,14 @@
#include <wlr/types/wlr_surface.h>
#include <wlr/types/wlr_wl_shell.h>
#include "log.h"
-#include "sway/container.h"
+#include "sway/tree/container.h"
#include "sway/input/input-manager.h"
#include "sway/input/seat.h"
#include "sway/layers.h"
-#include "sway/layout.h"
+#include "sway/tree/layout.h"
#include "sway/output.h"
#include "sway/server.h"
-#include "sway/view.h"
+#include "sway/tree/view.h"
/**
* Rotate a child's position relative to a parent. The parent size is (pw, ph),
diff --git a/sway/desktop/wl_shell.c b/sway/desktop/wl_shell.c
index 0356aa81..bb97fad4 100644
--- a/sway/desktop/wl_shell.c
+++ b/sway/desktop/wl_shell.c
@@ -3,10 +3,10 @@
#include <stdlib.h>
#include <wayland-server.h>
#include <wlr/types/wlr_wl_shell.h>
-#include "sway/container.h"
-#include "sway/layout.h"
+#include "sway/tree/container.h"
+#include "sway/tree/layout.h"
#include "sway/server.h"
-#include "sway/view.h"
+#include "sway/tree/view.h"
#include "sway/input/seat.h"
#include "sway/input/input-manager.h"
#include "log.h"
diff --git a/sway/desktop/xdg_shell_v6.c b/sway/desktop/xdg_shell_v6.c
index 7bc17149..25ffacbb 100644
--- a/sway/desktop/xdg_shell_v6.c
+++ b/sway/desktop/xdg_shell_v6.c
@@ -3,10 +3,10 @@
#include <stdlib.h>
#include <wayland-server.h>
#include <wlr/types/wlr_xdg_shell_v6.h>
-#include "sway/container.h"
-#include "sway/layout.h"
+#include "sway/tree/container.h"
+#include "sway/tree/layout.h"
#include "sway/server.h"
-#include "sway/view.h"
+#include "sway/tree/view.h"
#include "sway/input/seat.h"
#include "sway/input/input-manager.h"
#include "log.h"
diff --git a/sway/desktop/xwayland.c b/sway/desktop/xwayland.c
index f9b5242b..7f66f746 100644
--- a/sway/desktop/xwayland.c
+++ b/sway/desktop/xwayland.c
@@ -5,10 +5,10 @@
#include <wlr/xwayland.h>
#include <wlr/types/wlr_output_layout.h>
#include <wlr/types/wlr_output.h>
-#include "sway/container.h"
-#include "sway/layout.h"
+#include "sway/tree/container.h"
+#include "sway/tree/layout.h"
#include "sway/server.h"
-#include "sway/view.h"
+#include "sway/tree/view.h"
#include "sway/output.h"
#include "sway/input/seat.h"
#include "sway/input/input-manager.h"
diff --git a/sway/input/cursor.c b/sway/input/cursor.c
index 8a0d1df5..c0e14265 100644
--- a/sway/input/cursor.c
+++ b/sway/input/cursor.c
@@ -7,7 +7,7 @@
#include <wlr/types/wlr_cursor.h>
#include <wlr/types/wlr_xcursor_manager.h>
#include "sway/input/cursor.h"
-#include "sway/view.h"
+#include "sway/tree/view.h"
#include "list.h"
#include "log.h"
diff --git a/sway/input/seat.c b/sway/input/seat.c
index 648e7914..56b39766 100644
--- a/sway/input/seat.c
+++ b/sway/input/seat.c
@@ -1,13 +1,13 @@
#define _XOPEN_SOURCE 700
#include <wlr/types/wlr_cursor.h>
#include <wlr/types/wlr_xcursor_manager.h>
-#include "sway/container.h"
+#include "sway/tree/container.h"
#include "sway/input/seat.h"
#include "sway/input/cursor.h"
#include "sway/input/input-manager.h"
#include "sway/input/keyboard.h"
#include "sway/output.h"
-#include "sway/view.h"
+#include "sway/tree/view.h"
#include "log.h"
static void seat_device_destroy(struct sway_seat_device *seat_device) {
diff --git a/sway/ipc-json.c b/sway/ipc-json.c
index 977f1ecb..ebd5e43a 100644
--- a/sway/ipc-json.c
+++ b/sway/ipc-json.c
@@ -3,7 +3,7 @@
#include <ctype.h>
#include "log.h"
#include "sway/ipc-json.h"
-#include "sway/container.h"
+#include "sway/tree/container.h"
#include "sway/output.h"
#include "sway/input/input-manager.h"
#include "sway/input/seat.h"
diff --git a/sway/main.c b/sway/main.c
index f2f24be3..31bf617b 100644
--- a/sway/main.c
+++ b/sway/main.c
@@ -18,7 +18,7 @@
#include <wlr/util/log.h>
#include "sway/config.h"
#include "sway/server.h"
-#include "sway/layout.h"
+#include "sway/tree/layout.h"
#include "sway/ipc-server.h"
#include "ipc-client.h"
#include "readline.h"
diff --git a/sway/tree/container.c b/sway/tree/container.c
index bbafe9ec..805d5644 100644
--- a/sway/tree/container.c
+++ b/sway/tree/container.c
@@ -7,14 +7,14 @@
#include <wlr/types/wlr_output_layout.h>
#include <wlr/types/wlr_wl_shell.h>
#include "sway/config.h"
-#include "sway/container.h"
+#include "sway/tree/container.h"
#include "sway/input/input-manager.h"
#include "sway/input/seat.h"
-#include "sway/layout.h"
+#include "sway/tree/layout.h"
#include "sway/output.h"
#include "sway/server.h"
-#include "sway/view.h"
-#include "sway/workspace.h"
+#include "sway/tree/view.h"
+#include "sway/tree/workspace.h"
#include "sway/ipc-server.h"
#include "log.h"
@@ -82,8 +82,6 @@ static swayc_t *new_swayc(enum swayc_types type) {
c->layout = L_NONE;
c->workspace_layout = L_NONE;
c->type = type;
- c->nb_master = 1;
- c->nb_slave_groups = 1;
if (type != C_VIEW) {
c->children = create_list();
}
diff --git a/sway/tree/layout.c b/sway/tree/layout.c
index de9e7b58..5a15f3a2 100644
--- a/sway/tree/layout.c
+++ b/sway/tree/layout.c
@@ -6,10 +6,10 @@
#include <string.h>
#include <wlr/types/wlr_output.h>
#include <wlr/types/wlr_output_layout.h>
-#include "sway/container.h"
-#include "sway/layout.h"
+#include "sway/tree/container.h"
+#include "sway/tree/layout.h"
#include "sway/output.h"
-#include "sway/view.h"
+#include "sway/tree/view.h"
#include "sway/input/seat.h"
#include "list.h"
#include "log.h"
diff --git a/sway/tree/view.c b/sway/tree/view.c
index 9499adca..20e657a2 100644
--- a/sway/tree/view.c
+++ b/sway/tree/view.c
@@ -1,8 +1,8 @@
#include <wayland-server.h>
#include <wlr/types/wlr_output_layout.h>
-#include "sway/container.h"
-#include "sway/layout.h"
-#include "sway/view.h"
+#include "sway/tree/container.h"
+#include "sway/tree/layout.h"
+#include "sway/tree/view.h"
const char *view_get_title(struct sway_view *view) {
if (view->iface.get_prop) {
@@ -45,6 +45,7 @@ void view_set_size(struct sway_view *view, int width, int height) {
}
}
+// TODO make view coordinates
void view_set_position(struct sway_view *view, double ox, double oy) {
if (view->iface.set_position) {
struct wlr_box box = {
diff --git a/sway/tree/workspace.c b/sway/tree/workspace.c
index 861fda4d..3da3fde6 100644
--- a/sway/tree/workspace.c
+++ b/sway/tree/workspace.c
@@ -3,10 +3,10 @@
#include <stdlib.h>
#include <stdio.h>
#include <strings.h>
-#include "sway/container.h"
+#include "sway/tree/container.h"
#include "sway/input/input-manager.h"
#include "sway/input/seat.h"
-#include "sway/workspace.h"
+#include "sway/tree/workspace.h"
#include "log.h"
#include "util.h"