diff options
Diffstat (limited to 'packages/SystemUI/src/com/android/keyguard/KeyguardInputView.java')
-rw-r--r-- | packages/SystemUI/src/com/android/keyguard/KeyguardInputView.java | 39 |
1 files changed, 12 insertions, 27 deletions
diff --git a/packages/SystemUI/src/com/android/keyguard/KeyguardInputView.java b/packages/SystemUI/src/com/android/keyguard/KeyguardInputView.java index 5e02e0440c3d..40190c18935b 100644 --- a/packages/SystemUI/src/com/android/keyguard/KeyguardInputView.java +++ b/packages/SystemUI/src/com/android/keyguard/KeyguardInputView.java @@ -26,16 +26,12 @@ import android.widget.LinearLayout; import androidx.annotation.Nullable; import com.android.internal.jank.InteractionJankMonitor; -import com.android.systemui.Gefingerpoken; - -import java.util.ArrayList; -import java.util.List; /** * A Base class for all Keyguard password/pattern/pin related inputs. */ public abstract class KeyguardInputView extends LinearLayout { - private final List<Gefingerpoken> mMotionEventListener = new ArrayList<>(); + private Runnable mOnFinishImeAnimationRunnable; public KeyguardInputView(Context context) { super(context); @@ -52,7 +48,7 @@ public abstract class KeyguardInputView extends LinearLayout { abstract CharSequence getTitle(); - void animateForIme(float interpolatedFraction) { + void animateForIme(float interpolatedFraction, boolean appearingAnim) { return; } @@ -66,27 +62,6 @@ public abstract class KeyguardInputView extends LinearLayout { return false; } - void addMotionEventListener(Gefingerpoken listener) { - mMotionEventListener.add(listener); - } - - void removeMotionEventListener(Gefingerpoken listener) { - mMotionEventListener.remove(listener); - } - - @Override - public boolean onTouchEvent(MotionEvent event) { - return mMotionEventListener.stream().anyMatch(listener -> listener.onTouchEvent(event)) - || super.onTouchEvent(event); - } - - @Override - public boolean onInterceptTouchEvent(MotionEvent event) { - return mMotionEventListener.stream().anyMatch( - listener -> listener.onInterceptTouchEvent(event)) - || super.onInterceptTouchEvent(event); - } - protected AnimatorListenerAdapter getAnimationListener(int cuj) { return new AnimatorListenerAdapter() { private boolean mIsCancel; @@ -112,4 +87,14 @@ public abstract class KeyguardInputView extends LinearLayout { }; } + public void setOnFinishImeAnimationRunnable(Runnable onFinishImeAnimationRunnable) { + mOnFinishImeAnimationRunnable = onFinishImeAnimationRunnable; + } + + public void runOnFinishImeAnimationRunnable() { + if (mOnFinishImeAnimationRunnable != null) { + mOnFinishImeAnimationRunnable.run(); + mOnFinishImeAnimationRunnable = null; + } + } } |