pull/1259/head
gedoor 3 years ago
parent 39771cf474
commit f92663f5fe
  1. 8
      app/src/main/java/io/legado/app/ui/book/read/ReadBookActivity.kt

@ -683,8 +683,8 @@ class ReadBookActivity : ReadBookBaseActivity(),
autoPageStop() autoPageStop()
} else { } else {
isAutoPage = true isAutoPage = true
binding.readView.upContent() binding.readView.upContent(resetPageOffset = false)
binding.readView.upContent(1) binding.readView.upContent(1, resetPageOffset = false)
autoPagePlus() autoPagePlus()
binding.readMenu.setAutoPage(true) binding.readMenu.setAutoPage(true)
screenTimeOut = -1L screenTimeOut = -1L
@ -693,12 +693,14 @@ class ReadBookActivity : ReadBookBaseActivity(),
} }
override fun autoPageStop() { override fun autoPageStop() {
if (isAutoPage) {
isAutoPage = false isAutoPage = false
mHandler.removeCallbacks(autoPageRunnable) mHandler.removeCallbacks(autoPageRunnable)
binding.readView.upContent() binding.readView.upContent(resetPageOffset = false)
binding.readMenu.setAutoPage(false) binding.readMenu.setAutoPage(false)
upScreenTimeOut() upScreenTimeOut()
} }
}
private fun autoPagePlus() { private fun autoPagePlus() {
var delayMillis = ReadBookConfig.autoReadSpeed * 1000L / binding.readView.height var delayMillis = ReadBookConfig.autoReadSpeed * 1000L / binding.readView.height

Loading…
Cancel
Save