Loading packages/SystemUI/multivalentTests/src/com/android/systemui/statusbar/notification/collection/coordinator/LockScreenMinimalismCoordinatorTest.kt +2 −4 Original line number Diff line number Diff line Loading @@ -196,16 +196,14 @@ class LockScreenMinimalismCoordinatorTest : SysuiTestCase() { kosmos.activeNotificationListRepository.topOngoingNotificationKey.value = null kosmos.activeNotificationListRepository.topUnseenNotificationKey.value = child2.key assertThat(promoter.shouldPromoteToTopLevel(child1)).isFalse() assertThat(promoter.shouldPromoteToTopLevel(child2)) .isEqualTo(NotificationMinimalism.ungroupTopUnseen) assertThat(promoter.shouldPromoteToTopLevel(child2)).isFalse() assertThat(promoter.shouldPromoteToTopLevel(child3)).isFalse() assertThat(promoter.shouldPromoteToTopLevel(parent)).isFalse() kosmos.activeNotificationListRepository.topOngoingNotificationKey.value = child1.key kosmos.activeNotificationListRepository.topUnseenNotificationKey.value = child2.key assertThat(promoter.shouldPromoteToTopLevel(child1)).isTrue() assertThat(promoter.shouldPromoteToTopLevel(child2)) .isEqualTo(NotificationMinimalism.ungroupTopUnseen) assertThat(promoter.shouldPromoteToTopLevel(child2)).isFalse() assertThat(promoter.shouldPromoteToTopLevel(child3)).isFalse() assertThat(promoter.shouldPromoteToTopLevel(parent)).isFalse() } Loading packages/SystemUI/src/com/android/systemui/statusbar/notification/collection/coordinator/LockScreenMinimalismCoordinator.kt +1 −2 Original line number Diff line number Diff line Loading @@ -219,8 +219,7 @@ constructor( NotificationMinimalism.isUnexpectedlyInLegacyMode() -> false !minimalismEnabled -> false seenNotificationsInteractor.isTopOngoingNotification(child) -> true !NotificationMinimalism.ungroupTopUnseen -> false else -> seenNotificationsInteractor.isTopUnseenNotification(child) else -> false } } Loading packages/SystemUI/src/com/android/systemui/statusbar/notification/shared/NotificationMinimalism.kt +0 −13 Original line number Diff line number Diff line Loading @@ -35,19 +35,6 @@ object NotificationMinimalism { inline val isEnabled get() = Flags.notificationMinimalism() /** * The prototype will (by default) use a promoter to ensure that the top unseen notification is * not grouped, but this property read allows that behavior to be disabled. */ val ungroupTopUnseen: Boolean get() = if (isUnexpectedlyInLegacyMode()) false else SystemProperties.getBoolean( "persist.notification_minimalism_prototype.ungroup_top_unseen", false ) /** * Called to ensure code is only run when the flag is enabled. This protects users from the * unintended behaviors caused by accidentally running new logic, while also crashing on an eng Loading Loading
packages/SystemUI/multivalentTests/src/com/android/systemui/statusbar/notification/collection/coordinator/LockScreenMinimalismCoordinatorTest.kt +2 −4 Original line number Diff line number Diff line Loading @@ -196,16 +196,14 @@ class LockScreenMinimalismCoordinatorTest : SysuiTestCase() { kosmos.activeNotificationListRepository.topOngoingNotificationKey.value = null kosmos.activeNotificationListRepository.topUnseenNotificationKey.value = child2.key assertThat(promoter.shouldPromoteToTopLevel(child1)).isFalse() assertThat(promoter.shouldPromoteToTopLevel(child2)) .isEqualTo(NotificationMinimalism.ungroupTopUnseen) assertThat(promoter.shouldPromoteToTopLevel(child2)).isFalse() assertThat(promoter.shouldPromoteToTopLevel(child3)).isFalse() assertThat(promoter.shouldPromoteToTopLevel(parent)).isFalse() kosmos.activeNotificationListRepository.topOngoingNotificationKey.value = child1.key kosmos.activeNotificationListRepository.topUnseenNotificationKey.value = child2.key assertThat(promoter.shouldPromoteToTopLevel(child1)).isTrue() assertThat(promoter.shouldPromoteToTopLevel(child2)) .isEqualTo(NotificationMinimalism.ungroupTopUnseen) assertThat(promoter.shouldPromoteToTopLevel(child2)).isFalse() assertThat(promoter.shouldPromoteToTopLevel(child3)).isFalse() assertThat(promoter.shouldPromoteToTopLevel(parent)).isFalse() } Loading
packages/SystemUI/src/com/android/systemui/statusbar/notification/collection/coordinator/LockScreenMinimalismCoordinator.kt +1 −2 Original line number Diff line number Diff line Loading @@ -219,8 +219,7 @@ constructor( NotificationMinimalism.isUnexpectedlyInLegacyMode() -> false !minimalismEnabled -> false seenNotificationsInteractor.isTopOngoingNotification(child) -> true !NotificationMinimalism.ungroupTopUnseen -> false else -> seenNotificationsInteractor.isTopUnseenNotification(child) else -> false } } Loading
packages/SystemUI/src/com/android/systemui/statusbar/notification/shared/NotificationMinimalism.kt +0 −13 Original line number Diff line number Diff line Loading @@ -35,19 +35,6 @@ object NotificationMinimalism { inline val isEnabled get() = Flags.notificationMinimalism() /** * The prototype will (by default) use a promoter to ensure that the top unseen notification is * not grouped, but this property read allows that behavior to be disabled. */ val ungroupTopUnseen: Boolean get() = if (isUnexpectedlyInLegacyMode()) false else SystemProperties.getBoolean( "persist.notification_minimalism_prototype.ungroup_top_unseen", false ) /** * Called to ensure code is only run when the flag is enabled. This protects users from the * unintended behaviors caused by accidentally running new logic, while also crashing on an eng Loading