diff --git a/src/ext-protocol/ext-workspace.h b/src/ext-protocol/ext-workspace.h index 70bc2f6c..e6177cee 100644 --- a/src/ext-protocol/ext-workspace.h +++ b/src/ext-protocol/ext-workspace.h @@ -187,6 +187,10 @@ void mango_ext_workspace_printstatus(Monitor *m) { void refresh_monitors_workspaces_status(Monitor *m) { int32_t i; + if (!m || !m->wlr_output->enabled || m->iscleanuping) { + return; + } + if (m->isoverview) { add_workspace_by_tag(0, m); for (i = 1; i <= LENGTH(tags); i++) { diff --git a/src/mango.c b/src/mango.c index a6fbfcee..7217d4e1 100644 --- a/src/mango.c +++ b/src/mango.c @@ -2751,6 +2751,11 @@ void closemon(Monitor *m) { * move closed monitor's clients to the focused one */ Client *c = NULL; int32_t i = 0, nmons = wl_list_length(&mons); + + if (m->isoverview) { + toggleoverview(&(Arg){.i = 1}); + } + if (!nmons) { selmon = NULL; } else if (m == selmon) {