Hi all,
I’m dispatching a manual “touch” event via foo:dispatchEvent(e). The handler for foo is triggered properly by the custom event, but the event isn’t propagated if foo’s handler returns false.
Am I doing something wrong?
Below is the code I’m using to generate the custom event:
local newEvent = {} newEvent.name = "touch" newEvent.phase = "began" newEvent.x = event.xStart newEvent.y = event.yStart newEvent.xStart = event.xStart newEvent.yStart = event.yStart newEvent.target = event.target event.target:dispatchEvent(newEvent)
Also tried Runtime:dispatchEvent(e) but that doesn’t hit the handler at all.
Thx.