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

Commit 10e98eeb authored by Johannes Gallmann's avatar Johannes Gallmann
Browse files

Bring cross-activity back animation spec closer to forward animation

Bug: 343136429
Flag: com.android.window.flags.predictive_back_system_anims NEXTFOOD
Test: Manual, i.e. testing forward and backward animations on device
Change-Id: I677c17d19f82ba4be98139b4e29cd76b6788d211
parent 9a372e7c
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -43,7 +43,7 @@ constructor(
        Choreographer.getInstance()
    ) {

    private val postCommitInterpolator = Interpolators.FAST_OUT_SLOW_IN
    private val postCommitInterpolator = Interpolators.EMPHASIZED
    private val enteringStartOffset =
        context.resources.getDimension(R.dimen.cross_activity_back_entering_start_offset)
    override val allowEnteringYShift = true
@@ -87,7 +87,7 @@ constructor(

    override fun onPostCommitProgress(linearProgress: Float) {
        super.onPostCommitProgress(linearProgress)
        val closingAlpha = max(1f - linearProgress * 2, 0f)
        val closingAlpha = max(1f - linearProgress * 5, 0f)
        val progress = postCommitInterpolator.getInterpolation(linearProgress)
        currentClosingRect.setInterpolatedRectF(startClosingRect, targetClosingRect, progress)
        applyTransform(closingTarget?.leash, currentClosingRect, closingAlpha)
@@ -98,6 +98,6 @@ constructor(


    companion object {
        private const val POST_COMMIT_DURATION = 300L
        private const val POST_COMMIT_DURATION = 450L
    }
}