Refresh focus on FocusIn events
To avoid some oddities, awesome sets the input focus lazily. Instead of immediately sending everything to the X11 server, awesome just sets a flag "have to update the focus later". However, this can cause problems. As Stefan noticed, awesome can forget about focus changes on FocusIn events when such an event comes in while we still have a pending focus change. The fix here is to send out the pending focus change before we record the fact that another client now acquired the input focus. Reported-By: Stefan Haller <haliner@googlemail.com> Signed-off-by: Uli Schlachter <psychon@znc.in>
This commit is contained in:
parent
e4be0017ff
commit
bf72cf71ea
5
event.c
5
event.c
|
@ -524,9 +524,12 @@ event_handle_focusin(xcb_focus_in_event_t *ev)
|
|||
{
|
||||
client_t *c;
|
||||
|
||||
if((c = client_getbywin(ev->event)))
|
||||
if((c = client_getbywin(ev->event))) {
|
||||
/* If there is still a pending focus change, do it now. */
|
||||
client_focus_refresh();
|
||||
client_focus_update(c);
|
||||
}
|
||||
}
|
||||
/* all other events are ignored */
|
||||
default:
|
||||
break;
|
||||
|
|
Loading…
Reference in New Issue