Loading packages/SystemUI/compose/features/src/com/android/systemui/notifications/ui/composable/row/BundleHeader.kt +5 −1 Original line number Diff line number Diff line Loading @@ -46,6 +46,7 @@ import androidx.compose.ui.layout.Layout import androidx.compose.ui.platform.LocalDensity import androidx.compose.ui.res.stringResource import androidx.compose.ui.semantics.collapse import androidx.compose.ui.semantics.contentDescription import androidx.compose.ui.semantics.dismiss import androidx.compose.ui.semantics.expand import androidx.compose.ui.semantics.semantics Loading Loading @@ -236,7 +237,10 @@ private fun ContentScope.BundleHeaderContent( ExpansionControl( collapsed = collapsed, numberToShow = viewModel.numberOfChildren, modifier = Modifier.padding(start = 8.dp, end = 16.dp), modifier = Modifier.padding(start = 8.dp, end = 16.dp).semantics(mergeDescendants = false) { contentDescription = viewModel.numberOfChildrenContentDescription }, ) } } Loading packages/SystemUI/res/values/strings.xml +6 −0 Original line number Diff line number Diff line Loading @@ -2183,6 +2183,12 @@ <!-- Notification bundles onboarding affordance [CHAR LIMIT=NONE]--> <string name="notification_onboarding_bundles_message">Notification organizer bundles and silences lower priority notifications</string> <!-- Number of notifications for bundles header [CHAR LIMIT=NONE] --> <string name="notification_bundle_header_counter">{count, plural, =1 {# notification} other {# notifications} }</string> <!-- Notification Inline controls: button to dismiss the blocking helper [CHAR_LIMIT=20] --> <string name="inline_done_button">Done</string> Loading packages/SystemUI/src/com/android/systemui/statusbar/notification/row/domain/interactor/BundleInteractor.kt +10 −0 Original line number Diff line number Diff line Loading @@ -27,10 +27,12 @@ import com.android.compose.animation.scene.MutableSceneTransitionLayoutState import com.android.compose.animation.scene.SceneKey import com.android.systemui.dagger.qualifiers.Background import com.android.systemui.notifications.ui.composable.row.BundleHeader import com.android.systemui.res.R import com.android.systemui.statusbar.notification.row.dagger.BundleRowScope import com.android.systemui.statusbar.notification.row.data.model.AppData import com.android.systemui.statusbar.notification.row.data.repository.BundleRepository import com.android.systemui.statusbar.notification.row.icon.AppIconProvider import com.android.systemui.util.icuMessageFormat import com.android.systemui.util.time.SystemClock import com.android.systemui.utils.coroutines.flow.mapLatestConflated import javax.inject.Inject Loading Loading @@ -62,6 +64,14 @@ constructor( val bundleIcon: Int get() = repository.bundleIcon val numberOfChildrenContentDescription: String get() = icuMessageFormat( context.resources, R.string.notification_bundle_header_counter, numberOfChildren ?: 0, ) /** Filters the list of AppData based on time of last collapse by user. */ private fun filterByCollapseTime( rawAppDataList: List<AppData>, Loading packages/SystemUI/src/com/android/systemui/statusbar/notification/row/ui/viewmodel/BundleHeaderViewModel.kt +3 −0 Original line number Diff line number Diff line Loading @@ -54,6 +54,9 @@ class BundleHeaderViewModel @AssistedInject constructor(private val interactor: var backgroundDrawable by mutableStateOf<Drawable?>(null) val numberOfChildrenContentDescription: String get() = interactor.numberOfChildrenContentDescription fun onHeaderClicked() { val targetScene = when (state?.currentScene) { Loading Loading
packages/SystemUI/compose/features/src/com/android/systemui/notifications/ui/composable/row/BundleHeader.kt +5 −1 Original line number Diff line number Diff line Loading @@ -46,6 +46,7 @@ import androidx.compose.ui.layout.Layout import androidx.compose.ui.platform.LocalDensity import androidx.compose.ui.res.stringResource import androidx.compose.ui.semantics.collapse import androidx.compose.ui.semantics.contentDescription import androidx.compose.ui.semantics.dismiss import androidx.compose.ui.semantics.expand import androidx.compose.ui.semantics.semantics Loading Loading @@ -236,7 +237,10 @@ private fun ContentScope.BundleHeaderContent( ExpansionControl( collapsed = collapsed, numberToShow = viewModel.numberOfChildren, modifier = Modifier.padding(start = 8.dp, end = 16.dp), modifier = Modifier.padding(start = 8.dp, end = 16.dp).semantics(mergeDescendants = false) { contentDescription = viewModel.numberOfChildrenContentDescription }, ) } } Loading
packages/SystemUI/res/values/strings.xml +6 −0 Original line number Diff line number Diff line Loading @@ -2183,6 +2183,12 @@ <!-- Notification bundles onboarding affordance [CHAR LIMIT=NONE]--> <string name="notification_onboarding_bundles_message">Notification organizer bundles and silences lower priority notifications</string> <!-- Number of notifications for bundles header [CHAR LIMIT=NONE] --> <string name="notification_bundle_header_counter">{count, plural, =1 {# notification} other {# notifications} }</string> <!-- Notification Inline controls: button to dismiss the blocking helper [CHAR_LIMIT=20] --> <string name="inline_done_button">Done</string> Loading
packages/SystemUI/src/com/android/systemui/statusbar/notification/row/domain/interactor/BundleInteractor.kt +10 −0 Original line number Diff line number Diff line Loading @@ -27,10 +27,12 @@ import com.android.compose.animation.scene.MutableSceneTransitionLayoutState import com.android.compose.animation.scene.SceneKey import com.android.systemui.dagger.qualifiers.Background import com.android.systemui.notifications.ui.composable.row.BundleHeader import com.android.systemui.res.R import com.android.systemui.statusbar.notification.row.dagger.BundleRowScope import com.android.systemui.statusbar.notification.row.data.model.AppData import com.android.systemui.statusbar.notification.row.data.repository.BundleRepository import com.android.systemui.statusbar.notification.row.icon.AppIconProvider import com.android.systemui.util.icuMessageFormat import com.android.systemui.util.time.SystemClock import com.android.systemui.utils.coroutines.flow.mapLatestConflated import javax.inject.Inject Loading Loading @@ -62,6 +64,14 @@ constructor( val bundleIcon: Int get() = repository.bundleIcon val numberOfChildrenContentDescription: String get() = icuMessageFormat( context.resources, R.string.notification_bundle_header_counter, numberOfChildren ?: 0, ) /** Filters the list of AppData based on time of last collapse by user. */ private fun filterByCollapseTime( rawAppDataList: List<AppData>, Loading
packages/SystemUI/src/com/android/systemui/statusbar/notification/row/ui/viewmodel/BundleHeaderViewModel.kt +3 −0 Original line number Diff line number Diff line Loading @@ -54,6 +54,9 @@ class BundleHeaderViewModel @AssistedInject constructor(private val interactor: var backgroundDrawable by mutableStateOf<Drawable?>(null) val numberOfChildrenContentDescription: String get() = interactor.numberOfChildrenContentDescription fun onHeaderClicked() { val targetScene = when (state?.currentScene) { Loading