mirror of
https://github.com/enduro2d/enduro2d.git
synced 2025-12-14 16:09:06 +07:00
26 lines
433 B
Lua
26 lines
433 B
Lua
---@class widget
|
|
local widget = {
|
|
---@type boolean
|
|
enabled = true,
|
|
|
|
---@type boolean
|
|
disabled = false,
|
|
|
|
---@type v2f
|
|
size = v2f.zero(),
|
|
|
|
---@type v2f
|
|
pivot = v2f.unit() * 0.5
|
|
}
|
|
|
|
---@overload fun(self: widget)
|
|
---@param self widget
|
|
function widget.enable(self) end
|
|
|
|
---@overload fun(self: widget)
|
|
---@param self widget
|
|
function widget.disable(self) end
|
|
|
|
---@type widget
|
|
_G.widget = _G.widget or widget
|