mirror of
https://github.com/Insality/druid
synced 2025-09-27 18:12:21 +02:00
Add component instance with general methods. New component constructor
This commit is contained in:
@@ -71,7 +71,7 @@ function M.new(component_script, style)
|
||||
end
|
||||
local self = setmetatable({}, { __index = druid_instance })
|
||||
-- Druid context here (who created druid)
|
||||
-- Usually gui_script, but can be component from helper.get_druid(component)
|
||||
-- Usually gui_script, but can be component from self:get_druid()
|
||||
self._context = component_script
|
||||
self._style = style or default_style
|
||||
return self
|
||||
|
Reference in New Issue
Block a user