优化翻页

pull/357/head
gedoor 4 years ago
parent aa507d214a
commit b1f5f15eae
  1. 2
      app/src/main/java/io/legado/app/ui/book/read/page/PageView.kt
  2. 1
      app/src/main/java/io/legado/app/ui/book/read/page/delegate/ScrollPageDelegate.kt

@ -137,8 +137,8 @@ class PageView(context: Context, attrs: AttributeSet) :
postDelayed(longPressRunnable, longPressTimeout) postDelayed(longPressRunnable, longPressTimeout)
pressDown = true pressDown = true
isMove = false isMove = false
setStartPoint(event.x, event.y)
pageDelegate?.onTouch(event) pageDelegate?.onTouch(event)
setStartPoint(event.x, event.y)
} }
MotionEvent.ACTION_MOVE -> { MotionEvent.ACTION_MOVE -> {
pressDown = true pressDown = true

@ -29,7 +29,6 @@ class ScrollPageDelegate(pageView: PageView) : PageDelegate(pageView) {
when (event.action) { when (event.action) {
MotionEvent.ACTION_DOWN -> { MotionEvent.ACTION_DOWN -> {
abortAnim() abortAnim()
pageView.setStartPoint(event.x, event.y)
mVelocity.clear() mVelocity.clear()
} }
MotionEvent.ACTION_MOVE -> { MotionEvent.ACTION_MOVE -> {

Loading…
Cancel
Save