Update annotations

This commit is contained in:
Insality
2024-11-10 20:34:30 +01:00
parent b5ccd80215
commit 56ef92a1b5
16 changed files with 21 additions and 158 deletions

View File

@@ -35,7 +35,6 @@ local M = component.create("hover")
--- The Hover constructor
---@param self Hover Hover
---@param node node Gui node
---@param on_hover_callback function Hover callback
---@param on_mouse_hover function On mouse hover callback
@@ -115,7 +114,6 @@ end
--- Set hover state
---@param self Hover Hover
---@param state boolean|nil The hover state
function M:set_hover(state)
if self._is_hovered == state then
@@ -132,7 +130,6 @@ end
--- Return current hover state. True if touch action was on the node at current time
---@param self Hover Hover
---@return boolean The current hovered state
function M:is_hovered()
return self._is_hovered
@@ -140,7 +137,6 @@ end
--- Set mouse hover state
---@param self Hover Hover
---@param state boolean|nil The mouse hover state
function M:set_mouse_hover(state)
if self._is_mouse_hovered == state then
@@ -157,7 +153,6 @@ end
--- Return current hover state. True if nil action_id (usually desktop mouse) was on the node at current time
---@param self Hover Hover
---@return boolean The current hovered state
function M:is_mouse_hovered()
return self._is_mouse_hovered
@@ -166,7 +161,6 @@ end
--- Strict hover click area. Useful for
-- no click events outside stencil node
---@param self Hover Hover
---@param zone node|string|nil Gui node
function M:set_click_zone(zone)
self.click_zone = self:get_node(zone)
@@ -176,7 +170,6 @@ end
--- Set enable state of hover component.
-- If hover is not enabled, it will not generate
-- any hover events
---@param self Hover Hover
---@param state boolean|nil The hover enabled state
function M:set_enabled(state)
self._is_enabled = state
@@ -193,7 +186,6 @@ end
--- Return current hover enabled state
---@param self Hover Hover
---@return boolean The hover enabled state
function M:is_enabled()
return self._is_enabled