Remove skipped updates notification

Seems to cause more confusion than it's worth.
Will update the UI for the library update skip options to better
explain what they're for later.
This commit is contained in:
arkon 2023-12-26 13:13:33 -05:00
parent 8939274b5c
commit bfb0d31ff6
5 changed files with 2 additions and 33 deletions

View file

@ -208,7 +208,7 @@ object SettingsDataScreen : SearchableSettings {
val cacheReadableSize = remember(cacheReadableSizeSema) { chapterCache.readableSize }
return Preference.PreferenceGroup(
title = stringResource(MR.strings.label_data),
title = stringResource(MR.strings.pref_storage_usage),
preferenceItems = persistentListOf(
Preference.PreferenceItem.CustomPreference(
title = stringResource(MR.strings.pref_storage_usage),

View file

@ -235,7 +235,6 @@ class LibraryUpdateJob(private val context: Context, workerParams: WorkerParamet
.map { (reason, entries) -> "$reason: [${entries.map { it.first.title }.sorted().joinToString()}]" }
.joinToString()
}
notifier.showUpdateSkippedNotification(skippedUpdates.size)
}
}

View file

@ -139,27 +139,6 @@ class LibraryUpdateNotifier(private val context: Context) {
}
}
/**
* Shows notification containing update entries that were skipped.
*
* @param skipped Number of entries that were skipped during the update.
*/
fun showUpdateSkippedNotification(skipped: Int) {
if (skipped == 0) {
return
}
context.notify(
Notifications.ID_LIBRARY_SKIPPED,
Notifications.CHANNEL_LIBRARY_SKIPPED,
) {
setContentTitle(context.stringResource(MR.strings.notification_update_skipped, skipped))
setContentText(context.stringResource(MR.strings.learn_more))
setSmallIcon(R.drawable.ic_tachi)
setContentIntent(NotificationHandler.openUrl(context, HELP_SKIPPED_URL))
}
}
/**
* Shows the notification containing the result of the update done by the service.
*
@ -385,4 +364,3 @@ class LibraryUpdateNotifier(private val context: Context) {
private const val NOTIF_MAX_CHAPTERS = 5
private const val NOTIF_TITLE_MAX_LEN = 45
private const val NOTIF_ICON_SIZE = 192
private const val HELP_SKIPPED_URL = "https://tachiyomi.org/docs/faq/library#why-is-global-update-skipping-entries"

View file

@ -30,8 +30,6 @@ object Notifications {
const val ID_LIBRARY_SIZE_WARNING = -103
const val CHANNEL_LIBRARY_ERROR = "library_errors_channel"
const val ID_LIBRARY_ERROR = -102
const val CHANNEL_LIBRARY_SKIPPED = "library_skipped_channel"
const val ID_LIBRARY_SKIPPED = -104
/**
* Notification channel and ids used by the downloader.
@ -86,6 +84,7 @@ object Notifications {
"updates_ext_channel",
"downloader_cache_renewal",
"crash_logs_channel",
"library_skipped_channel",
)
/**
@ -132,11 +131,6 @@ object Notifications {
setGroup(GROUP_LIBRARY)
setShowBadge(false)
},
buildNotificationChannel(CHANNEL_LIBRARY_SKIPPED, IMPORTANCE_LOW) {
setName(context.stringResource(MR.strings.channel_skipped))
setGroup(GROUP_LIBRARY)
setShowBadge(false)
},
buildNotificationChannel(CHANNEL_NEW_CHAPTERS, IMPORTANCE_DEFAULT) {
setName(context.stringResource(MR.strings.channel_new_chapters))
},

View file

@ -830,7 +830,6 @@
<string name="notification_chapters_single_and_more">Chapter %1$s and %2$d more</string>
<string name="notification_chapters_multiple">Chapters %1$s</string>
<string name="notification_update_error">%1$d update(s) failed</string>
<string name="notification_update_skipped">%1$d update(s) skipped</string>
<string name="learn_more">Tap to learn more</string>
<string name="notification_cover_update_failed">Failed to update cover</string>
<string name="notification_first_add_to_library">Please add the entry to your library before doing this</string>
@ -896,7 +895,6 @@
<string name="channel_progress">Progress</string>
<string name="channel_complete">Complete</string>
<string name="channel_errors">Errors</string>
<string name="channel_skipped">Skipped</string>
<string name="channel_new_chapters">Chapter updates</string>
<string name="channel_app_updates">App updates</string>
<string name="channel_ext_updates">Extension updates</string>