If I (like as newbie in lua) write event.stopPropagation() instead event:stopPropagation() the gideros player just silent closes itself. It's actual only for Event.KEY_DOWN and Event.KEY_UP events.
In others events this typo is recognized.
For example:
self:addEventListener(Event.KEY_DOWN, self.onKeyDown, self)
function Button:onKeyDown(event)
if event.keyCode == KeyCode.Y then
event.stopPropagation()
end
end
Try press Y during execution and gideros player will become invisible.
Comments