diff options
| author | Jacob McNamee <jacob@jacobmcnamee.com> | 2025-01-04 00:03:14 -0800 |
|---|---|---|
| committer | Simon Ser <contact@emersion.fr> | 2025-01-13 08:54:23 +0100 |
| commit | 0b08dce08cbcf515103d8a7fd8c390ed04c93428 (patch) | |
| tree | 9508174c35cd5cc3255301d474da87b6aa509cad | |
| parent | f177d0544108d2fbf567ee0db646efc99e72d47f (diff) | |
swaymsg: pretty-print sandbox properties
| -rw-r--r-- | swaymsg/main.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/swaymsg/main.c b/swaymsg/main.c index 5c57171e..0ef6eb8a 100644 --- a/swaymsg/main.c +++ b/swaymsg/main.c @@ -330,6 +330,9 @@ static void pretty_print_tree(json_object *obj, int indent) { const char *instance = json_object_get_string(json_object_object_get(window_props_obj, "instance")); const char *class = json_object_get_string(json_object_object_get(window_props_obj, "class")); int x11_id = json_object_get_int(json_object_object_get(obj, "window")); + const char *sandbox_engine = json_object_get_string(json_object_object_get(obj, "sandbox_engine")); + const char *sandbox_app_id = json_object_get_string(json_object_object_get(obj, "sandbox_app_id")); + const char *sandbox_instance_id = json_object_get_string(json_object_object_get(obj, "sandbox_instance_id")); printf(" (%s, pid: %d", shell, pid); if (app_id != NULL) { @@ -344,6 +347,15 @@ static void pretty_print_tree(json_object *obj, int indent) { if (x11_id != 0) { printf(", X11 window: 0x%X", x11_id); } + if (sandbox_engine != NULL) { + printf(", sandbox_engine: \"%s\"", sandbox_engine); + } + if (sandbox_app_id != NULL) { + printf(", sandbox_app_id: \"%s\"", sandbox_app_id); + } + if (sandbox_instance_id != NULL) { + printf(", sandbox_instance_id: \"%s\"", sandbox_instance_id); + } printf(")"); } |
