Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 50f96222 authored by Johannes Gallmann's avatar Johannes Gallmann
Browse files

Fix flicker in cross-activity-back-animation

Bug: 347861186
Flag: com.android.window.flags.predictive_back_system_anims
Test: Manual, i.e. verifying that flicker is not reproducible with the CL applied
Change-Id: I5464afbffab182e96acae104cf0471bbaf0a056b
parent e84fdcef
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -324,6 +324,7 @@ abstract class CrossActivityBackAnimation(
        enteringHasSameLetterbox = false
        lastPostCommitFlingScale = SPRING_SCALE
        gestureProgress = 0f
        triggerBack = false
    }

    protected fun applyTransform(
@@ -499,10 +500,12 @@ abstract class CrossActivityBackAnimation(
        }

        override fun onBackCancelled() {
            triggerBack = false
            progressAnimator.onBackCancelled { finishAnimation() }
        }

        override fun onBackInvoked() {
            triggerBack = true
            progressAnimator.reset()
            onGestureCommitted(progressAnimator.velocity)
        }