/* update the focus lists */
focus_order_remove(self);
+ /* don't leave an invalid focus_client */
+ if (self == focus_client)
+ focus_client = NULL;
client_list = g_list_remove(client_list, self);
stacking_remove(self);
*/
focus_nothing();
+ focus_client = NULL;
+
if ((new = focus_fallback_target(allow_refocus, old)))
client_focus(new);
}
screen_install_colormap(NULL, TRUE);
}
- focus_client = NULL;
-
/* when nothing will be focused, send focus to the backup target */
XSetInputFocus(ob_display, screen_support_win, RevertToPointerRoot,
event_curtime);
void focus_order_remove(ObClient *c)
{
focus_order = g_list_remove(focus_order, c);
- if (c == focus_client)
- focus_client = NULL;
}
void focus_order_to_top(ObClient *c)