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

Commit 27735763 authored by Johannes Gallmann's avatar Johannes Gallmann Committed by Android (Google) Code Review
Browse files

Merge "Fix double back swipe not working" into main

parents de96f53f 6cea7dc1
Loading
Loading
Loading
Loading
+1 −4
Original line number Diff line number Diff line
@@ -354,7 +354,7 @@ abstract class CrossActivityBackAnimation(
        matrix.postScale(scale, scale, scalePivotX, 0f)
        matrix.postTranslate(tempRectF.left, tempRectF.top)
        transaction
            .setAlpha(leash, keepMinimumAlpha(alpha))
            .setAlpha(leash, alpha)
            .setMatrix(leash, matrix, tmpFloat9)
            .setCrop(leash, cropRect)
            .setCornerRadius(leash, cornerRadius)
@@ -562,9 +562,6 @@ abstract class CrossActivityBackAnimation(
    }
}

// The target will loose focus when alpha == 0, so keep a minimum value for it.
private fun keepMinimumAlpha(transAlpha: Float) = max(transAlpha, 0.005f)

private fun isDarkMode(context: Context): Boolean {
    return context.resources.configuration.uiMode and Configuration.UI_MODE_NIGHT_MASK ==
        Configuration.UI_MODE_NIGHT_YES