mirror of
https://github.com/Insality/druid
synced 2025-09-27 18:12:21 +02:00
Remove register and update examples
This commit is contained in:
@@ -43,8 +43,6 @@ local const = require("druid.const")
|
||||
local utf8_lua = require("druid.system.utf8")
|
||||
local utf8 = utf8 or utf8_lua
|
||||
|
||||
local input = require("druid.extended.input")
|
||||
|
||||
---@class druid.rich_input: druid.base_component
|
||||
---@field root node
|
||||
---@field input druid.input
|
||||
@@ -209,7 +207,7 @@ function M:init(template, nodes)
|
||||
self.is_lshift = false
|
||||
self.is_lctrl = false
|
||||
|
||||
self.input = self.druid:new(input, "button", "input_text")
|
||||
self.input = self.druid:new_input("button", "input_text")
|
||||
self.is_button_input_enabled = gui.is_enabled(self.input.button.node)
|
||||
|
||||
self.cursor = self:get_node("cursor_node")
|
||||
|
@@ -667,7 +667,7 @@ end
|
||||
local timer_component = require("druid.extended.timer")
|
||||
---Create Timer component
|
||||
---@param node string|node Gui text node
|
||||
---@param seconds_from number Start timer value in seconds
|
||||
---@param seconds_from number|nil Start timer value in seconds
|
||||
---@param seconds_to number|nil End timer value in seconds
|
||||
---@param callback function|nil Function on timer end
|
||||
---@return druid.timer Timer component
|
||||
@@ -690,7 +690,7 @@ end
|
||||
local layout = require("druid.extended.layout")
|
||||
---Create Layout component
|
||||
---@param node string|node The_node id or gui.get_node(node_id).
|
||||
---@param mode string vertical|horizontal|horizontal_wrap
|
||||
---@param mode string|nil vertical|horizontal|horizontal_wrap. Default: horizontal
|
||||
---@return druid.layout Layout component
|
||||
function M:new_layout(node, mode)
|
||||
return self:new(layout, node, mode)
|
||||
|
Reference in New Issue
Block a user