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

Commit 9fa112fb authored by Evan Laird's avatar Evan Laird
Browse files

[Statusbar] Hide operator name by default; fix paddings

There are three main fixes here, all relating to the improper layout of
the clock on the home-screen status bar:

1. The OperatorNameView is now getting inflated by default by Dagger,
   which is fine. But it was never hidden. This change makes it GONE by
   default so it does not push the clock over unnecessarily

2. For some reason, the left-side padding was 2x the right side padding
   for the status bar contents. Made them equal

3. Reduced the embedded left-side clock padding that is read by
   Clock.java from 7dp -> 4dp. This makes the clock align more with the
   battery. They're off by only one pixel now!

This entire area is under construction, so it makes sense to manually
tune things for now. In general though we will be looking at making
these layouts more programmatically-correct rather than requring
screenshot analysis.

Test: manual; comparing screenshots
Bug: 322779840
Flag: NONE
Change-Id: Iaf0784d7f39b26c5f94f4ceae5bcc56732344831
parent e3b7288b
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -174,7 +174,7 @@
    <dimen name="status_bar_clock_size">14sp</dimen>

    <!-- The starting padding for the clock in the status bar. -->
    <dimen name="status_bar_clock_starting_padding">7dp</dimen>
    <dimen name="status_bar_clock_starting_padding">4dp</dimen>

    <!-- The end padding for the clock in the status bar. -->
    <dimen name="status_bar_clock_end_padding">0dp</dimen>
@@ -398,7 +398,7 @@
    <dimen name="status_bar_icon_horizontal_margin">0sp</dimen>

    <!-- the padding on the start of the statusbar -->
    <dimen name="status_bar_padding_start">8dp</dimen>
    <dimen name="status_bar_padding_start">4dp</dimen>

    <!-- the padding on the end of the statusbar -->
    <dimen name="status_bar_padding_end">4dp</dimen>
+3 −1
Original line number Diff line number Diff line
@@ -91,7 +91,9 @@ public interface StatusBarFragmentModule {
    @StatusBarFragmentScope
    @Named(OPERATOR_NAME_VIEW)
    static View provideOperatorNameView(@RootView PhoneStatusBarView view) {
        return ((ViewStub) view.findViewById(R.id.operator_name_stub)).inflate();
        View operatorName = ((ViewStub) view.findViewById(R.id.operator_name_stub)).inflate();
        operatorName.setVisibility(View.GONE);
        return operatorName;
    }

    /** */