From f92663f5fe315bfe0ca2b28227e888e01cff7d9f Mon Sep 17 00:00:00 2001 From: gedoor Date: Sun, 22 Aug 2021 12:30:42 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8Dbug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../legado/app/ui/book/read/ReadBookActivity.kt | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/app/src/main/java/io/legado/app/ui/book/read/ReadBookActivity.kt b/app/src/main/java/io/legado/app/ui/book/read/ReadBookActivity.kt index 9591f1ae2..4f43bdb37 100644 --- a/app/src/main/java/io/legado/app/ui/book/read/ReadBookActivity.kt +++ b/app/src/main/java/io/legado/app/ui/book/read/ReadBookActivity.kt @@ -683,8 +683,8 @@ class ReadBookActivity : ReadBookBaseActivity(), autoPageStop() } else { isAutoPage = true - binding.readView.upContent() - binding.readView.upContent(1) + binding.readView.upContent(resetPageOffset = false) + binding.readView.upContent(1, resetPageOffset = false) autoPagePlus() binding.readMenu.setAutoPage(true) screenTimeOut = -1L @@ -693,11 +693,13 @@ class ReadBookActivity : ReadBookBaseActivity(), } override fun autoPageStop() { - isAutoPage = false - mHandler.removeCallbacks(autoPageRunnable) - binding.readView.upContent() - binding.readMenu.setAutoPage(false) - upScreenTimeOut() + if (isAutoPage) { + isAutoPage = false + mHandler.removeCallbacks(autoPageRunnable) + binding.readView.upContent(resetPageOffset = false) + binding.readMenu.setAutoPage(false) + upScreenTimeOut() + } } private fun autoPagePlus() {