feat: 优化代码

pull/123/head
kunfei 5 years ago
parent 3bf94f8cc0
commit cacbf2f8a4
  1. 5
      app/src/main/java/io/legado/app/ui/book/read/page/delegate/ScrollPageDelegate.kt

@ -2,6 +2,7 @@ package io.legado.app.ui.book.read.page.delegate
import android.view.MotionEvent import android.view.MotionEvent
import android.view.VelocityTracker import android.view.VelocityTracker
import io.legado.app.ui.book.read.page.ChapterProvider
import io.legado.app.ui.book.read.page.PageView import io.legado.app.ui.book.read.page.PageView
import kotlin.math.abs import kotlin.math.abs
@ -60,10 +61,10 @@ class ScrollPageDelegate(pageView: PageView) : PageDelegate(pageView) {
} }
override fun nextPageByAnim() { override fun nextPageByAnim() {
startScroll(0, 0, 0, -ChapterProvider.visibleHeight)
} }
override fun prevPageByAnim() { override fun prevPageByAnim() {
startScroll(0, 0, 0, ChapterProvider.visibleHeight)
} }
} }
Loading…
Cancel
Save