diff options
Diffstat (limited to 'sway/ipc-json.c')
-rw-r--r-- | sway/ipc-json.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/sway/ipc-json.c b/sway/ipc-json.c index c49ea47e..4c2bcc98 100644 --- a/sway/ipc-json.c +++ b/sway/ipc-json.c | |||
@@ -201,6 +201,15 @@ static void ipc_json_describe_view(struct sway_container *c, json_object *object | |||
201 | bool urgent = c->type == C_VIEW ? | 201 | bool urgent = c->type == C_VIEW ? |
202 | view_is_urgent(c->sway_view) : container_has_urgent_child(c); | 202 | view_is_urgent(c->sway_view) : container_has_urgent_child(c); |
203 | json_object_object_add(object, "urgent", json_object_new_boolean(urgent)); | 203 | json_object_object_add(object, "urgent", json_object_new_boolean(urgent)); |
204 | |||
205 | if (c->type == C_VIEW) { | ||
206 | json_object *marks = json_object_new_array(); | ||
207 | list_t *view_marks = c->sway_view->marks; | ||
208 | for (int i = 0; i < view_marks->length; ++i) { | ||
209 | json_object_array_add(marks, json_object_new_string(view_marks->items[i])); | ||
210 | } | ||
211 | json_object_object_add(object, "marks", marks); | ||
212 | } | ||
204 | } | 213 | } |
205 | 214 | ||
206 | static void focus_inactive_children_iterator(struct sway_container *c, void *data) { | 215 | static void focus_inactive_children_iterator(struct sway_container *c, void *data) { |