InputDialog is broken by #2672 (#2690)

This change also adds a tap_input_func in both TouchMenu and Button.
This commit is contained in:
Hzj_jie
2017-03-28 15:47:18 -07:00
committed by GitHub
parent ea2de9638b
commit ed461c7f30
4 changed files with 28 additions and 14 deletions

View File

@@ -185,6 +185,8 @@ function Button:onTapSelectButton()
end)
elseif self.tap_input then
self:onInput(self.tap_input)
elseif type(self.tap_input_func) == "function" then
self:onInput(self.tap_input_func())
end
return true
end
@@ -194,6 +196,8 @@ function Button:onHoldSelectButton()
self.hold_callback()
elseif self.hold_input then
self:onInput(self.hold_input)
elseif type(self.hold_input_func) == "function" then
self:onInput(self.hold_input_func())
end
return true
end