Remove app labels in isVerticalBar
Bug: 296400197 Test: ResponsiveHomeScreenImageTest Test: ResponsiveAllAppsImageTest Test: DeviceProfileResponsiveDumpTest Flag: ENABLE_RESPONSIVE_WORKSPACE Change-Id: Ia508c1b909df3fff5768b39e90275bf914b6f1c4
This commit is contained in:
@@ -925,14 +925,11 @@ public class DeviceProfile {
|
||||
- iconTextHeight;
|
||||
|
||||
if (mIsResponsiveGrid) {
|
||||
// Hide text only if doesn't fit inside the cell for responsive grid
|
||||
if (workspaceCellPaddingY < 0) {
|
||||
iconTextSizePx = 0;
|
||||
iconDrawablePaddingPx = 0;
|
||||
int iconSizeWithOverlap = getIconSizeWithOverlap(iconSizePx);
|
||||
cellYPaddingPx = Math.max(0, getCellSize().y - iconSizeWithOverlap) / 2;
|
||||
autoResizeAllAppsCells();
|
||||
}
|
||||
iconTextSizePx = 0;
|
||||
iconDrawablePaddingPx = 0;
|
||||
int iconSizeWithOverlap = getIconSizeWithOverlap(iconSizePx);
|
||||
cellYPaddingPx = Math.max(0, getCellSize().y - iconSizeWithOverlap) / 2;
|
||||
autoResizeAllAppsCells();
|
||||
|
||||
return;
|
||||
}
|
||||
@@ -1048,15 +1045,16 @@ public class DeviceProfile {
|
||||
iconSizePx = mIconSizeSteps.getIconSmallerThan(cellWidthPx);
|
||||
}
|
||||
|
||||
// TODO(b/296400197): isVerticalBar shouldn't show labels anymore
|
||||
iconDrawablePaddingPx = getNormalizedIconDrawablePadding();
|
||||
|
||||
CellContentDimensions cellContentDimensions = new CellContentDimensions(iconSizePx,
|
||||
iconDrawablePaddingPx,
|
||||
iconTextSizePx);
|
||||
if (isVerticalLayout && cellHeightPx < iconSizePx) {
|
||||
cellContentDimensions.setIconSizePx(
|
||||
mIconSizeSteps.getIconSmallerThan(cellHeightPx));
|
||||
if (isVerticalLayout) {
|
||||
if (cellHeightPx < iconSizePx) {
|
||||
cellContentDimensions.setIconSizePx(
|
||||
mIconSizeSteps.getIconSmallerThan(cellHeightPx));
|
||||
}
|
||||
} else {
|
||||
cellContentDimensions.resizeToFitCellHeight(cellHeightPx, mIconSizeSteps);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user