diff --git a/alpha_todo.txt b/alpha_todo.txt index cff23aa..fbbf68e 100644 --- a/alpha_todo.txt +++ b/alpha_todo.txt @@ -13,9 +13,9 @@ Simple to-do for Druid Alpha 0.2.0 - add init/remove stuff for every style in component. How to set custom sprites for button states? - add druid settings (add auto_focus input and other stuff) -- button add key trigger ++ button add key trigger - button polish, actions -- button and hover click restriction zone? ++ button and hover click restriction zone? - unify component api (get/set/to and other general stuff) - better callbacks for every components diff --git a/druid/base/button.lua b/druid/base/button.lua index 2b6e4bf..8733a39 100644 --- a/druid/base/button.lua +++ b/druid/base/button.lua @@ -176,14 +176,12 @@ function M.on_input(self, action_id, action) return false end - local is_key_trigger = (action_id == self.key_trigger) - if not helper.is_enabled(self.node) then return false end local is_pick = true - + local is_key_trigger = (action_id == self.key_trigger) if not is_key_trigger then is_pick = gui.pick_node(self.node, action.x, action.y) if self.click_zone then