diff options
author | Mikkel Oscar Lyderik <[email protected]> | 2015-12-18 17:43:03 +0100 |
---|---|---|
committer | Mikkel Oscar Lyderik <[email protected]> | 2015-12-18 18:27:44 +0100 |
commit | ede27eabc53dc926aa1932c2a58c06def1000f86 (patch) | |
tree | 4d734e99a6163d846423c79a2d7ff04070018e78 /sway/container.c | |
parent | de219f6bec432e98e419591f6accd516402c0182 (diff) |
Reload swaybar/swaybg on config reload.
This works by tracking the pids of the child processes in the related
output container and terminating the processes and spawning new ones on
a config reload.
Should solve: #347
Diffstat (limited to 'sway/container.c')
-rw-r--r-- | sway/container.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/sway/container.c b/sway/container.c index 36056ff7..395eb04d 100644 --- a/sway/container.c +++ b/sway/container.c @@ -60,6 +60,9 @@ static void free_swayc(swayc_t *cont) { if (cont->app_id) { free(cont->app_id); } + if (cont->bar_pids) { + free_flat_list(cont->bar_pids); + } free(cont); } @@ -109,6 +112,8 @@ swayc_t *new_output(wlc_handle handle) { output->width = size->w; output->height = size->h; output->unmanaged = create_list(); + output->bar_pids = create_list(); + output->bg_pid = 0; apply_output_config(oc, output); add_child(&root_container, output); |