diff options
2 files changed, 4 insertions, 21 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/notification/row/ExpandableNotificationRow.java b/packages/SystemUI/src/com/android/systemui/statusbar/notification/row/ExpandableNotificationRow.java index 9e7717caf69c..de158c4d017e 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/notification/row/ExpandableNotificationRow.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/notification/row/ExpandableNotificationRow.java @@ -1341,21 +1341,6 @@ public class ExpandableNotificationRow extends ActivatableNotificationView return mOnKeyguard; } - public void removeAllChildren() { - List<ExpandableNotificationRow> notificationChildren = - mChildrenContainer.getAttachedChildren(); - ArrayList<ExpandableNotificationRow> clonedList = new ArrayList<>(notificationChildren); - for (int i = 0; i < clonedList.size(); i++) { - ExpandableNotificationRow row = clonedList.get(i); - if (row.keepInParent()) { - continue; - } - mChildrenContainer.removeNotification(row); - row.setIsChildInGroup(false, null); - } - onAttachedChildrenCountChanged(); - } - @Override public void dismiss(boolean refocusOnDismiss) { super.dismiss(refocusOnDismiss); diff --git a/packages/SystemUI/tests/src/com/android/systemui/statusbar/notification/row/ExpandableNotificationRowTest.java b/packages/SystemUI/tests/src/com/android/systemui/statusbar/notification/row/ExpandableNotificationRowTest.java index 137842ef314f..12cc11450ede 100644 --- a/packages/SystemUI/tests/src/com/android/systemui/statusbar/notification/row/ExpandableNotificationRowTest.java +++ b/packages/SystemUI/tests/src/com/android/systemui/statusbar/notification/row/ExpandableNotificationRowTest.java @@ -232,7 +232,6 @@ public class ExpandableNotificationRowTest extends SysuiTestCase { @Test public void testUserLockedResetEvenWhenNoChildren() { mGroupRow.setUserLocked(true); - mGroupRow.removeAllChildren(); mGroupRow.setUserLocked(false); assertFalse("The childrencontainer should not be userlocked but is, the state " + "seems out of sync.", mGroupRow.getChildrenContainer().isUserLocked()); @@ -240,12 +239,11 @@ public class ExpandableNotificationRowTest extends SysuiTestCase { @Test public void testReinflatedOnDensityChange() { - mGroupRow.setUserLocked(true); - mGroupRow.removeAllChildren(); - mGroupRow.setUserLocked(false); NotificationChildrenContainer mockContainer = mock(NotificationChildrenContainer.class); - mGroupRow.setChildrenContainer(mockContainer); - mGroupRow.onDensityOrFontScaleChanged(); + mNotifRow.setChildrenContainer(mockContainer); + + mNotifRow.onDensityOrFontScaleChanged(); + verify(mockContainer).reInflateViews(any(), any()); } |