feat: 优化

pull/277/head
kunfei 5 years ago
parent 869e13e26a
commit 7ce476c35e
  1. 2
      app/src/main/java/io/legado/app/help/ReadBookConfig.kt
  2. 1
      app/src/main/java/io/legado/app/help/storage/Restore.kt

@ -105,8 +105,8 @@ object ReadBookConfig {
//配置写入读取 //配置写入读取
var autoReadSpeed = App.INSTANCE.getPrefInt(PreferKey.autoReadSpeed, 46) var autoReadSpeed = App.INSTANCE.getPrefInt(PreferKey.autoReadSpeed, 46)
set(value) { set(value) {
App.INSTANCE.putPrefInt(PreferKey.autoReadSpeed, value)
field = value field = value
App.INSTANCE.putPrefInt(PreferKey.autoReadSpeed, value)
} }
var styleSelect = App.INSTANCE.getPrefInt(PreferKey.readStyleSelect) var styleSelect = App.INSTANCE.getPrefInt(PreferKey.readStyleSelect)
set(value) { set(value) {

@ -126,6 +126,7 @@ object Restore {
hideStatusBar = App.INSTANCE.getPrefBoolean(PreferKey.hideStatusBar) hideStatusBar = App.INSTANCE.getPrefBoolean(PreferKey.hideStatusBar)
hideNavigationBar = App.INSTANCE.getPrefBoolean(PreferKey.hideNavigationBar) hideNavigationBar = App.INSTANCE.getPrefBoolean(PreferKey.hideNavigationBar)
bodyIndentCount = App.INSTANCE.getPrefInt(PreferKey.bodyIndent, 2) bodyIndentCount = App.INSTANCE.getPrefInt(PreferKey.bodyIndent, 2)
autoReadSpeed = App.INSTANCE.getPrefInt(PreferKey.autoReadSpeed, 46)
} }
ChapterProvider.upStyle() ChapterProvider.upStyle()
ReadBook.loadContent(resetPageOffset = false) ReadBook.loadContent(resetPageOffset = false)

Loading…
Cancel
Save