aboutsummaryrefslogtreecommitdiff
path: root/sway/ipc-json.c
diff options
context:
space:
mode:
Diffstat (limited to 'sway/ipc-json.c')
-rw-r--r--sway/ipc-json.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/sway/ipc-json.c b/sway/ipc-json.c
index 7caa2457..977f1ecb 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/tree/container.h"
+#include "sway/container.h"
#include "sway/output.h"
#include "sway/input/input-manager.h"
#include "sway/input/seat.h"
@@ -25,7 +25,7 @@ json_object *ipc_json_get_version() {
return version;
}
-static json_object *ipc_json_create_rect(struct sway_container *c) {
+static json_object *ipc_json_create_rect(swayc_t *c) {
json_object *rect = json_object_new_object();
json_object_object_add(rect, "x", json_object_new_int((int32_t)c->x));
@@ -36,7 +36,7 @@ static json_object *ipc_json_create_rect(struct sway_container *c) {
return rect;
}
-static void ipc_json_describe_root(struct sway_container *root, json_object *object) {
+static void ipc_json_describe_root(swayc_t *root, json_object *object) {
json_object_object_add(object, "type", json_object_new_string("root"));
json_object_object_add(object, "layout", json_object_new_string("splith"));
}
@@ -63,7 +63,7 @@ static const char *ipc_json_get_output_transform(enum wl_output_transform transf
return NULL;
}
-static void ipc_json_describe_output(struct sway_container *container, json_object *object) {
+static void ipc_json_describe_output(swayc_t *container, json_object *object) {
struct wlr_output *wlr_output = container->sway_output->wlr_output;
json_object_object_add(object, "type", json_object_new_string("output"));
json_object_object_add(object, "active", json_object_new_boolean(true));
@@ -94,7 +94,7 @@ static void ipc_json_describe_output(struct sway_container *container, json_obje
json_object_object_add(object, "modes", modes_array);
}
-static void ipc_json_describe_workspace(struct sway_container *workspace, json_object *object) {
+static void ipc_json_describe_workspace(swayc_t *workspace, json_object *object) {
int num = (isdigit(workspace->name[0])) ? atoi(workspace->name) : -1;
json_object_object_add(object, "num", json_object_new_int(num));
@@ -102,11 +102,11 @@ static void ipc_json_describe_workspace(struct sway_container *workspace, json_o
json_object_object_add(object, "type", json_object_new_string("workspace"));
}
-static void ipc_json_describe_view(struct sway_container *c, json_object *object) {
+static void ipc_json_describe_view(swayc_t *c, json_object *object) {
json_object_object_add(object, "name", (c->name) ? json_object_new_string(c->name) : NULL);
}
-json_object *ipc_json_describe_container(struct sway_container *c) {
+json_object *ipc_json_describe_container(swayc_t *c) {
if (!(sway_assert(c, "Container must not be null."))) {
return NULL;
}
@@ -147,7 +147,7 @@ json_object *ipc_json_describe_container(struct sway_container *c) {
return object;
}
-json_object *ipc_json_describe_container_recursive(struct sway_container *c) {
+json_object *ipc_json_describe_container_recursive(swayc_t *c) {
json_object *object = ipc_json_describe_container(c);
int i;