In my program, a recursive state is being used. The state judge some conditions,and call itself or exit. In the state, I want check the UI event. I adds "Idle" state in the front of the state queue,but found it will empty the queue. My question: How to check the UI event or Jump to "Idle" state programly?