Hand over the event loop to the embedding app