Problem with applicationShouldTerminate on iPhone

后端 未结 4 1434
再見小時候
再見小時候 2021-01-24 05:57

I\'m having a problem with applicationShouldTerminate.

What ever I do it seams that has no effect. Any help would be appreciated.

I\'m well versed in programing

4条回答
  •  误落风尘
    2021-01-24 06:21

    I know this is a non-answer, but hopefully I can be helpful:

    Displaying a "Really quit?"-type alert like this, even if you can pull it off technically (and I'm not sure you can), is a bad idea and is likely to either cause rejection from the App Store or, at best, an inconsistent user experience because no other apps do this.

    The convention with iPhone apps is to save state if necessary, then yield control (for termination) as quickly as possible when the user hits the home button or switches apps.

    To ensure a consistent experience, Apple probably has an aggressive timer in place to restrict what you can do in applicationWillTerminate. And even if they don't have a technical measure in place, they probably have an App Store approval policy to ensure that applications quit immediately when they're asked to.

提交回复
热议问题