diff --git a/app/src/main/java/io/legado/app/ui/widget/page/curl/CurlView.kt b/app/src/main/java/io/legado/app/ui/widget/page/curl/CurlView.kt index f7dfd14f7..96f15eac9 100644 --- a/app/src/main/java/io/legado/app/ui/widget/page/curl/CurlView.kt +++ b/app/src/main/java/io/legado/app/ui/widget/page/curl/CurlView.kt @@ -82,10 +82,7 @@ class CurlView : GLSurfaceView, View.OnTouchListener, CurlRenderer.Observer { if (mAllowLastPageCurl) { min(index, mPageProvider!!.pageCount) } else { - min( - index, - mPageProvider!!.pageCount - 1 - ) + min(index, mPageProvider!!.pageCount - 1) } } updatePages() diff --git a/app/src/main/java/io/legado/app/ui/widget/page/delegate/SimulationPageDelegate.kt b/app/src/main/java/io/legado/app/ui/widget/page/delegate/SimulationPageDelegate.kt index 186fc8c97..4b96fb6cd 100644 --- a/app/src/main/java/io/legado/app/ui/widget/page/delegate/SimulationPageDelegate.kt +++ b/app/src/main/java/io/legado/app/ui/widget/page/delegate/SimulationPageDelegate.kt @@ -39,8 +39,7 @@ class SimulationPageDelegate(pageView: PageView) : PageDelegate(pageView) { get() = 1 override fun updatePage(page: CurlPage, width: Int, height: Int, index: Int) { - val front = curPage?.screenshot() - page.setTexture(front, CurlPage.SIDE_BOTH) + page.setTexture(curPage?.screenshot(), CurlPage.SIDE_BOTH) } }