Split general reader settings into reading mode and display
(cherry picked from commit d353a3457d194ed246d218a086695aeedb8d0e42)
This commit is contained in:
parent
57565fce2d
commit
c2c2a3be01
@ -22,7 +22,7 @@ class SettingsReaderController : SettingsController() {
|
|||||||
titleRes = R.string.pref_category_reader
|
titleRes = R.string.pref_category_reader
|
||||||
|
|
||||||
preferenceCategory {
|
preferenceCategory {
|
||||||
titleRes = R.string.pref_category_general
|
titleRes = R.string.pref_category_reading_mode
|
||||||
|
|
||||||
intListPreference {
|
intListPreference {
|
||||||
key = Keys.defaultViewer
|
key = Keys.defaultViewer
|
||||||
@ -35,6 +35,43 @@ class SettingsReaderController : SettingsController() {
|
|||||||
defaultValue = "2"
|
defaultValue = "2"
|
||||||
summary = "%s"
|
summary = "%s"
|
||||||
}
|
}
|
||||||
|
intListPreference {
|
||||||
|
key = Keys.doubleTapAnimationSpeed
|
||||||
|
titleRes = R.string.pref_double_tap_anim_speed
|
||||||
|
entries = arrayOf(context.getString(R.string.double_tap_anim_speed_0), context.getString(R.string.double_tap_anim_speed_fast), context.getString(R.string.double_tap_anim_speed_normal))
|
||||||
|
entryValues = arrayOf("1", "250", "500") // using a value of 0 breaks the image viewer, so min is 1
|
||||||
|
defaultValue = "500"
|
||||||
|
summary = "%s"
|
||||||
|
}
|
||||||
|
switchPreference {
|
||||||
|
key = Keys.showReadingMode
|
||||||
|
titleRes = R.string.pref_show_reading_mode
|
||||||
|
summaryRes = R.string.pref_show_reading_mode_summary
|
||||||
|
defaultValue = true
|
||||||
|
}
|
||||||
|
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
|
||||||
|
switchPreference {
|
||||||
|
key = Keys.trueColor
|
||||||
|
titleRes = R.string.pref_true_color
|
||||||
|
summaryRes = R.string.pref_true_color_summary
|
||||||
|
defaultValue = false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
switchPreference {
|
||||||
|
key = Keys.cropBorders
|
||||||
|
titleRes = R.string.pref_crop_borders
|
||||||
|
defaultValue = false
|
||||||
|
}
|
||||||
|
switchPreference {
|
||||||
|
key = Keys.enableTransitions
|
||||||
|
titleRes = R.string.pref_page_transitions
|
||||||
|
defaultValue = true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
preferenceCategory {
|
||||||
|
titleRes = R.string.pref_category_display
|
||||||
|
|
||||||
intListPreference {
|
intListPreference {
|
||||||
key = Keys.rotation
|
key = Keys.rotation
|
||||||
titleRes = R.string.pref_rotation_type
|
titleRes = R.string.pref_rotation_type
|
||||||
@ -54,14 +91,6 @@ class SettingsReaderController : SettingsController() {
|
|||||||
defaultValue = "1"
|
defaultValue = "1"
|
||||||
summary = "%s"
|
summary = "%s"
|
||||||
}
|
}
|
||||||
intListPreference {
|
|
||||||
key = Keys.doubleTapAnimationSpeed
|
|
||||||
titleRes = R.string.pref_double_tap_anim_speed
|
|
||||||
entries = arrayOf(context.getString(R.string.double_tap_anim_speed_0), context.getString(R.string.double_tap_anim_speed_fast), context.getString(R.string.double_tap_anim_speed_normal))
|
|
||||||
entryValues = arrayOf("1", "250", "500") // using a value of 0 breaks the image viewer, so min is 1
|
|
||||||
defaultValue = "500"
|
|
||||||
summary = "%s"
|
|
||||||
}
|
|
||||||
switchPreference {
|
switchPreference {
|
||||||
key = Keys.fullscreen
|
key = Keys.fullscreen
|
||||||
titleRes = R.string.pref_fullscreen
|
titleRes = R.string.pref_fullscreen
|
||||||
@ -86,30 +115,6 @@ class SettingsReaderController : SettingsController() {
|
|||||||
titleRes = R.string.pref_show_page_number
|
titleRes = R.string.pref_show_page_number
|
||||||
defaultValue = true
|
defaultValue = true
|
||||||
}
|
}
|
||||||
switchPreference {
|
|
||||||
key = Keys.showReadingMode
|
|
||||||
titleRes = R.string.pref_show_reading_mode
|
|
||||||
summaryRes = R.string.pref_show_reading_mode_summary
|
|
||||||
defaultValue = true
|
|
||||||
}
|
|
||||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
|
|
||||||
switchPreference {
|
|
||||||
key = Keys.trueColor
|
|
||||||
titleRes = R.string.pref_true_color
|
|
||||||
summaryRes = R.string.pref_true_color_summary
|
|
||||||
defaultValue = false
|
|
||||||
}
|
|
||||||
}
|
|
||||||
switchPreference {
|
|
||||||
key = Keys.cropBorders
|
|
||||||
titleRes = R.string.pref_crop_borders
|
|
||||||
defaultValue = false
|
|
||||||
}
|
|
||||||
switchPreference {
|
|
||||||
key = Keys.enableTransitions
|
|
||||||
titleRes = R.string.pref_page_transitions
|
|
||||||
defaultValue = true
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
preferenceCategory {
|
preferenceCategory {
|
||||||
|
@ -294,6 +294,7 @@
|
|||||||
<string name="color_filter_b_value">B</string>
|
<string name="color_filter_b_value">B</string>
|
||||||
<string name="color_filter_a_value">A</string>
|
<string name="color_filter_a_value">A</string>
|
||||||
<string name="pref_always_show_chapter_transition">Always show chapter transition</string>
|
<string name="pref_always_show_chapter_transition">Always show chapter transition</string>
|
||||||
|
<string name="pref_category_reading_mode">Reading mode</string>
|
||||||
<string name="pref_category_reading">Reading</string>
|
<string name="pref_category_reading">Reading</string>
|
||||||
<string name="pref_webtoon_side_padding">Side padding</string>
|
<string name="pref_webtoon_side_padding">Side padding</string>
|
||||||
<string name="webtoon_side_padding_0">None</string>
|
<string name="webtoon_side_padding_0">None</string>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user