src/osd.c: Prevent showing invalid windows

This might happen when closing the last
application "to tray" like VLC, Discord or Steam.

Reported-by: @Flrian
This commit is contained in:
Consolatis 2022-09-26 03:48:02 +02:00 committed by Johan Malm
parent f2277c37c3
commit c83c1beace
2 changed files with 5 additions and 2 deletions

View file

@ -226,7 +226,7 @@ osd_update(struct server *server)
struct wl_list *node_list =
&server->workspace_current->tree->children;
if (wl_list_empty(node_list)) {
if (wl_list_empty(node_list) || !server->osd_state.cycle_view) {
osd_finish(server);
return;
}