Fix text sizes and alignment in drop target

Drop target button texts are being resized incorrectly.
When both buttons are visible, the text is considerably smaller compared
to only one visible button. This happens even for the default display and font scale 1.

Fix: 271279172
Test: manual. test all combinations of display size and font size.
Test: HomeScreenEditStateImageTest
Change-Id: Ib001dcf8b096c65b138946bdad49cf8199fb5b1d
This commit is contained in:
Jordan Silva committed 2023-05-02 14:57:49 +02:00
1 parent 5e43031ed0
commit 567372fbda
3 files changed
+7 -10

No files matched your search

@@ -152,6 +152,7 @@ public class DropTargetBar extends FrameLayout
firstButton.setTextVisible(true);
firstButton.setIconVisible(true);
firstButton.measure(widthSpec, heightSpec);
firstButton.resizeTextToFit();
} else if (visibleCount == 2) {
DeviceProfile dp = mLauncher.getDeviceProfile();
int verticalPadding = dp.dropTargetVerticalPaddingPx;