[feature] add ability to set global filter/sort/display for Manga chapters (#3622)

* - [feature] add ability to set global filter/sort/display for Manga chapters

* - move default chapter settings functionality to overflow menu
- code clean up

* - show confirmation dialog when user selects "Set as Default" option in Chapter Settings

* - hide overflow menu in LibrarySettingsSheet

* - apply default chapter settings if manga is added to Library from a Source's browsing screen

Co-authored-by: arkon <arkon@users.noreply.github.com>
This commit is contained in:
lmj0011
2020-09-14 14:58:34 -05:00
committed by GitHub
parent 791a7d5a01
commit 64050e8266
14 changed files with 252 additions and 19 deletions
@@ -28,6 +28,7 @@ import eu.kanade.tachiyomi.ui.browse.source.filter.TextItem
import eu.kanade.tachiyomi.ui.browse.source.filter.TextSectionItem
import eu.kanade.tachiyomi.ui.browse.source.filter.TriStateItem
import eu.kanade.tachiyomi.ui.browse.source.filter.TriStateSectionItem
import eu.kanade.tachiyomi.util.chapter.ChapterSettingsHelper
import eu.kanade.tachiyomi.util.removeCovers
import kotlinx.coroutines.flow.subscribe
import rx.Observable
@@ -268,6 +269,8 @@ open class BrowseSourcePresenter(
if (!manga.favorite) {
manga.removeCovers(coverCache)
} else {
ChapterSettingsHelper.applySettingDefaultsFromPreferences(manga)
}
db.insertManga(manga).executeAsBlocking()