1、检查设备是否支持多任务
2、applicationDidEnterBackground和applicationWillEnterForeground(UIApplicationDidEnterBackgroundNotification和UIApplicationWillEnterForegroundNotification)
3、声明你需要的后台任务(在Info.plist中添加UIBackgroundModes键值:audio、location、voip)
1、检查设备是否支持多任务
2、applicationDidEnterBackground和applicationWillEnterForeground(UIApplicationDidEnterBackgroundNotification和UIApplicationWillEnterForegroundNotification)
3、声明你需要的后台任务(在Info.plist中添加UIBackgroundModes键值:audio、location、voip)