Android Lollipop changed the way that notification icons are required to be configured. Lollipop icons are now required to be a white colored icon with an alpha value. |
You can define the icons and the color directly on the default notification factory:
- Large Icon - DefaultNotificationFactory| Urban Airship Android Library
- Small Icon - DefaultNotificationFactory| Urban Airship Android Library
- Accent Color - DefaultNotificationFactory| Urban Airship Android Library
These methods pass the values directly to the corresponding notification builder setters. See NotificationCompat.Builder | Android Developers for more information.
In the end, you should have something similar to the following:
// Create Notification Factory
DefaultNotificationFactory defaultNotificationFactory = new DefaultNotificationFactory(getApplicationContext());
// Get the Icon image from resources
defaultNotificationFactory.setSmallIconId(R.drawable.ic_notification);
// Set the accent color
defaultNotificationFactory.setColor(NotificationCompat.COLOR_DEFAULT);
airship.getPushManager().setNotificationFactory(defaultNotificationFactory);
Related Content: