From 1bcb9d94ce036f85a6e6657fb8b51c400ec5a531 Mon Sep 17 00:00:00 2001 From: wilsonshih Date: Tue, 18 May 2021 17:04:01 +0800 Subject: [PATCH] Read the starting surface icon size from framework Bug: 177264697 Test: Manual verify icon size on splash screen. Change-Id: Iec6b0c519cf4692ac6851911ed1e21a3c1b752b4 --- .../com/android/launcher3/QuickstepTransitionManager.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/quickstep/src/com/android/launcher3/QuickstepTransitionManager.java b/quickstep/src/com/android/launcher3/QuickstepTransitionManager.java index 80754a00f4..0ac0223d91 100644 --- a/quickstep/src/com/android/launcher3/QuickstepTransitionManager.java +++ b/quickstep/src/com/android/launcher3/QuickstepTransitionManager.java @@ -1340,14 +1340,14 @@ public class QuickstepTransitionManager implements OnDeviceProfileChangeListener iconAlphaStart = hasSplashScreen ? 0 : 1f; - // TOOD: Share value from shell when available. - final float windowIconSize = Utilities.pxFromSp(108, r.getDisplayMetrics()); + final int windowIconSize = ResourceUtils.getDimenByName("starting_surface_icon_size", + r, 108); cropCenterXStart = windowTargetBounds.centerX(); cropCenterYStart = windowTargetBounds.centerY(); - cropWidthStart = (int) windowIconSize; - cropHeightStart = (int) windowIconSize; + cropWidthStart = windowIconSize; + cropHeightStart = windowIconSize; cropWidthEnd = windowTargetBounds.width(); cropHeightEnd = windowTargetBounds.height();