Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 73886f37 authored by Jonathan Miranda's avatar Jonathan Miranda Committed by Automerger Merge Worker
Browse files

Merge "Only inset widgets if workspaceTopPadding is greater than the widget...

Merge "Only inset widgets if workspaceTopPadding is greater than the widget padding." into sc-dev am: 3ed65ede

Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/14823934

Change-Id: Ica0d5b9d65dcaa32aae7978ffa36e3a63c172ce1
parents f647016c 3ed65ede
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -399,8 +399,10 @@ public class DeviceProfile {
    public boolean shouldInsetWidgets() {
        Rect widgetPadding = inv.defaultWidgetPadding;

        // Check all sides to ensure that the widget won't overlap into another cell.
        return cellLayoutBorderSpacingPx > widgetPadding.left
        // Check all sides to ensure that the widget won't overlap into another cell, or into
        // status bar.
        return workspaceTopPadding > widgetPadding.top
                && cellLayoutBorderSpacingPx > widgetPadding.left
                && cellLayoutBorderSpacingPx > widgetPadding.top
                && cellLayoutBorderSpacingPx > widgetPadding.right
                && cellLayoutBorderSpacingPx > widgetPadding.bottom;