summaryrefslogtreecommitdiff
path: root/core/lua
diff options
context:
space:
mode:
authorKevin <[email protected]>2024-10-09 20:40:42 -0300
committerGitHub <[email protected]>2024-10-09 20:40:42 -0300
commitb5fc6cd12c7d62a4e89fc9c2915c61f8c19900aa (patch)
treee4dd92547856f5f4246f2536ffd6ab15049422ba /core/lua
parente6c35cb90f01149928baaa6959f5e1744efbb9b2 (diff)
parent0def6d7e9fd8b66220171ee228f0e845ed6edb57 (diff)
Merge branch 'Aylur:main' into main
Diffstat (limited to 'core/lua')
-rw-r--r--core/lua/astal/widget.lua8
1 files changed, 4 insertions, 4 deletions
diff --git a/core/lua/astal/widget.lua b/core/lua/astal/widget.lua
index 8f49409..73fe3b6 100644
--- a/core/lua/astal/widget.lua
+++ b/core/lua/astal/widget.lua
@@ -206,6 +206,10 @@ local function astalify(ctor)
-- construct, attach bindings, add children
local widget = ctor()
+ for prop, value in pairs(props) do
+ widget[prop] = value
+ end
+
if getmetatable(children) == Binding then
set_children(widget, children:get())
widget.on_destroy = children:subscribe(function(v)
@@ -223,10 +227,6 @@ local function astalify(ctor)
end)
end
- for prop, value in pairs(props) do
- widget[prop] = value
- end
-
if type(setup) == "function" then
setup(widget)
end