如何在iOS应用程序中向图标添加通知 [英] How to add notifications to icon in iOS application

查看:95
本文介绍了如何在iOS应用程序中向图标添加通知的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我看到iPhone中的某些应用程序显示一个红色圆圈,其中包含来自应用程序的通知数量,这是怎么做的?

I see that some applications in iPhone show a red circle with the number of notifications from the application, how is that done?

推荐答案

[[UIApplication sharedApplication] setApplicationIconBadgeNumber:99]

零值隐藏徽章。

这篇关于如何在iOS应用程序中向图标添加通知的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆