From f188d1c0f3049880af7506db62ac40eb42a004a6 Mon Sep 17 00:00:00 2001 From: Koitharu Date: Tue, 27 Jun 2023 12:34:12 +0300 Subject: [PATCH] Remove ongoing flag from background work notifications --- app/build.gradle | 2 +- .../org/koitharu/kotatsu/local/ui/LocalChaptersRemoveService.kt | 2 +- .../org/koitharu/kotatsu/suggestions/ui/SuggestionsWorker.kt | 2 +- .../kotlin/org/koitharu/kotatsu/tracker/work/TrackWorker.kt | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/app/build.gradle b/app/build.gradle index 94e4a0b83..609a9776a 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -79,7 +79,7 @@ afterEvaluate { } dependencies { //noinspection GradleDependency - implementation('com.github.KotatsuApp:kotatsu-parsers:7ccacf4c27') { + implementation('com.github.KotatsuApp:kotatsu-parsers:b8f0ea4690') { exclude group: 'org.json', module: 'json' } diff --git a/app/src/main/kotlin/org/koitharu/kotatsu/local/ui/LocalChaptersRemoveService.kt b/app/src/main/kotlin/org/koitharu/kotatsu/local/ui/LocalChaptersRemoveService.kt index 754c8ffbb..09a87391e 100644 --- a/app/src/main/kotlin/org/koitharu/kotatsu/local/ui/LocalChaptersRemoveService.kt +++ b/app/src/main/kotlin/org/koitharu/kotatsu/local/ui/LocalChaptersRemoveService.kt @@ -85,7 +85,7 @@ class LocalChaptersRemoveService : CoroutineIntentService() { .setProgress(0, 0, true) .setSmallIcon(android.R.drawable.stat_notify_sync) .setForegroundServiceBehavior(NotificationCompat.FOREGROUND_SERVICE_DEFERRED) - .setOngoing(true) + .setOngoing(false) .build() startForeground(NOTIFICATION_ID, notification) } diff --git a/app/src/main/kotlin/org/koitharu/kotatsu/suggestions/ui/SuggestionsWorker.kt b/app/src/main/kotlin/org/koitharu/kotatsu/suggestions/ui/SuggestionsWorker.kt index 5398035a4..e8e2700f4 100644 --- a/app/src/main/kotlin/org/koitharu/kotatsu/suggestions/ui/SuggestionsWorker.kt +++ b/app/src/main/kotlin/org/koitharu/kotatsu/suggestions/ui/SuggestionsWorker.kt @@ -109,7 +109,7 @@ class SuggestionsWorker @AssistedInject constructor( .setPriority(NotificationCompat.PRIORITY_MIN) .setCategory(NotificationCompat.CATEGORY_SERVICE) .setDefaults(0) - .setOngoing(true) + .setOngoing(false) .setSilent(true) .setProgress(0, 0, true) .setSmallIcon(android.R.drawable.stat_notify_sync) diff --git a/app/src/main/kotlin/org/koitharu/kotatsu/tracker/work/TrackWorker.kt b/app/src/main/kotlin/org/koitharu/kotatsu/tracker/work/TrackWorker.kt index 6b8f4ffa0..2880969dc 100644 --- a/app/src/main/kotlin/org/koitharu/kotatsu/tracker/work/TrackWorker.kt +++ b/app/src/main/kotlin/org/koitharu/kotatsu/tracker/work/TrackWorker.kt @@ -221,7 +221,7 @@ class TrackWorker @AssistedInject constructor( .setPriority(NotificationCompat.PRIORITY_MIN) .setCategory(NotificationCompat.CATEGORY_SERVICE) .setDefaults(0) - .setOngoing(true) + .setOngoing(false) .setSilent(true) .setProgress(0, 0, true) .setSmallIcon(android.R.drawable.stat_notify_sync)