开发者

iPhone app reactivate (open from icon)

开发者 https://www.devze.com 2023-01-27 10:48 出处:网络
In the latest i开发者_如何学GoOS, apps now \"deactivate\" rather than close by default.So the app retains state and stays in memory.

In the latest i开发者_如何学GoOS, apps now "deactivate" rather than close by default. So the app retains state and stays in memory.

I want my app to reset its state when it's reactivated, just like when it's closed/opened on iPhone 3.

I suspect reactivate is the wrong word! But hopefully you know what I mean. thanks


Add the UIApplicationExitsOnSuspend key to your Info.plist, and set it to YES. This will mark your application as NOT supporting multitasking, and it will quit just like it used to. Good luck!


You can opt out of multitasking by setting the UIApplicationExitsOnSuspend key in your project’s Info.plist and setting the value to YES.

This will make your app behave like it would on iOS 3.x.


There's a property list key for that. UIApplicationExitsOnSuspend is set in your Info.plist when you want to exit instead of suspend when the user hits the home button.


If you have an app that you developed pre-multitasking and you are having issues or you don’t need it, you can disable multitasking in the application’s Info.plist file.

Adding

    Application does not run in background

or

    UIApplicationExitsOnSuspend

will stop your application being suspended when it is closed.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号