diff --git a/packages/SystemUI/src/com/android/systemui/keyguard/KeyguardViewMediator.java b/packages/SystemUI/src/com/android/systemui/keyguard/KeyguardViewMediator.java index 38b98eb45aec2..6f84903af7458 100644 --- a/packages/SystemUI/src/com/android/systemui/keyguard/KeyguardViewMediator.java +++ b/packages/SystemUI/src/com/android/systemui/keyguard/KeyguardViewMediator.java @@ -987,9 +987,11 @@ public class KeyguardViewMediator extends CoreStartable implements Dumpable, @Override public void onAnimationCancelled(boolean isKeyguardOccluded) { - if (mUnoccludeAnimator != null) { - mUnoccludeAnimator.cancel(); - } + mContext.getMainExecutor().execute(() -> { + if (mUnoccludeAnimator != null) { + mUnoccludeAnimator.cancel(); + } + }); setOccluded(isKeyguardOccluded /* isOccluded */, false /* animate */); Log.d(TAG, "Unocclude animation cancelled. Occluded state is now: "