【问题标题】:How to create a status bar icon on the right side? (Android)如何在右侧创建状态栏图标? (安卓)
【发布时间】:2010-03-29 17:47:59
【问题描述】:

NotificationNotificationManager 用于创建放置在屏幕左上角的图标。 Notification 也需要在状态栏下拉菜单上有一个条目。

但是,右侧的电池、信号强度、无线指示灯等图标不需要在状态栏上输入任何内容。

如何在状态栏下拉菜单中没有任何条目的情况下制作此类图标?

【问题讨论】:

标签: android icons notifications notificationmanager


【解决方案1】:

我相信通知栏的右侧区域是为操作系统保留的。

【讨论】:

  • Google 日语输入法在右侧显示 A 或あ 图标。它不是系统应用程序,它在 4.4.2 三星设备和 5.1.1 Nexus 设备上都有。所以一定有某种API。
  • 请注意,我在 2010 年编写了此答案。如果在较新版本的 Android 中有办法做到这一点,请随时将其添加为新答案。
【解决方案2】:

你为什么会接受上面的答案。 . .如果您使用 android 源代码并自己构建它,那么在右侧设置图标并非不可能。我在How to create a Notification \ status bar icon on the right side?How to create a Notification \ status bar icon on the right side?

【讨论】:

    猜你喜欢
    • 2013-08-23
    • 2010-12-23
    • 1970-01-01
    • 2014-07-15
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多