diff options
Diffstat (limited to 'sway/ipc-json.c')
-rw-r--r-- | sway/ipc-json.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sway/ipc-json.c b/sway/ipc-json.c index 064509c9..1579a2d9 100644 --- a/sway/ipc-json.c +++ b/sway/ipc-json.c | |||
@@ -1,3 +1,4 @@ | |||
1 | #define _POSIX_C_SOURCE 200809L | ||
1 | #include <json-c/json.h> | 2 | #include <json-c/json.h> |
2 | #include <ctype.h> | 3 | #include <ctype.h> |
3 | #include <string.h> | 4 | #include <string.h> |
@@ -5,6 +6,7 @@ | |||
5 | #include <libinput.h> | 6 | #include <libinput.h> |
6 | #include <wlr/types/wlr_box.h> | 7 | #include <wlr/types/wlr_box.h> |
7 | #include <wlr/types/wlr_output.h> | 8 | #include <wlr/types/wlr_output.h> |
9 | #include "sway/output.h" | ||
8 | #include "sway/container.h" | 10 | #include "sway/container.h" |
9 | #include "sway/input.h" | 11 | #include "sway/input.h" |
10 | #include "sway/ipc-json.h" | 12 | #include "sway/ipc-json.h" |
@@ -18,7 +20,7 @@ static json_object *ipc_json_create_rect(swayc_t *c) { | |||
18 | 20 | ||
19 | struct wlr_box box; | 21 | struct wlr_box box; |
20 | if (c->type == C_OUTPUT) { | 22 | if (c->type == C_OUTPUT) { |
21 | wlr_output_effective_resolution(c->_handle.output, | 23 | wlr_output_effective_resolution(c->_handle.output->wlr_output, |
22 | &box.width, &box.height); | 24 | &box.width, &box.height); |
23 | } else { | 25 | } else { |
24 | box.width = c->width; | 26 | box.width = c->width; |