From f53f3ec2a6ab74296479a63ced3e773c8b348bc2 Mon Sep 17 00:00:00 2001 From: Steven Terrell Date: Wed, 15 Mar 2023 20:19:47 +0000 Subject: [PATCH] Adjust BackgroundPauseDelay for Animations Changing the BackgroundPauseDelay from 10 seconds to 1 second. When an apps visible service is moved to the background infinite animators will now be paused after 1 second. Bug: 273577693 Test: Atest CtsGraphicsTestCases:AnimatorLeakTest Change-Id: I0bb460dbc9651d74759d1f826738b063716c0845 --- core/java/android/animation/Animator.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/java/android/animation/Animator.java b/core/java/android/animation/Animator.java index a81ef18c8022d..d0ce701334146 100644 --- a/core/java/android/animation/Animator.java +++ b/core/java/android/animation/Animator.java @@ -69,7 +69,7 @@ public abstract class Animator implements Cloneable { * backing field for backgroundPauseDelay property. This could be simply a hardcoded * value in AnimationHandler, but it is useful to be able to change the value in tests. */ - private static long sBackgroundPauseDelay = 10000; + private static long sBackgroundPauseDelay = 1000; /** * Sets the duration for delaying pausing animators when apps go into the background.