wibox: do not set need_arrange on wibox detach
Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
parent
1a0b1a2215
commit
25b3e718d1
|
@ -93,8 +93,9 @@ function getname(layout)
|
||||||
end
|
end
|
||||||
|
|
||||||
hooks.arrange.register(on_arrange)
|
hooks.arrange.register(on_arrange)
|
||||||
hooks.property.register(function (c, prop)
|
hooks.property.register(function (obj, prop)
|
||||||
if type(c) ~= "client" then return end
|
local objtype = type(obj)
|
||||||
|
if objtype == "client" then
|
||||||
if prop == "size_hints_honor"
|
if prop == "size_hints_honor"
|
||||||
or prop == "struts"
|
or prop == "struts"
|
||||||
or prop == "minimized"
|
or prop == "minimized"
|
||||||
|
@ -104,7 +105,7 @@ hooks.property.register(function (c, prop)
|
||||||
or prop == "maximized_vertical"
|
or prop == "maximized_vertical"
|
||||||
or prop == "border_width"
|
or prop == "border_width"
|
||||||
or prop == "hide" then
|
or prop == "hide" then
|
||||||
on_arrange(c.screen)
|
on_arrange(obj.screen)
|
||||||
elseif prop == "screen" then
|
elseif prop == "screen" then
|
||||||
-- If prop is screen, we do not know what was the previous screen, so
|
-- If prop is screen, we do not know what was the previous screen, so
|
||||||
-- let's arrange all screens :-(
|
-- let's arrange all screens :-(
|
||||||
|
@ -112,6 +113,11 @@ hooks.property.register(function (c, prop)
|
||||||
on_arrange(screen)
|
on_arrange(screen)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
elseif objtype == "wibox" then
|
||||||
|
if prop == "screen" then
|
||||||
|
on_arrange(obj.screen)
|
||||||
|
end
|
||||||
|
end
|
||||||
end)
|
end)
|
||||||
hooks.wibox_position.register(function(wibox)
|
hooks.wibox_position.register(function(wibox)
|
||||||
on_arrange(wibox.screen)
|
on_arrange(wibox.screen)
|
||||||
|
|
Loading…
Reference in New Issue