Skip to content

Commit 66d92f8

Browse files
committed
Remove an unnecessary animation.
When the notification panel is full-width (small devices like phones) we can just leave the icons showing all the time, which saves a little CPU during the performance-critical shade expand operation. On sw600dp devices we continue to use DISABLE_SYSTEM_INFO to smoothly hide the status bar when the notification panel appears (and show it when the panel is dismissed). Bug: 6555172 Change-Id: I59a1226549dd1e51c375c3972b47079c1ee856b0
1 parent 913bf80 commit 66d92f8

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -167,6 +167,7 @@ public class PhoneStatusBar extends BaseStatusBar {
167167
int mNotificationPanelMarginBottomPx, mNotificationPanelMarginLeftPx;
168168
int mNotificationPanelGravity;
169169
int mNotificationPanelMinHeight;
170+
boolean mNotificationPanelIsFullScreenWidth;
170171

171172
// top bar
172173
View mClearButton;
@@ -350,9 +351,11 @@ public boolean onTouch(View v, MotionEvent event) {
350351
return true;
351352
}
352353
});
354+
mNotificationPanelIsFullScreenWidth =
355+
(mNotificationPanel.getLayoutParams().width == ViewGroup.LayoutParams.MATCH_PARENT);
353356
mNotificationPanel.setSystemUiVisibility(
354357
View.STATUS_BAR_DISABLE_NOTIFICATION_TICKER
355-
| View.STATUS_BAR_DISABLE_SYSTEM_INFO);
358+
| (mNotificationPanelIsFullScreenWidth ? 0 : View.STATUS_BAR_DISABLE_SYSTEM_INFO));
356359

357360
if (!ActivityManager.isHighEndGfx(mDisplay)) {
358361
mStatusBarWindow.setBackground(null);

0 commit comments

Comments
 (0)