From 3a9859546aa8f9881d1c26ebebbeb2db2923b007 Mon Sep 17 00:00:00 2001 From: Christian Schneppe Date: Thu, 13 Sep 2018 17:31:00 +0200 Subject: make channel for video compression, updater, backup --- .../messenger/services/NotificationService.java | 24 ++++++++++++++++++++++ 1 file changed, 24 insertions(+) (limited to 'src/main/java/de/pixart/messenger') diff --git a/src/main/java/de/pixart/messenger/services/NotificationService.java b/src/main/java/de/pixart/messenger/services/NotificationService.java index 4cdde8390..913dd6f1e 100644 --- a/src/main/java/de/pixart/messenger/services/NotificationService.java +++ b/src/main/java/de/pixart/messenger/services/NotificationService.java @@ -71,6 +71,9 @@ public class NotificationService { public static final int ERROR_NOTIFICATION_ID = NOTIFICATION_ID_MULTIPLIER * 6; public static final String MESSAGES_CHANNEL_ID = "messages"; public static final String FOREGROUND_CHANNEL_ID = "foreground"; + public static final String BACKUP_CHANNEL_ID = "backup"; + public static final String UPDATE_CHANNEL_ID = "appupdate"; + public static final String VIDEOCOMPRESSION_CHANNEL_ID = "compression"; public static final String ERROR_CHANNEL_ID = "error"; private final XmppConnectionService mXmppConnectionService; @@ -118,6 +121,27 @@ public class NotificationService { foregroundServiceChannel.setGroup("status"); notificationManager.createNotificationChannel(foregroundServiceChannel); + final NotificationChannel backupChannel = new NotificationChannel(BACKUP_CHANNEL_ID, + c.getString(R.string.backup_channel_name), + NotificationManager.IMPORTANCE_LOW); + backupChannel.setShowBadge(false); + backupChannel.setGroup("status"); + notificationManager.createNotificationChannel(backupChannel); + + final NotificationChannel videoCompressionChannel = new NotificationChannel(VIDEOCOMPRESSION_CHANNEL_ID, + c.getString(R.string.video_compression_channel_name), + NotificationManager.IMPORTANCE_LOW); + videoCompressionChannel.setShowBadge(false); + videoCompressionChannel.setGroup("status"); + notificationManager.createNotificationChannel(videoCompressionChannel); + + final NotificationChannel AppUpdateChannel = new NotificationChannel(UPDATE_CHANNEL_ID, + c.getString(R.string.app_update_channel_name), + NotificationManager.IMPORTANCE_LOW); + AppUpdateChannel.setShowBadge(false); + AppUpdateChannel.setGroup("status"); + notificationManager.createNotificationChannel(AppUpdateChannel); + final NotificationChannel errorChannel = new NotificationChannel(ERROR_CHANNEL_ID, c.getString(R.string.error_channel_name), NotificationManager.IMPORTANCE_LOW); -- cgit v1.2.3