From 5b1ac7703ebb9cf12d7d24dac6252530bb812626 Mon Sep 17 00:00:00 2001 From: gedoor Date: Mon, 14 Dec 2020 17:51:46 +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 --- app/src/main/java/io/legado/app/ui/book/read/page/ReadView.kt | 1 + .../io/legado/app/ui/book/read/page/delegate/PageDelegate.kt | 1 + 2 files changed, 2 insertions(+) diff --git a/app/src/main/java/io/legado/app/ui/book/read/page/ReadView.kt b/app/src/main/java/io/legado/app/ui/book/read/page/ReadView.kt index 716a0bd88..409b57129 100644 --- a/app/src/main/java/io/legado/app/ui/book/read/page/ReadView.kt +++ b/app/src/main/java/io/legado/app/ui/book/read/page/ReadView.kt @@ -547,5 +547,6 @@ class ReadView(context: Context, attrs: AttributeSet) : fun showActionMenu() fun screenOffTimerStart() fun showTextActionMenu() + fun autoPageStop() } } diff --git a/app/src/main/java/io/legado/app/ui/book/read/page/delegate/PageDelegate.kt b/app/src/main/java/io/legado/app/ui/book/read/page/delegate/PageDelegate.kt index 2f1d70c8d..a70961487 100644 --- a/app/src/main/java/io/legado/app/ui/book/read/page/delegate/PageDelegate.kt +++ b/app/src/main/java/io/legado/app/ui/book/read/page/delegate/PageDelegate.kt @@ -173,6 +173,7 @@ abstract class PageDelegate(protected val readView: ReadView) { fun hasNext(): Boolean { val hasNext = readView.pageFactory.hasNext() if (!hasNext) { + readView.callBack.autoPageStop() if (!snackBar.isShown) { snackBar.setText(R.string.no_next_page) snackBar.show()