diff --git a/banning.c b/banning.c index 3d1f37120..78c94637e 100644 --- a/banning.c +++ b/banning.c @@ -52,8 +52,6 @@ banning_refresh(void) globalconf.need_lazy_banning = false; - client_ignore_enterleave_events(); - foreach(c, globalconf.clients) if(client_isvisible(*c)) client_unban(*c); @@ -63,8 +61,6 @@ banning_refresh(void) foreach(c, globalconf.clients) if(!client_isvisible(*c)) client_ban(*c); - - client_restore_enterleave_events(); } // vim: filetype=c:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:textwidth=80 diff --git a/objects/client.c b/objects/client.c index d406daa8d..3e871fe2c 100644 --- a/objects/client.c +++ b/objects/client.c @@ -1059,7 +1059,9 @@ client_ban(client_t *c) { if(!c->isbanned) { + client_ignore_enterleave_events(); xcb_unmap_window(globalconf.connection, c->frame_window); + client_restore_enterleave_events(); c->isbanned = true; @@ -2130,7 +2132,9 @@ client_unban(client_t *c) lua_State *L = globalconf_get_lua_State(); if(c->isbanned) { + client_ignore_enterleave_events(); xcb_map_window(globalconf.connection, c->frame_window); + client_restore_enterleave_events(); c->isbanned = false;