tags:

views:

391

answers:

2

I know that -applicationWillResignActive gets called upon an incoming call, but is there a standard method that gets called if the user hits the "exit" button (the only button on the front of the iPhone)?

+7  A: 

- (void)applicationWillTerminate:(UIApplication *)application, in UIApplicationDelegate protocol.

Marc Charbonneau
A: 

I made some try and i'm using iPhone SDK 4, and when you press the "exit" button the app called two methods:

(void)applicationWillResignActive:(UIApplication *)application
(void)applicationDidEnterBackground:(UIApplication *)application
Noya