pull/37/head
kunfei 5 years ago
parent 483bf92003
commit ac18cdcad7
  1. 8
      app/src/main/java/io/legado/app/ui/widget/page/delegate/SimulationPageDelegate.kt

@ -40,10 +40,14 @@ class SimulationPageDelegate(pageView: PageView) : PageDelegate(pageView) {
private inner class PageProvider : CurlView.PageProvider { private inner class PageProvider : CurlView.PageProvider {
override val pageCount: Int override val pageCount: Int
get() = 1 get() = 3
override fun updatePage(page: CurlPage, width: Int, height: Int, index: Int) { override fun updatePage(page: CurlPage, width: Int, height: Int, index: Int) {
page.setTexture(curPage?.screenshot(), CurlPage.SIDE_BOTH) when (index) {
0 -> page.setTexture(prevPage?.screenshot(), CurlPage.SIDE_BOTH)
1 -> page.setTexture(curPage?.screenshot(), CurlPage.SIDE_BOTH)
2 -> page.setTexture(nextPage?.screenshot(), CurlPage.SIDE_BOTH)
}
} }
} }

Loading…
Cancel
Save