Sorry I can’t put a better title. I am not sure if this is a bug or intentional so I am posting here.
I have an event that dispatch to all storyboard scene if they are active (overlays) when my pet dies. Currently opened overlay will listen to the event and then hides itself (hideOverlay).
Here is the problem, when I am holding down a button when this event is dispatch, it will hide the overlay normally. However once I release the mouse, a segmented error is given in the terminal. I have this error before when I accidentally detected touch event without checking for touch phase when hiding the overlay.
The above problem is solved by adding before hiding the overlay:
display.getCurrentStage():setFocus( nil )
this is to cancel out any scrollers or buttons or other things that is taking focus.
I am not sure if this is a bug or intentional so I am just posting it here. The version I am using is 1137.