diff options
| -rw-r--r-- | packages/SystemUI/src/com/android/keyguard/KeyguardPasswordView.java | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/packages/SystemUI/src/com/android/keyguard/KeyguardPasswordView.java b/packages/SystemUI/src/com/android/keyguard/KeyguardPasswordView.java index 92b65b242b0e..533bec14f60a 100644 --- a/packages/SystemUI/src/com/android/keyguard/KeyguardPasswordView.java +++ b/packages/SystemUI/src/com/android/keyguard/KeyguardPasswordView.java @@ -136,14 +136,23 @@ public class KeyguardPasswordView extends KeyguardAbsKeyInputView { @Override public void startAppearAnimation() { - // Reset state, and let IME animation reveal the view as it slides in + // Reset state, and let IME animation reveal the view as it slides in, if one exists. + // It is possible for an IME to have no view, so provide a default animation since no + // calls to animateForIme would occur setAlpha(0f); + animate() + .alpha(1f) + .setDuration(500) + .setStartDelay(300) + .start(); + setTranslationY(0f); } @Override public void animateForIme(float interpolatedFraction) { - setAlpha(interpolatedFraction); + animate().cancel(); + setAlpha(Math.max(interpolatedFraction, getAlpha())); } @Override |