In your example above, coming out of event #1, would be considered reaching the next top-level event. Anything you do, still inside event #1, including groups, functions, is still not valid. Triggers should be OK, as they are outside of the event loop, but if the trigger happens immediately, I'm not 100% sure then.