问题
May be a simple question: When I call "cancelAllLocalNotifications", does it cancel notifications created by the app only or it will cancel all notifications from other apps also?
回答1:
The notifications created by other apps will not be affected.
From: Local and Push Notification Programming Guide
"You can cancel a specific scheduled notification by calling cancelLocalNotification: on the application object, and you can cancel all scheduled notifications by calling cancelAllLocalNotifications."
Although, this is probably not the best written sentence, the "on the application object" applies to cancelAllLocalNotifications as well as cancelLocalNotification.
Hope that helps!
来源:https://stackoverflow.com/questions/8033690/ios-local-notifications-cancelalllocalnotifications