2010-10-08 116 views

回答

3

iPhone的後臺功能使進程暫停,用戶代碼無法控制應用程序,直到它再次變爲活動狀態。因此,即使其他應用程序啓動或退出,後臺應用程序也無法收到通知。


(無論如何,檢測與ID com.yourcompany.foo一個應用程序是否被激活或暫停,你可以聽com.yourcompany.foo-activatedcom.yourcompany.foo-suspended達爾文通知。)

+0

Darwin通知? – Emil 2010-10-08 18:58:30

+1

@Emil:http://devworld.apple.com/library/mac/#documentation/Darwin/Conceptual/MacOSXNotifcationOv/DarwinNotificationConcepts/DarwinNotificationConcepts.html – kennytm 2010-10-08 18:59:41

+0

因此您需要使用'CFNotification's? http://developer.apple.com/library/ios/#documentation/CoreFoundation/Reference/CFNotificationCenterRef/Reference/reference.html – Emil 2010-10-08 19:04:30

0

在股票的iOS,應用程序不運行背景,只允許特定的任務(音頻,VOIP,位置記錄等)

相關問題