Android的 - 更改通知图标 [英] Android - Change Notification Icon
问题描述
我想知道,如果它可能有一个不同的Notificationbar图标比启动或应用程序图标。我想为我的推送通知显示其他图标。这可能吗?谢谢你。
I would like to know if its possible to have an different Notificationbar Icon than the Launcher or Application Icon. I would like to display an other icon for my push notifications. Is this possible? Thanks.
推荐答案
有关API< 11,通知
构造允许一个<一href="http://developer.android.com/reference/android/app/Notification.html#Notification%28int,%20java.lang.CharSequence,%20long%29">icon要指定。对于API> 10, setSmallIcon
和 setLargeIcon
方法<一href="http://developer.android.com/reference/android/app/Notification.Builder.html">Notifcation.Builder让同样的事情。
For API < 11, the Notification
constructor allowed an icon to be specified. For API > 10, the setSmallIcon
and setLargeIcon
methods for Notifcation.Builder allow much the same thing.
这篇关于Android的 - 更改通知图标的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!