From: Dana Jansens Date: Wed, 9 Dec 2009 18:23:18 +0000 (-0500) Subject: When moving focus across desktops, make sure Openbox doesn't think that a window... X-Git-Tag: release-3.4.9~7^2~4 X-Git-Url: http://git.openbox.org/?p=mikachu%2Fopenbox.git;a=commitdiff_plain;h=9f74f1e244d90a60aa33e5921a66bb22e3faf073 When moving focus across desktops, make sure Openbox doesn't think that a window which is no longer visible is still focused. --- diff --git a/openbox/screen.c b/openbox/screen.c index 3e27903..b0fa17d 100644 --- a/openbox/screen.c +++ b/openbox/screen.c @@ -727,6 +727,15 @@ void screen_set_desktop(guint num, gboolean dofocus) if (WINDOW_IS_CLIENT(it->data)) { ObClient *c = it->data; client_hide(c); + if (c == focus_client) { + /* c was focused and we didn't do fallback clearly so make sure + openbox doesnt still consider the window focused. + this happens when using NextWindow with allDesktops, since + it doesnt want to move focus on desktop change, but the + focus is not going to stay with the current window, which + has now disappeared */ + focus_set_client(NULL); + } } }