aboutsummaryrefslogtreecommitdiffstats
path: root/src/main
diff options
context:
space:
mode:
authorSam Whited <sam@samwhited.com>2015-01-17 23:41:57 -0500
committerSam Whited <sam@samwhited.com>2015-01-17 23:41:57 -0500
commit99989cd1d52bda9016d21df8f1d876c569498135 (patch)
tree5e117da0f48d4724810690faca0668e107f48d63 /src/main
parentc17005218f454397535bcbddf09ecf75553fb2b8 (diff)
Add some Android 21 notification features
Diffstat (limited to '')
-rw-r--r--src/main/java/eu/siacs/conversations/services/NotificationService.java4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/main/java/eu/siacs/conversations/services/NotificationService.java b/src/main/java/eu/siacs/conversations/services/NotificationService.java
index 8c3aff16..4355dba0 100644
--- a/src/main/java/eu/siacs/conversations/services/NotificationService.java
+++ b/src/main/java/eu/siacs/conversations/services/NotificationService.java
@@ -203,6 +203,10 @@ public class NotificationService {
mBuilder.setSound(Uri.parse(ringtone));
}
}
+ if (android.os.Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) {
+ mBuilder.setCategory(Notification.CATEGORY_MESSAGE);
+ mBuilder.setColor(mXmppConnectionService.getResources().getColor(R.color.primary));
+ }
mBuilder.setSmallIcon(R.drawable.ic_notification);
mBuilder.setDeleteIntent(createDeleteIntent());
mBuilder.setLights(0xffffffff, 2000, 4000);