简体   繁体   English

如何在iOS 5的通知中心获取我的应用的所有通知

[英]How to get all notifications for my app in notification center of iOS 5

I use didReceiveRemoteNotifications:(NSDictionary*)userInfo to get a push message while it arrives. 我使用didReceiveRemoteNotifications:(NSDictionary*)userInfo来获取推送消息。

The problem is: iOS 5 added a notification center to temporarily save push notifications, when I tap one of them , the didReceiveRemote** call back func only gets one of the messages, and other messages dissappear in notification center. 问题是:iOS 5添加了一个通知中心来临时保存推送通知,当我点击其中一个时, didReceiveRemote**回调func只获取其中一条消息,其他消息在通知中心消失。

How can I get all of the push messages in the notification center? 如何在通知中心获取所有推送消息?

The only way to get all the messages in the notification center, is to have the user touch them. 获取通知中心中所有消息的唯一方法是让用户触摸它们。

When your app enters the foreground, it should check with the server for any unreceived messages. 当您的应用程序进入前台时,它应该检查服务器是否有任何未接收的消息。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM