mirror of
https://github.com/Insality/druid
synced 2025-09-27 18:12:21 +02:00
Update
This commit is contained in:
@@ -92,6 +92,18 @@ function M:on_style_change(style)
|
||||
end
|
||||
|
||||
|
||||
---@return druid.button self
|
||||
function M:set_animations_disabled()
|
||||
self.style.on_click = function() end
|
||||
self.style.on_click_disabled = function() end
|
||||
self.style.on_mouse_hover = function() end
|
||||
self.style.on_hover = function() end
|
||||
self.style.on_set_enabled = function() end
|
||||
|
||||
return self
|
||||
end
|
||||
|
||||
|
||||
function M:on_late_init()
|
||||
if not self.click_zone then
|
||||
local stencil_node = helper.get_closest_stencil_node(self.node)
|
||||
|
@@ -9,8 +9,8 @@ local component = require("druid.component")
|
||||
|
||||
---@class druid.hover: druid.component
|
||||
---@field node node
|
||||
---@field on_hover event
|
||||
---@field on_mouse_hover event
|
||||
---@field on_hover event fun(self: druid.hover, is_hover: boolean)
|
||||
---@field on_mouse_hover event fun(self: druid.hover, is_hover: boolean)
|
||||
---@field style druid.hover.style
|
||||
---@field click_zone node
|
||||
---@field private _is_hovered boolean|nil
|
||||
|
Reference in New Issue
Block a user