diff --git a/client.c b/client.c index bd3a5dd6..ee8f6f2e 100644 --- a/client.c +++ b/client.c @@ -1230,9 +1230,6 @@ luaA_client_swap(lua_State *L) *ref_c = swap; *ref_swap = c; - client_need_arrange(c); - client_need_arrange(swap); - /* Call hook to notify list change */ if(globalconf.hooks.clients != LUA_REFNIL) luaA_dofunction(L, globalconf.hooks.clients, 0, 0); diff --git a/lib/awful/layout/init.lua.in b/lib/awful/layout/init.lua.in index d673f5c2..ca49b9a8 100644 --- a/lib/awful/layout/init.lua.in +++ b/lib/awful/layout/init.lua.in @@ -111,5 +111,10 @@ end) hooks.padding.register(function(screen) on_arrange(screen) end) hooks.focus.register(function(c) on_arrange(c.screen) end) +hooks.clients.register(function() + for screen = 1, capi.screen.count() do + on_arrange(screen) + end + end) -- vim: filetype=lua:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=80