From e73fc4b123e96575e8c6d5997a055cc900298fa9 Mon Sep 17 00:00:00 2001 From: Beverly Date: Fri, 7 Apr 2023 19:38:18 +0000 Subject: [PATCH] Support FP => lock icon animation To support fingerprint becoming locked out Test: manully lock out class 3 face which will lock out fingerprint, see animation Fixes: 277361687 Change-Id: I83b90a56cd54f7f24acebc45b60e4a607e8da50a --- .../res-keyguard/drawable/fp_to_locked.xml | 165 ++++++++++++++++++ .../res-keyguard/drawable/super_lock_icon.xml | 5 + .../keyguard/LockIconViewController.java | 5 + 3 files changed, 175 insertions(+) create mode 100644 packages/SystemUI/res-keyguard/drawable/fp_to_locked.xml diff --git a/packages/SystemUI/res-keyguard/drawable/fp_to_locked.xml b/packages/SystemUI/res-keyguard/drawable/fp_to_locked.xml new file mode 100644 index 0000000000000..61a1cb5f1d314 --- /dev/null +++ b/packages/SystemUI/res-keyguard/drawable/fp_to_locked.xml @@ -0,0 +1,165 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/packages/SystemUI/res-keyguard/drawable/super_lock_icon.xml b/packages/SystemUI/res-keyguard/drawable/super_lock_icon.xml index 951d6fed0a17c..f3325ecefada0 100644 --- a/packages/SystemUI/res-keyguard/drawable/super_lock_icon.xml +++ b/packages/SystemUI/res-keyguard/drawable/super_lock_icon.xml @@ -104,4 +104,9 @@ android:fromId="@id/unlocked" android:toId="@id/locked" android:drawable="@drawable/unlocked_to_locked" /> + + diff --git a/packages/SystemUI/src/com/android/keyguard/LockIconViewController.java b/packages/SystemUI/src/com/android/keyguard/LockIconViewController.java index 235a8bca6d1e6..5f2afe8f755d9 100644 --- a/packages/SystemUI/src/com/android/keyguard/LockIconViewController.java +++ b/packages/SystemUI/src/com/android/keyguard/LockIconViewController.java @@ -294,6 +294,11 @@ public class LockIconViewController extends ViewController impleme final CharSequence prevContentDescription = mView.getContentDescription(); if (mShowLockIcon) { + if (wasShowingFpIcon) { + // fp icon was shown by UdfpsView, and now we still want to animate the transition + // in this drawable + mView.updateIcon(ICON_FINGERPRINT, false); + } mView.updateIcon(ICON_LOCK, false); mView.setContentDescription(mLockedLabel); mView.setVisibility(View.VISIBLE);