Skip to content

Commit

Permalink
Fixed listener trigger in wrong time
Browse files Browse the repository at this point in the history
  • Loading branch information
hearsilent committed Jul 12, 2019
1 parent 9c69a47 commit 7e0768b
Showing 1 changed file with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -650,11 +650,10 @@ private boolean handleTouchEvent(MotionEvent event) {
mMoveDetector.onTouchEvent(event);
return true;
}
if (mPaddingPosition != mMinProgress && mPaddingPosition != mMaxProgress &&
!mSkipMove) {
if (mPaddingPosition != mMinProgress && mPaddingPosition != mMaxProgress) {
float p = mOrientation == HORIZONTAL ? event.getX() : event.getY();
final int position = (int) getClosestPosition(p, length)[0];
if (position == mPaddingPosition) {
if (position == mPaddingPosition && !mSkipMove) {
if (mMaxProgress == -1 && mMode == MODE_NORMAL) {
mPaddingPosition = mMinProgress;
} else {
Expand Down

0 comments on commit 7e0768b

Please sign in to comment.