PIN view - Fix multiple ripples
Only apply animation on DOWN motion Fixes: 180994829 Test: manual Change-Id: Ifdb6e6319e063d577aecdf84dcb7197bd5c725d3
This commit is contained in:
@@ -69,7 +69,9 @@ public class NumPadButton extends AlphaOptimizedImageButton {
|
||||
|
||||
@Override
|
||||
public boolean onTouchEvent(MotionEvent event) {
|
||||
if (mAnimator != null) mAnimator.start();
|
||||
if (event.getActionMasked() == MotionEvent.ACTION_DOWN) {
|
||||
if (mAnimator != null) mAnimator.start();
|
||||
}
|
||||
return super.onTouchEvent(event);
|
||||
}
|
||||
|
||||
|
||||
@@ -160,10 +160,9 @@ public class NumPadKey extends ViewGroup {
|
||||
public boolean onTouchEvent(MotionEvent event) {
|
||||
if (event.getActionMasked() == MotionEvent.ACTION_DOWN) {
|
||||
doHapticKeyClick();
|
||||
if (mAnimator != null) mAnimator.start();
|
||||
}
|
||||
|
||||
if (mAnimator != null) mAnimator.start();
|
||||
|
||||
return super.onTouchEvent(event);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user