Raise importance of backup notifications to show them in status bar

This commit is contained in:
Torsten Grote 2019-08-01 12:06:15 +02:00
parent bd968be0b1
commit e2a3e3d2b7
No known key found for this signature in database
GPG key ID: 3E5F77D92CF891FF

View file

@ -2,7 +2,7 @@ package com.stevesoltys.backup
import android.app.NotificationChannel import android.app.NotificationChannel
import android.app.NotificationManager import android.app.NotificationManager
import android.app.NotificationManager.IMPORTANCE_MIN import android.app.NotificationManager.IMPORTANCE_LOW
import android.app.backup.BackupProgress import android.app.backup.BackupProgress
import android.app.backup.IBackupObserver import android.app.backup.IBackupObserver
import android.content.Context import android.content.Context
@ -25,7 +25,7 @@ class NotificationBackupObserver(
private val pm = context.packageManager private val pm = context.packageManager
private val nm = context.getSystemService(NotificationManager::class.java).apply { private val nm = context.getSystemService(NotificationManager::class.java).apply {
val title = context.getString(R.string.notification_channel_title) val title = context.getString(R.string.notification_channel_title)
val channel = NotificationChannel(CHANNEL_ID, title, IMPORTANCE_MIN).apply { val channel = NotificationChannel(CHANNEL_ID, title, IMPORTANCE_LOW).apply {
enableVibration(false) enableVibration(false)
} }
createNotificationChannel(channel) createNotificationChannel(channel)