Loading packages/SystemUI/src/com/android/systemui/statusbar/NotificationShelf.java +0 −1 Original line number Diff line number Diff line Loading @@ -929,7 +929,6 @@ public class NotificationShelf extends ActivatableNotificationView implements public void setAnimationsEnabled(boolean enabled) { mAnimationsEnabled = enabled; mCollapsedIcons.setAnimationsEnabled(enabled); if (!enabled) { // we need to wait with enabling the animations until the first frame has passed mShelfIcons.setAnimationsEnabled(false); Loading packages/SystemUI/src/com/android/systemui/statusbar/notification/stack/NotificationStackScrollLayout.java +1 −0 Original line number Diff line number Diff line Loading @@ -3223,6 +3223,7 @@ public class NotificationStackScrollLayout extends ViewGroup implements ScrollAd private void updateNotificationAnimationStates() { boolean running = mAnimationsEnabled || hasPulsingNotifications(); mShelf.setAnimationsEnabled(running); mIconAreaController.setAnimationsEnabled(running); int childCount = getChildCount(); for (int i = 0; i < childCount; i++) { View child = getChildAt(i); Loading packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationIconAreaController.java +21 −0 Original line number Diff line number Diff line Loading @@ -24,6 +24,7 @@ import com.android.systemui.statusbar.NotificationListener; import com.android.systemui.statusbar.NotificationMediaManager; import com.android.systemui.statusbar.NotificationShelf; import com.android.systemui.statusbar.StatusBarIconView; import com.android.systemui.statusbar.StatusBarState; import com.android.systemui.statusbar.notification.NotificationEntryManager; import com.android.systemui.statusbar.notification.NotificationUtils; import com.android.systemui.statusbar.notification.collection.NotificationEntry; Loading Loading @@ -78,6 +79,7 @@ public class NotificationIconAreaController implements DarkReceiver, private Context mContext; private boolean mFullyDark; private boolean mShowLowPriority = true; private boolean mAnimationsEnabled; /** * Ratio representing being awake or in ambient mode, where 1 is dark and 0 awake. Loading Loading @@ -283,6 +285,25 @@ public class NotificationIconAreaController implements DarkReceiver, false /* hide centered icon */); } /** * If icons of the status bar should animate when they are added or removed. */ public void setAnimationsEnabled(boolean enabled) { mAnimationsEnabled = enabled; updateAnimations(); } @Override public void onStateChanged(int newState) { updateAnimations(); } private void updateAnimations() { boolean inShade = mStatusBarStateController.getState() == StatusBarState.SHADE; mCenteredIcon.setAnimationsEnabled(mAnimationsEnabled && inShade); mNotificationIcons.setAnimationsEnabled(mAnimationsEnabled && inShade); } @VisibleForTesting boolean shouldShouldLowPriorityIcons() { return mShowLowPriority; Loading packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationIconContainer.java +1 −1 Original line number Diff line number Diff line Loading @@ -315,7 +315,7 @@ public class NotificationIconContainer extends AlphaOptimizedFrameLayout { @Override public void onViewRemoved(View child) { super.onViewRemoved(child); if (child instanceof StatusBarIconView) { if (mAnimationsEnabled && child instanceof StatusBarIconView) { boolean isReplacingIcon = isReplacingIcon(child); final StatusBarIconView icon = (StatusBarIconView) child; if (icon.getVisibleState() != StatusBarIconView.STATE_HIDDEN Loading Loading
packages/SystemUI/src/com/android/systemui/statusbar/NotificationShelf.java +0 −1 Original line number Diff line number Diff line Loading @@ -929,7 +929,6 @@ public class NotificationShelf extends ActivatableNotificationView implements public void setAnimationsEnabled(boolean enabled) { mAnimationsEnabled = enabled; mCollapsedIcons.setAnimationsEnabled(enabled); if (!enabled) { // we need to wait with enabling the animations until the first frame has passed mShelfIcons.setAnimationsEnabled(false); Loading
packages/SystemUI/src/com/android/systemui/statusbar/notification/stack/NotificationStackScrollLayout.java +1 −0 Original line number Diff line number Diff line Loading @@ -3223,6 +3223,7 @@ public class NotificationStackScrollLayout extends ViewGroup implements ScrollAd private void updateNotificationAnimationStates() { boolean running = mAnimationsEnabled || hasPulsingNotifications(); mShelf.setAnimationsEnabled(running); mIconAreaController.setAnimationsEnabled(running); int childCount = getChildCount(); for (int i = 0; i < childCount; i++) { View child = getChildAt(i); Loading
packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationIconAreaController.java +21 −0 Original line number Diff line number Diff line Loading @@ -24,6 +24,7 @@ import com.android.systemui.statusbar.NotificationListener; import com.android.systemui.statusbar.NotificationMediaManager; import com.android.systemui.statusbar.NotificationShelf; import com.android.systemui.statusbar.StatusBarIconView; import com.android.systemui.statusbar.StatusBarState; import com.android.systemui.statusbar.notification.NotificationEntryManager; import com.android.systemui.statusbar.notification.NotificationUtils; import com.android.systemui.statusbar.notification.collection.NotificationEntry; Loading Loading @@ -78,6 +79,7 @@ public class NotificationIconAreaController implements DarkReceiver, private Context mContext; private boolean mFullyDark; private boolean mShowLowPriority = true; private boolean mAnimationsEnabled; /** * Ratio representing being awake or in ambient mode, where 1 is dark and 0 awake. Loading Loading @@ -283,6 +285,25 @@ public class NotificationIconAreaController implements DarkReceiver, false /* hide centered icon */); } /** * If icons of the status bar should animate when they are added or removed. */ public void setAnimationsEnabled(boolean enabled) { mAnimationsEnabled = enabled; updateAnimations(); } @Override public void onStateChanged(int newState) { updateAnimations(); } private void updateAnimations() { boolean inShade = mStatusBarStateController.getState() == StatusBarState.SHADE; mCenteredIcon.setAnimationsEnabled(mAnimationsEnabled && inShade); mNotificationIcons.setAnimationsEnabled(mAnimationsEnabled && inShade); } @VisibleForTesting boolean shouldShouldLowPriorityIcons() { return mShowLowPriority; Loading
packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationIconContainer.java +1 −1 Original line number Diff line number Diff line Loading @@ -315,7 +315,7 @@ public class NotificationIconContainer extends AlphaOptimizedFrameLayout { @Override public void onViewRemoved(View child) { super.onViewRemoved(child); if (child instanceof StatusBarIconView) { if (mAnimationsEnabled && child instanceof StatusBarIconView) { boolean isReplacingIcon = isReplacingIcon(child); final StatusBarIconView icon = (StatusBarIconView) child; if (icon.getVisibleState() != StatusBarIconView.STATE_HIDDEN Loading