Merge "Use getExactRotation for UPSIDE_DOWN rotation" into tm-dev

This commit is contained in:
TreeHugger Robot
2022-02-24 18:18:22 +00:00
committed by Android (Google) Code Review

View File

@@ -175,7 +175,7 @@ class WiredChargingRippleController @Inject constructor(
val width = displayMetrics.widthPixels
val height = displayMetrics.heightPixels
rippleView.radius = Integer.max(width, height).toFloat()
rippleView.origin = when (RotationUtils.getRotation(context)) {
rippleView.origin = when (RotationUtils.getExactRotation(context)) {
RotationUtils.ROTATION_LANDSCAPE -> {
PointF(width * normalizedPortPosY, height * (1 - normalizedPortPosX))
}