]> git.sur5r.net Git - i3/i3/commitdiff
_NET_ACTIVE_WINDOW: invalidate focus to force SetInputFocus call (#3027)
authorMichael Stapelberg <stapelberg@users.noreply.github.com>
Sun, 22 Oct 2017 20:16:15 +0000 (22:16 +0200)
committerGitHub <noreply@github.com>
Sun, 22 Oct 2017 20:16:15 +0000 (22:16 +0200)
The sender of the _NET_ACTIVE_WINDOW client message might know better when to
set focus than i3, as i3 does not know about unmanaged (override_redirect=1)
windows.

related to https://github.com/i3/i3lock/issues/35

src/handlers.c

index 3140e4057674ca7596719ece8df9f5fbba70b19a..436fb2aba881f5b8f5e88d16cb6119e15fb479f0 100644 (file)
@@ -774,6 +774,8 @@ static void handle_client_message(xcb_client_message_event_t *event) {
                 scratchpad_show(con);
             } else {
                 workspace_show(ws);
+                /* Re-set focus, even if unchanged from i3’s perspective. */
+                focused_id = XCB_NONE;
                 con_focus(con);
             }
         } else {