From 465ed89e3ff4e7953c3cf321bb2189c0be97a4a8 Mon Sep 17 00:00:00 2001 From: "Jian-Syuan (Shane) Wong" Date: Mon, 24 Jul 2023 16:51:02 +0000 Subject: [PATCH] Revert "Handle when AnimationUtils getExpectedPresentationTimeNa..." Revert submission 24081677-update-ept Reason for revert: Revert the CLs due to the CTS breakage (b/292022847) Reverted changes: /q/submissionid:24081677-update-ept Change-Id: I0bfd1d25f2a36692c22f8301838edc7e354b4c05 --- core/java/android/view/animation/AnimationUtils.java | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/core/java/android/view/animation/AnimationUtils.java b/core/java/android/view/animation/AnimationUtils.java index 0699bc1cb734b..8ba8b8cca5edf 100644 --- a/core/java/android/view/animation/AnimationUtils.java +++ b/core/java/android/view/animation/AnimationUtils.java @@ -32,7 +32,6 @@ import android.os.SystemClock; import android.util.AttributeSet; import android.util.TimeUtils; import android.util.Xml; -import android.view.Choreographer; import android.view.InflateException; import org.xmlpull.v1.XmlPullParser; @@ -154,13 +153,7 @@ public class AnimationUtils { */ public static long getExpectedPresentationTimeNanos() { AnimationState state = sAnimationState.get(); - if (state.animationClockLocked) { - return state.mExpectedPresentationTimeNanos; - } - // When this methoed is called outside of a Choreographer callback, - // we obtain the value of expectedPresentTimeNanos from the Choreographer. - // This helps avoid returning a time that could potentially be earlier than current time. - return Choreographer.getInstance().getLatestExpectedPresentTimeNanos(); + return state.mExpectedPresentationTimeNanos; } /**