]> git.sur5r.net Git - i3/i3/commit
Use the EWMH support window rather than the root window as an input focus fallback. 1917/head
authorIngo Bürk <ingo.buerk@tngtech.com>
Sat, 12 Sep 2015 20:34:06 +0000 (22:34 +0200)
committerIngo Bürk <ingo.buerk@tngtech.com>
Sun, 13 Sep 2015 18:29:02 +0000 (20:29 +0200)
commit5dbfb05c85f592fb90a3918cd50c21e30009cbb2
tree6407a70b7d57075b8a1fd94e62769bb4990b15d6
parentef6f2f43659e04f7eb3da117581fd09f16fca618
Use the EWMH support window rather than the root window as an input focus fallback.

If no other window is available on the active workspace, we now select the EWMH support window (used to indicate that an EWMH-compliant window manager is preent) as the focus window rather than the root window. The NET_WM_ACTIVE window will still be set to XCB_WINDOW_NONE to pretend that no window is actually focused.
This fixes the issue that when using the root window, a fallback mechanism in X11 takes effect which routes keyboard input to the window under the cursor, independent of whether that window has the input focus. Using the EWMH window instead, we can avoid this behavior. We cannot simply set it to XCB_WINDOW_NONE as this would discard all keyboard events, breaking keybindings.

fixes #1378
include/i3.h
src/ewmh.c
src/x.c
testcases/t/527-focus-fallback.t [new file with mode: 0644]