diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/ReaderActivity.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/ReaderActivity.kt index 42ba04729..62261ba3a 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/ReaderActivity.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/ReaderActivity.kt @@ -414,6 +414,11 @@ class ReaderActivity : BaseRxActivity() setOnClickListener { ReaderSettingsSheet(this@ReaderActivity).show() } + + setOnLongClickListener { + ReaderSettingsSheet(this@ReaderActivity, showColorFilterSettings = true).show() + true + } } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/setting/ReaderSettingsSheet.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/setting/ReaderSettingsSheet.kt index 7d50079d1..f5d5648cd 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/setting/ReaderSettingsSheet.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/setting/ReaderSettingsSheet.kt @@ -8,7 +8,10 @@ import eu.kanade.tachiyomi.ui.reader.ReaderActivity import eu.kanade.tachiyomi.widget.SimpleTabSelectedListener import eu.kanade.tachiyomi.widget.sheet.TabbedBottomSheetDialog -class ReaderSettingsSheet(private val activity: ReaderActivity) : TabbedBottomSheetDialog(activity) { +class ReaderSettingsSheet( + private val activity: ReaderActivity, + showColorFilterSettings: Boolean = false, +) : TabbedBottomSheetDialog(activity) { private val readingModeSettings = ReaderReadingModeSettings(activity) private val generalSettings = ReaderGeneralSettings(activity) @@ -40,6 +43,10 @@ class ReaderSettingsSheet(private val activity: ReaderActivity) : TabbedBottomSh } } }) + + if (showColorFilterSettings) { + binding.tabs.getTabAt(filterTabIndex)?.select() + } } override fun getTabViews() = listOf( diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/sheet/TabbedBottomSheetDialog.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/sheet/TabbedBottomSheetDialog.kt index a5b3a73bd..ea40f6b4b 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/sheet/TabbedBottomSheetDialog.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/sheet/TabbedBottomSheetDialog.kt @@ -8,7 +8,7 @@ import eu.kanade.tachiyomi.widget.ViewPagerAdapter abstract class TabbedBottomSheetDialog(private val activity: Activity) : BaseBottomSheetDialog(activity) { - val binding: CommonTabbedSheetBinding = CommonTabbedSheetBinding.inflate(activity.layoutInflater) + val binding = CommonTabbedSheetBinding.inflate(activity.layoutInflater) init { val adapter = LibrarySettingsSheetAdapter()