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

Commit 264e4e42 authored by Nicolo' Mazzucato's avatar Nicolo' Mazzucato
Browse files

Fix rounded corner padding for external displays

Use a small hardcoded padding for the rounded corner content padding on external displays, instead of 0.

This provides a better default for external displays that don't have rounded corners, preventing UI elements from being attached to the edge

Bug: 439598525
Test: Show statusbar on external display, verify the left part is not attached to the beginning
Flag: EXEMPT minor visual fix
Change-Id: I0d56814ec422e5a3fcf04b366d6c022c1946c885
parent 3922d5a4
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -465,6 +465,11 @@
    <!-- the padding on the top of the statusbar (usually 0) -->
    <dimen name="status_bar_padding_top">0dp</dimen>

    <!-- The padding used in case there are no rounded corners. -->
    <dimen name="status_bar_padding_without_rounded_corners">
        @dimen/ongoing_appops_dot_min_padding
    </dimen>

    <!-- the radius of the overflow dot in the status bar -->
    <dimen name="overflow_dot_radius">2sp</dimen>

+4 −2
Original line number Diff line number Diff line
@@ -340,8 +340,10 @@ constructor(
                // Display#getRoundedCorner) and a padding value. The proper way of doing this is
                // using safe insets, that take this into account already.
                // For now, as external displays with corner radius are extremely uncommon, we're
                // just returning zero.
                0
                // just returning an hardcoded small padding.
                rotatedResources.getDimensionPixelSize(
                    R.dimen.status_bar_padding_without_rounded_corners
                )
            }
        val minDotPadding =
            if (isPrivacyDotEnabled)