Fixed Push Notification Icon showing White Android
As we already know that this is the old problem, actually this is not a problem. This is what we need to do a proper implementation.
Why I’m writing this article is just because I have seen in many applications the push notification icon is showing the white icon when we run this in android 6.0 and greater versions.
We always need to be updated on the things according to the OS versions of Android. As we know that Android new OS versions coming rapidly with the new change so we need to change accordingly.
Without wasting the time let’s dig into the implementation, we just need to change the two things.
Implementation of Notification Builder for below and above Lollipop OS version would be:
We just need to change the small icon and color for notification according to the OS versions like below code:
setColor is only available in Lollipop and it only affect to background of the icon.
now your problem will resolved completely…run and test it.
If you want to learn some other topic check the link below:
Sharing the knowledge is caring :-)
If you want to learn more about it then check the official links below:
Android 5.0 Behavior Changes | Android Developers
Dev Byte: What's New in Android 5.0 Dev Byte: Notifications API Level: Ringtone, MediaPlayer, or Vibrator classes…
Product icons are the visual expression of a brand and product, including their services and tools. Icons communicate…