Navigate to pan / landscape zoom (#6481)

* pan if the image is zoomed instead of navigating away
quickly display full landscape image before zooming to fit height in fit to screen

* add Tap to pan preference, defaults to true
add landscape zoom preference, defaults to false

* hide landscape image zoom option if scale is not fit screen

* fix landscape image zoom for first image and loading image

* properly reload pagerholders when landscape zoom option is changed

* enable landscape zoom by default
This commit is contained in:
Gauthier
2022-02-13 00:21:54 +08:00
committed by GitHub
parent 71ddb16574
commit d8719ceee9
10 changed files with 223 additions and 15 deletions
@@ -183,6 +183,11 @@ class SettingsReaderController : SettingsController() {
entryValues = arrayOf("1", "2", "3", "4", "5", "6")
summary = "%s"
}
switchPreference {
bindTo(preferences.landscapeZoom())
titleRes = R.string.pref_landscape_zoom
visibleIf(preferences.imageScaleType()) { it == 1 }
}
intListPreference {
bindTo(preferences.zoomStart())
titleRes = R.string.pref_zoom_start
@@ -199,6 +204,10 @@ class SettingsReaderController : SettingsController() {
bindTo(preferences.cropBorders())
titleRes = R.string.pref_crop_borders
}
switchPreference {
bindTo(preferences.navigateToPan())
titleRes = R.string.pref_navigate_pan
}
switchPreference {
bindTo(preferences.dualPageSplitPaged())
titleRes = R.string.pref_dual_page_split