How to respond to any kind of interruption?

Posted by mystify on Stack Overflow See other posts from Stack Overflow or by mystify
Published on 2010-05-31T15:21:12Z Indexed on 2010/05/31 15:23 UTC
Read the original article Hit count: 217

Filed under:

My app is playing a pretty complex animation. It's like a flipbook.

What I do is: I have a huge loop with selectors, and after every delayed call the next one is called.

Now someone calls the user and the device suddenly shows up this fat green status bar and maybe some big pick-up-the-phone-call overlay. Or: The alarm clock rings, and a big alert sheet appears in front of just about everything.

It would be great to just pause the whole animation in case of ANY interruption. Probably I've also missed like 5 more possible interruptions.

How are you doing that? How do you get notified for all interruptions and then call one single -stopEverything method?

© Stack Overflow or respective owner

Related posts about iphone