我想知道是否有办法知道某个应用程序(可以在后台关闭或打开)是否已通过点击启动:
>通知(在通知中心)?
>或跳板上的应用程序图标?
谢谢 !!
解决方法
把这段代码:
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { UILocalNotification *notification = launchOptions[UIApplicationLaunchOptionsLocalNotificationKey]; if (notification) { // launched from notification } else { // from the springboard } }