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

Commit 8e18dc77 authored by Daniel Sandler's avatar Daniel Sandler
Browse files

Black out the status bar when the shade comes down.

Also move the shade up and forward to overlap the (now
empty) status bar.

As a side effect, DISABLE_SYSTEM_INFO now works for phones.

Bug: 6418617
Change-Id: I3b129e4bb26d3aba55403bf03baf8f4c8ad0ff46
parent 8bbbd3fc
Loading
Loading
Loading
Loading
+5 −5
Original line number Diff line number Diff line
@@ -26,15 +26,15 @@
    android:fitsSystemWindows="true"
    >

    <include layout="@layout/status_bar"
        android:layout_width="match_parent"
        android:layout_height="@*android:dimen/status_bar_height"
        />

    <include layout="@layout/status_bar_expanded"
        android:layout_width="@dimen/notification_panel_width"
        android:layout_height="match_parent"
        android:layout_gravity="center_horizontal|top"
        />

    <include layout="@layout/status_bar"
        android:layout_width="match_parent"
        android:layout_height="@*android:dimen/status_bar_height"
        />

</com.android.systemui.statusbar.phone.StatusBarWindowView>
+4 −4
Original line number Diff line number Diff line
@@ -26,14 +26,14 @@
    android:fitsSystemWindows="true"
    >

    <include layout="@layout/status_bar_expanded"
    <include layout="@layout/status_bar"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:layout_height="@*android:dimen/status_bar_height"
        />

    <include layout="@layout/status_bar"
    <include layout="@layout/status_bar_expanded"
        android:layout_width="match_parent"
        android:layout_height="@*android:dimen/status_bar_height"
        android:layout_height="match_parent"
        />

</com.android.systemui.statusbar.phone.StatusBarWindowView>
+0 −3
Original line number Diff line number Diff line
@@ -33,9 +33,6 @@
    <!-- Height of search panel including navigation bar height -->
    <dimen name="navbar_search_panel_height">300dip</dimen>

    <!-- Extra space above the clock in the panel; on this device, zero -->
    <dimen name="notification_panel_header_padding_top">0dp</dimen>

    <!-- Size of application thumbnail -->
    <dimen name="status_bar_recents_thumbnail_width">200dp</dimen>
    <dimen name="status_bar_recents_thumbnail_height">177dp</dimen>
+3 −3
Original line number Diff line number Diff line
@@ -132,10 +132,10 @@
    <!-- Height of the notification panel header bar -->
    <dimen name="notification_panel_header_height">48dp</dimen>

    <!-- Height of the notification panel header bar -->
    <dimen name="notification_panel_padding_top">@*android:dimen/status_bar_height</dimen>
    <!-- Extra space above the panel -->
    <dimen name="notification_panel_padding_top">4dp</dimen>

    <!-- Extra space above the clock in the panel; half of (notification_panel_header_height - 32) -->
    <!-- Extra space above the clock in the panel -->
    <dimen name="notification_panel_header_padding_top">0dp</dimen>

    <!-- Layout parameters for the notification panel -->
+12 −1
Original line number Diff line number Diff line
@@ -301,6 +301,9 @@ public class PhoneStatusBar extends BaseStatusBar {
                return true;
            }
        });
        mNotificationPanel.setSystemUiVisibility(
                  View.STATUS_BAR_DISABLE_NOTIFICATION_TICKER
                | View.STATUS_BAR_DISABLE_SYSTEM_INFO);

        if (!ActivityManager.isHighEndGfx(mDisplay)) {
            mStatusBarWindow.setBackground(null);
@@ -336,7 +339,6 @@ public class PhoneStatusBar extends BaseStatusBar {
        mPixelFormat = PixelFormat.OPAQUE;
        mStatusIcons = (LinearLayout)mStatusBarView.findViewById(R.id.statusIcons);
        mNotificationIcons = (IconMerger)mStatusBarView.findViewById(R.id.notificationIcons);
        mMoreIcon = mStatusBarView.findViewById(R.id.moreIcon);
        mNotificationIcons.setOverflowIndicator(mMoreIcon);
        mIcons = (LinearLayout)mStatusBarView.findViewById(R.id.icons);
        mTickerView = mStatusBarView.findViewById(R.id.ticker);
@@ -885,6 +887,15 @@ public class PhoneStatusBar extends BaseStatusBar {
        flagdbg.append(">");
        Slog.d(TAG, flagdbg.toString());
        
        if ((diff & StatusBarManager.DISABLE_SYSTEM_INFO) != 0) {
            mIcons.animate().cancel();
            if ((state & StatusBarManager.DISABLE_SYSTEM_INFO) != 0) {
                mIcons.animate().alpha(0f).setStartDelay(100).setDuration(200).start();
            } else {
                mIcons.animate().alpha(1f).setStartDelay(0).setDuration(300).start();
            }
        }

        if ((diff & StatusBarManager.DISABLE_CLOCK) != 0) {
            boolean show = (state & StatusBarManager.DISABLE_CLOCK) == 0;
            showClock(show);