mirror of
https://github.com/swaywm/sway.git
synced 2025-11-10 13:29:51 -05:00
Handle SIGTERM sent to sway
This makes sway handle and gracefully shut down everything when receiving a SIGTERM. Fix #416
This commit is contained in:
parent
b18f004210
commit
16b8c2e915
4 changed files with 24 additions and 7 deletions
|
|
@ -796,3 +796,13 @@ void add_gaps(swayc_t *view, void *_data) {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
static void close_view(swayc_t *container, void *data) {
|
||||
if (container->type == C_VIEW) {
|
||||
wlc_view_close(container->handle);
|
||||
}
|
||||
}
|
||||
|
||||
void close_views(swayc_t *container) {
|
||||
container_map(container, close_view, NULL);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue