Merge remote-tracking branch 'aosp/android12L-release' into 12.1-dev
This commit is contained in:
@@ -24,7 +24,6 @@ import static com.android.launcher3.BubbleTextView.TEXT_ALPHA_PROPERTY;
|
||||
import static com.android.launcher3.LauncherAnimUtils.SCALE_PROPERTY;
|
||||
import static com.android.launcher3.folder.ClippedFolderIconLayoutRule.MAX_NUM_ITEMS_IN_PREVIEW;
|
||||
import static com.android.launcher3.graphics.IconShape.getShape;
|
||||
import static com.android.launcher3.icons.GraphicsUtils.setColorAlphaBound;
|
||||
|
||||
import android.animation.Animator;
|
||||
import android.animation.AnimatorListenerAdapter;
|
||||
@@ -179,15 +178,10 @@ public class FolderAnimationManager {
|
||||
final float yDistance = initialY - lp.y;
|
||||
|
||||
// Set up the Folder background.
|
||||
final int finalColor;
|
||||
int folderFillColor = ColorTokens.FolderFillColor.resolveColor(mContext);
|
||||
if (mIsOpening) {
|
||||
finalColor = folderFillColor;
|
||||
} else {
|
||||
finalColor = mFolderBackground.getColor().getDefaultColor();
|
||||
}
|
||||
final int initialColor = setColorAlphaBound(
|
||||
folderFillColor, mPreviewBackground.getBackgroundAlpha());
|
||||
// TODO: apply colortokens
|
||||
final int initialColor = Themes.getAttrColor(mContext, R.attr.folderPreviewColor);
|
||||
final int finalColor = Themes.getAttrColor(mContext, R.attr.folderBackgroundColor);
|
||||
|
||||
mFolderBackground.mutate();
|
||||
mFolderBackground.setColor(mIsOpening ? initialColor : finalColor);
|
||||
|
||||
@@ -243,9 +237,9 @@ public class FolderAnimationManager {
|
||||
mFolder, startRect, endRect, finalRadius, !mIsOpening));
|
||||
|
||||
// Create reveal animator for the folder content (capture the top 4 icons 2x2)
|
||||
int width = mDeviceProfile.folderCellLayoutBorderSpacingPx
|
||||
int width = mDeviceProfile.folderCellLayoutBorderSpacePx.x
|
||||
+ mDeviceProfile.folderCellWidthPx * 2;
|
||||
int height = mDeviceProfile.folderCellLayoutBorderSpacingPx
|
||||
int height = mDeviceProfile.folderCellLayoutBorderSpacePx.y
|
||||
+ mDeviceProfile.folderCellHeightPx * 2;
|
||||
int page = mIsOpening ? mContent.getCurrentPage() : mContent.getDestinationPage();
|
||||
int left = mContent.getPaddingLeft() + page * lp.width;
|
||||
|
||||
Reference in New Issue
Block a user