开发者

iPhone screen lock notification to app

How can I be notified th开发者_如何学Cat the screen/phone was locked while my app is running? I want to suspend some timers related to refreshing the display in such cases.


I think your UIApplicationDelegate will receive the following message before the screen gets locked:

- (void)applicationWillResignActive:(UIApplication *)application

here the link to the documentation: http://developer.apple.com/iphone/library/documentation/UIKit/Reference/UIApplicationDelegate_Protocol/Reference/Reference.html#//apple_ref/occ/intfm/UIApplicationDelegate/applicationWillResignActive:

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜