all repos — openbox @ 3265ea9ac14a6cf05e3c2a462fdd81b7fe925c0a

openbox fork - make it a bit more like ryudo

when focusing nothing, make sure focus_client knows that nothing is focused
Dana Jansens danakj@orodu.net
commit

3265ea9ac14a6cf05e3c2a462fdd81b7fe925c0a

parent

afd88015b55da186a3e7777dadf2a1f572e85529

1 files changed, 4 insertions(+), 1 deletions(-)

jump to
M openbox/focus.copenbox/focus.c

@@ -259,6 +259,7 @@

void focus_fallback(gboolean allow_refocus) { ObClient *new; + ObClient *old = focus_client; /* unfocus any focused clients.. they can be focused by Pointer events and such, and then when I try focus them, I won't get a FocusIn event

@@ -266,7 +267,7 @@ at all for them.

*/ focus_nothing(); - if ((new = focus_fallback_target(allow_refocus, focus_client))) + if ((new = focus_fallback_target(allow_refocus, old))) client_focus(new); }

@@ -277,6 +278,8 @@ if (focus_client != NULL) {

screen_install_colormap(focus_client, FALSE); 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,