IOS中环信和极光的消息角标累计问题

WBOY
Release: 2016-06-06 20:12:07
Original
1100 people have browsed it

退出app后,通过环信好友发送的消息数 与 极光推送的通知 角标怎么累计?服务端方面要怎么配合?现在是每次来了各自的消息后,角标就按照各自的计数器来显示,我想让他们总数累计在一起,而且可以根据查看信息的动作来减去相应的角标数?

回复内容:

退出app后,通过环信好友发送的消息数 与 极光推送的通知 角标怎么累计?服务端方面要怎么配合?现在是每次来了各自的消息后,角标就按照各自的计数器来显示,我想让他们总数累计在一起,而且可以根据查看信息的动作来减去相应的角标数?

自己在 application:didReceiveRemoteNotification: 获取通知中的 applicationIconBadgeNumber 进行累加,然后通过 [[UIApplication sharedApplication] setApplicationIconBadgeNumber:x]; 接口统一设置。

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!