且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

从跳板返回应用程序时调用的方法

更新时间:2023-02-16 23:28:19

将简历代码放入应用程序委托.m文件的- (void) applicationDidBecomeActive:(UIApplication *)application- (void)applicationWillEnterForeground:(UIApplication *)application函数中.当用户单击主页按钮后,当您的应用程序再次启动时,该函数将被调用

put your resume code in the - (void) applicationDidBecomeActive:(UIApplication *)application or - (void)applicationWillEnterForeground:(UIApplication *)application function in your app delegate .m file. when your application starts up again after the user hits the home button, this function will be called

apple的文档详细说明了用于某些任务的功能:

apple's documentation explains in more detail as to which function to use for certain tasks:

http://developer.apple .com/library/ios/#documentation/uikit/reference/UIApplicationDelegate_Protocol/Reference/Reference.html