Remove autoAddTrack preference

This commit is contained in:
arkon 2021-07-18 15:00:07 -04:00
parent fcd6fe5d8a
commit dce3049446
6 changed files with 3 additions and 16 deletions

View File

@ -99,8 +99,6 @@ object PreferenceKeys {
const val autoUpdateTrack = "pref_auto_update_manga_sync_key" const val autoUpdateTrack = "pref_auto_update_manga_sync_key"
const val autoAddTrack = "pref_auto_add_track_key"
const val lastUsedSource = "last_catalogue_source" const val lastUsedSource = "last_catalogue_source"
const val lastUsedCategory = "last_used_category" const val lastUsedCategory = "last_used_category"

View File

@ -177,8 +177,6 @@ class PreferencesHelper(val context: Context) {
fun autoUpdateTrack() = prefs.getBoolean(Keys.autoUpdateTrack, true) fun autoUpdateTrack() = prefs.getBoolean(Keys.autoUpdateTrack, true)
fun autoAddTrack() = prefs.getBoolean(Keys.autoAddTrack, true)
fun lastUsedSource() = flowPrefs.getLong(Keys.lastUsedSource, -1) fun lastUsedSource() = flowPrefs.getLong(Keys.lastUsedSource, -1)
fun lastUsedCategory() = flowPrefs.getInt(Keys.lastUsedCategory, 0) fun lastUsedCategory() = flowPrefs.getInt(Keys.lastUsedCategory, 0)

View File

@ -267,9 +267,7 @@ open class BrowseSourcePresenter(
} else { } else {
ChapterSettingsHelper.applySettingDefaults(manga) ChapterSettingsHelper.applySettingDefaults(manga)
if (prefs.autoAddTrack()) { autoAddTrack(manga)
autoAddTrack(manga)
}
} }
db.insertManga(manga).executeAsBlocking() db.insertManga(manga).executeAsBlocking()

View File

@ -540,7 +540,7 @@ class MangaController :
} }
} }
if (source != null && preferences.autoAddTrack()) { if (source != null) {
presenter.trackList presenter.trackList
.map { it.service } .map { it.service }
.filterIsInstance<EnhancedTrackService>() .filterIsInstance<EnhancedTrackService>()

View File

@ -76,12 +76,6 @@ class SettingsTrackingController :
preferenceCategory { preferenceCategory {
titleRes = R.string.enhanced_services titleRes = R.string.enhanced_services
switchPreference {
key = Keys.autoAddTrack
titleRes = R.string.pref_auto_add_track
defaultValue = true
}
trackPreference(trackManager.komga) { trackPreference(trackManager.komga) {
val acceptedSources = trackManager.komga.getAcceptedSources() val acceptedSources = trackManager.komga.getAcceptedSources()
val hasValidSourceInstalled = sourceManager.getCatalogueSources() val hasValidSourceInstalled = sourceManager.getCatalogueSources()

View File

@ -385,8 +385,7 @@
<string name="services">Services</string> <string name="services">Services</string>
<string name="tracking_info">One-way sync to update the chapter progress in tracking services. Set up tracking for individual manga entries from their tracking button.</string> <string name="tracking_info">One-way sync to update the chapter progress in tracking services. Set up tracking for individual manga entries from their tracking button.</string>
<string name="enhanced_services">Enhanced services</string> <string name="enhanced_services">Enhanced services</string>
<string name="pref_auto_add_track">Automatically track manga when added to library</string> <string name="enhanced_tracking_info">Services that provide enhanced features for specific sources. Manga are automatically tracked when added to your library.</string>
<string name="enhanced_tracking_info">Services that provide enhanced features for specific sources.</string>
<!-- Browse section --> <!-- Browse section -->
<string name="pref_enable_automatic_extension_updates">Check for extension updates</string> <string name="pref_enable_automatic_extension_updates">Check for extension updates</string>