Loading packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java +8 −1 Original line number Diff line number Diff line Loading @@ -75,6 +75,7 @@ import com.android.systemui.R; import com.android.systemui.recent.RecentTasksLoader; import com.android.systemui.statusbar.BaseStatusBar; import com.android.systemui.statusbar.NotificationData; import com.android.systemui.statusbar.NotificationData.Entry; import com.android.systemui.statusbar.SignalClusterView; import com.android.systemui.statusbar.StatusBarIconView; import com.android.systemui.statusbar.policy.BatteryController; Loading Loading @@ -118,6 +119,9 @@ public class PhoneStatusBar extends BaseStatusBar { private static final boolean CLOSE_PANEL_WHEN_EMPTIED = true; private static final int NOTIFICATION_PRIORITY_MULTIPLIER = 10; // see NotificationManagerService private static final int HIDE_ICONS_BELOW_SCORE = Notification.PRIORITY_LOW * NOTIFICATION_PRIORITY_MULTIPLIER; // fling gesture tuning parameters, scaled to display density private float mSelfExpandVelocityPx; // classic value: 2000px/s private float mSelfCollapseVelocityPx; // classic value: 2000px/s (will be negated to collapse "up") Loading Loading @@ -905,7 +909,10 @@ public class PhoneStatusBar extends BaseStatusBar { ArrayList<View> toShow = new ArrayList<View>(); for (int i=0; i<N; i++) { toShow.add(mNotificationData.get(N-i-1).icon); Entry ent = mNotificationData.get(N-i-1); if (ent.notification.score >= HIDE_ICONS_BELOW_SCORE) { toShow.add(ent.icon); } } ArrayList<View> toRemove = new ArrayList<View>(); Loading packages/SystemUI/src/com/android/systemui/statusbar/tablet/TabletStatusBar.java +12 −4 Original line number Diff line number Diff line Loading @@ -70,6 +70,7 @@ import com.android.systemui.statusbar.BaseStatusBar; import com.android.systemui.statusbar.NotificationData; import com.android.systemui.statusbar.SignalClusterView; import com.android.systemui.statusbar.StatusBarIconView; import com.android.systemui.statusbar.NotificationData.Entry; import com.android.systemui.statusbar.policy.BatteryController; import com.android.systemui.statusbar.policy.BluetoothController; import com.android.systemui.statusbar.policy.CompatModeButton; Loading Loading @@ -111,6 +112,9 @@ public class TabletStatusBar extends BaseStatusBar implements final static int NOTIFICATION_PEEK_HOLD_THRESH = 200; // ms final static int NOTIFICATION_PEEK_FADE_DELAY = 3000; // ms private static final int NOTIFICATION_PRIORITY_MULTIPLIER = 10; // see NotificationManagerService private static final int HIDE_ICONS_BELOW_SCORE = Notification.PRIORITY_LOW * NOTIFICATION_PRIORITY_MULTIPLIER; // The height of the bar, as definied by the build. It may be taller if we're plugged // into hdmi. int mNaturalBarHeight = -1; Loading Loading @@ -1713,9 +1717,12 @@ public class TabletStatusBar extends BaseStatusBar implements if (mInputMethodSwitchButton.getVisibility() != View.GONE) maxNotificationIconsCount --; if (mCompatModeButton.getVisibility() != View.GONE) maxNotificationIconsCount --; for (int i=0; i< maxNotificationIconsCount; i++) { for (int i=0; toShow.size()< maxNotificationIconsCount; i++) { if (i >= N) break; toShow.add(mNotificationData.get(N-i-1).icon); Entry ent = mNotificationData.get(N-i-1); if (ent.notification.score >= HIDE_ICONS_BELOW_SCORE) { toShow.add(ent.icon); } } ArrayList<View> toRemove = new ArrayList<View>(); Loading Loading @@ -1764,7 +1771,8 @@ public class TabletStatusBar extends BaseStatusBar implements for (int i=0; i<toShow.size(); i++) { View v = toShow.get(i); if (v.getParent() == null) { mPile.addView(v, N-1-i); // the notification panel has newest at the bottom // the notification panel has the most important things at the bottom mPile.addView(v, N-1-i); } } Loading Loading
packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java +8 −1 Original line number Diff line number Diff line Loading @@ -75,6 +75,7 @@ import com.android.systemui.R; import com.android.systemui.recent.RecentTasksLoader; import com.android.systemui.statusbar.BaseStatusBar; import com.android.systemui.statusbar.NotificationData; import com.android.systemui.statusbar.NotificationData.Entry; import com.android.systemui.statusbar.SignalClusterView; import com.android.systemui.statusbar.StatusBarIconView; import com.android.systemui.statusbar.policy.BatteryController; Loading Loading @@ -118,6 +119,9 @@ public class PhoneStatusBar extends BaseStatusBar { private static final boolean CLOSE_PANEL_WHEN_EMPTIED = true; private static final int NOTIFICATION_PRIORITY_MULTIPLIER = 10; // see NotificationManagerService private static final int HIDE_ICONS_BELOW_SCORE = Notification.PRIORITY_LOW * NOTIFICATION_PRIORITY_MULTIPLIER; // fling gesture tuning parameters, scaled to display density private float mSelfExpandVelocityPx; // classic value: 2000px/s private float mSelfCollapseVelocityPx; // classic value: 2000px/s (will be negated to collapse "up") Loading Loading @@ -905,7 +909,10 @@ public class PhoneStatusBar extends BaseStatusBar { ArrayList<View> toShow = new ArrayList<View>(); for (int i=0; i<N; i++) { toShow.add(mNotificationData.get(N-i-1).icon); Entry ent = mNotificationData.get(N-i-1); if (ent.notification.score >= HIDE_ICONS_BELOW_SCORE) { toShow.add(ent.icon); } } ArrayList<View> toRemove = new ArrayList<View>(); Loading
packages/SystemUI/src/com/android/systemui/statusbar/tablet/TabletStatusBar.java +12 −4 Original line number Diff line number Diff line Loading @@ -70,6 +70,7 @@ import com.android.systemui.statusbar.BaseStatusBar; import com.android.systemui.statusbar.NotificationData; import com.android.systemui.statusbar.SignalClusterView; import com.android.systemui.statusbar.StatusBarIconView; import com.android.systemui.statusbar.NotificationData.Entry; import com.android.systemui.statusbar.policy.BatteryController; import com.android.systemui.statusbar.policy.BluetoothController; import com.android.systemui.statusbar.policy.CompatModeButton; Loading Loading @@ -111,6 +112,9 @@ public class TabletStatusBar extends BaseStatusBar implements final static int NOTIFICATION_PEEK_HOLD_THRESH = 200; // ms final static int NOTIFICATION_PEEK_FADE_DELAY = 3000; // ms private static final int NOTIFICATION_PRIORITY_MULTIPLIER = 10; // see NotificationManagerService private static final int HIDE_ICONS_BELOW_SCORE = Notification.PRIORITY_LOW * NOTIFICATION_PRIORITY_MULTIPLIER; // The height of the bar, as definied by the build. It may be taller if we're plugged // into hdmi. int mNaturalBarHeight = -1; Loading Loading @@ -1713,9 +1717,12 @@ public class TabletStatusBar extends BaseStatusBar implements if (mInputMethodSwitchButton.getVisibility() != View.GONE) maxNotificationIconsCount --; if (mCompatModeButton.getVisibility() != View.GONE) maxNotificationIconsCount --; for (int i=0; i< maxNotificationIconsCount; i++) { for (int i=0; toShow.size()< maxNotificationIconsCount; i++) { if (i >= N) break; toShow.add(mNotificationData.get(N-i-1).icon); Entry ent = mNotificationData.get(N-i-1); if (ent.notification.score >= HIDE_ICONS_BELOW_SCORE) { toShow.add(ent.icon); } } ArrayList<View> toRemove = new ArrayList<View>(); Loading Loading @@ -1764,7 +1771,8 @@ public class TabletStatusBar extends BaseStatusBar implements for (int i=0; i<toShow.size(); i++) { View v = toShow.get(i); if (v.getParent() == null) { mPile.addView(v, N-1-i); // the notification panel has newest at the bottom // the notification panel has the most important things at the bottom mPile.addView(v, N-1-i); } } Loading