mirror of
https://github.com/swaywm/sway.git
synced 2025-11-07 13:29:56 -05:00
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
This commit is contained in:
parent
de219f6bec
commit
ede27eabc5
5 changed files with 125 additions and 44 deletions
|
|
@ -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);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue