Android 通知状态栏中出现空红圈!

发布于 2024-09-30 11:56:25 字数 476 浏览 1 评论 0原文

当我的状态栏通知中包含数字时,它会显示该数字。但稍后,如果我显示另一条通知来替换这个通知,并且没有编号,它会显示一个空红色圆圈。这个圈子不应该存在。怎样去掉红圈呢?请参阅此处的图片:http://jump.fm/UYHGV

我已经尝试过:

notification.number = 0;

并且

notification.number = -1;

忘记取消通知第一的。由于无法查询通知服务中的现有通知,因此我无法检测前一个通知是否需要更新。如果我每次通知都取消,用户会看到状态栏偶尔闪烁,这很烦人。

请指教。

以马内利

When I have a status bar notification with a number inside, it shows the number fine. But later if I show another notification to replace this one, with no number, it shows an empty red circle. This circle shouldn't be there. How do I remove the red circle? See image here: http://jump.fm/UYHGV

I've already tried:

notification.number = 0;

and

notification.number = -1;

And forget about canceling notifications first. Since there's no way to query the notification service for existing notifications, I can't detect if the previous one needs to be updated. If I would cancel every time I notify, the user will see the status bar flashing once in a while, which is annoying.

Please advise.

Emmanuel

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文