@ -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()
@ -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)