Workflow Trigger Test

This commit is contained in:
Robert Jelic
2025-02-26 14:50:55 +01:00
parent 4f703e9d3c
commit 2e4a745a01
2 changed files with 18 additions and 0 deletions

View File

@@ -133,16 +133,25 @@ function BaseFrame:term_resize()
self._renderUpdate = true
end
--- @shortDescription Handles key events
--- @param key number The key that was pressed
--- @protected
function BaseFrame:key(key)
self:fireEvent("key", key)
Container.key(self, key)
end
--- @shortDescription Handles key up events
--- @param key number The key that was released
--- @protected
function BaseFrame:key_up(key)
self:fireEvent("key_up", key)
Container.key_up(self, key)
end
--- @shortDescription Handles character events
--- @param char string The character that was pressed
--- @protected
function BaseFrame:char(char)
self:fireEvent("char", char)
Container.char(self, char)

View File

@@ -326,18 +326,27 @@ function VisualElement:calculatePosition()
return x, y
end
--- @shortDescription Handles a key event
--- @param key number The key that was pressed
--- @protected
function VisualElement:key(key)
if(self.get("focused"))then
self:fireEvent("key", key)
end
end
--- @shortDescription Handles a key up event
--- @param key number The key that was released
--- @protected
function VisualElement:key_up(key)
if(self.get("focused"))then
self:fireEvent("key_up", key)
end
end
--- @shortDescription Handles a character event
--- @param char string The character that was pressed
--- @protected
function VisualElement:char(char)
if(self.get("focused"))then
self:fireEvent("char", char)