1
0
Fork 0
mirror of https://github.com/syncthing/syncthing-android.git synced 2024-11-29 15:51:17 +00:00

Show notification badge if user interaction is required (fixes #406) (#408)

Ref.: Android 8.0
This commit is contained in:
Catfriend1 2019-04-27 09:09:42 +02:00 committed by GitHub
parent 38f94ce34c
commit 0ca5d851f2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -57,6 +57,7 @@ public class NotificationHandler {
mPersistentChannel.enableLights(false);
mPersistentChannel.enableVibration(false);
mPersistentChannel.setSound(null, null);
mPersistentChannel.setShowBadge(false);
mNotificationManager.createNotificationChannel(mPersistentChannel);
mPersistentChannelWaiting = new NotificationChannel(
@ -65,6 +66,7 @@ public class NotificationHandler {
mPersistentChannelWaiting.enableLights(false);
mPersistentChannelWaiting.enableVibration(false);
mPersistentChannelWaiting.setSound(null, null);
mPersistentChannelWaiting.setShowBadge(false);
mNotificationManager.createNotificationChannel(mPersistentChannelWaiting);
mInfoChannel = new NotificationChannel(
@ -72,6 +74,7 @@ public class NotificationHandler {
NotificationManager.IMPORTANCE_LOW);
mPersistentChannel.enableVibration(false);
mPersistentChannel.setSound(null, null);
mPersistentChannel.setShowBadge(true);
mNotificationManager.createNotificationChannel(mInfoChannel);
} else {
mPersistentChannel = null;