core: just enable track_focuse

It's not an intensive task.

Simplifies logic.

Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>
This commit is contained in:
Yuxuan Shui
2019-05-25 00:02:16 +01:00
parent 57f4a99940
commit 7d8a3e09be
9 changed files with 8 additions and 63 deletions

View File

@ -266,9 +266,7 @@ static inline void ev_map_notify(session_t *ps, xcb_map_notify_event_t *ev) {
map_win_by_id(ps, ev->window);
// FocusIn/Out may be ignored when the window is unmapped, so we must
// recheck focus here
if (ps->o.track_focus) {
recheck_focus(ps);
}
recheck_focus(ps);
}
static inline void ev_unmap_notify(session_t *ps, xcb_unmap_notify_event_t *ev) {
@ -402,7 +400,7 @@ static inline void ev_property_notify(session_t *ps, xcb_property_notify_event_t
}
if (ps->root == ev->window) {
if (ps->o.track_focus && ps->o.use_ewmh_active_win &&
if (ps->o.use_ewmh_active_win &&
ps->atoms->a_NET_ACTIVE_WINDOW == ev->atom) {
update_ewmh_active_win(ps);
} else {