Commit 3816137d by Kunj Gupta

Added notification icon and make notification readable.

parent a3d5bb07
......@@ -158,13 +158,15 @@ public class NotificationMessagingService extends FirebaseMessagingService {
Uri defaultSoundUri = RingtoneManager.getDefaultUri(RingtoneManager.TYPE_NOTIFICATION);
String message = "Status: " + notification.getPriority() + "\n" + notification.getShortDescription();
NotificationCompat.Builder notificationBuilder = new NotificationCompat.Builder(this, CHANNEL_ID)
.setSmallIcon(R.drawable.notification_icon)
.setContentTitle(notification.getTitle())
.setContentText(notification.getShortDescription() +"\n" + "Status: "+notification.getPriority())
.setContentText(message)
.setAutoCancel(true)
// .setContentIntent(null)
.setChannelId(CHANNEL_ID)
.setStyle(new NotificationCompat.BigTextStyle().bigText(message))
.setSound(defaultSoundUri);
NotificationManager notificationManager =
......

104 Bytes | W: | H:

459 Bytes | W: | H:

app/src/main/res/drawable-hdpi/notification_icon.png
app/src/main/res/drawable-hdpi/notification_icon.png
app/src/main/res/drawable-hdpi/notification_icon.png
app/src/main/res/drawable-hdpi/notification_icon.png
  • 2-up
  • Swipe
  • Onion skin

92 Bytes | W: | H:

304 Bytes | W: | H:

app/src/main/res/drawable-mdpi/notification_icon.png
app/src/main/res/drawable-mdpi/notification_icon.png
app/src/main/res/drawable-mdpi/notification_icon.png
app/src/main/res/drawable-mdpi/notification_icon.png
  • 2-up
  • Swipe
  • Onion skin

121 Bytes | W: | H:

623 Bytes | W: | H:

app/src/main/res/drawable-xhdpi/notification_icon.png
app/src/main/res/drawable-xhdpi/notification_icon.png
app/src/main/res/drawable-xhdpi/notification_icon.png
app/src/main/res/drawable-xhdpi/notification_icon.png
  • 2-up
  • Swipe
  • Onion skin

169 Bytes | W: | H:

940 Bytes | W: | H:

app/src/main/res/drawable-xxhdpi/notification_icon.png
app/src/main/res/drawable-xxhdpi/notification_icon.png
app/src/main/res/drawable-xxhdpi/notification_icon.png
app/src/main/res/drawable-xxhdpi/notification_icon.png
  • 2-up
  • Swipe
  • Onion skin
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment