Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 0d508ca7 authored by William Xiao's avatar William Xiao Committed by Android (Google) Code Review
Browse files

Merge "Address follow-up comments for UMO in hub mode" into main

parents be10ee5a 46faf200
Loading
Loading
Loading
Loading
+1 −6
Original line number Diff line number Diff line
@@ -25,7 +25,6 @@ import androidx.compose.foundation.layout.Box
import androidx.compose.foundation.layout.fillMaxHeight
import androidx.compose.foundation.layout.fillMaxSize
import androidx.compose.foundation.layout.height
import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.layout.width
import androidx.compose.foundation.lazy.grid.GridCells
import androidx.compose.foundation.lazy.grid.GridItemSpan
@@ -164,11 +163,7 @@ private fun TutorialContent(modifier: Modifier = Modifier) {
@Composable
private fun Umo(viewModel: CommunalViewModel, modifier: Modifier = Modifier) {
    AndroidView(
        modifier =
            modifier
                .width(Dimensions.CardWidth)
                .height(Dimensions.CardHeightThird)
                .padding(Dimensions.Spacing),
        modifier = modifier,
        factory = {
            viewModel.mediaHost.expansion = MediaHostState.EXPANDED
            viewModel.mediaHost.showsOnlyActiveMedia = false
+1 −0
Original line number Diff line number Diff line
@@ -141,6 +141,7 @@ constructor(
    private val umoContent: Flow<List<CommunalContentModel.Umo>> =
        mediaRepository.mediaPlaying.flatMapLatest { mediaPlaying ->
            if (mediaPlaying) {
                // TODO(b/310254801): support HALF and FULL layouts
                flowOf(listOf(CommunalContentModel.Umo(CommunalContentSize.THIRD)))
            } else {
                flowOf(emptyList())
+1 −1
Original line number Diff line number Diff line
@@ -240,7 +240,7 @@ class CommunalInteractorTest : SysuiTestCase() {
        }

    @Test
    fun contentOrdering() =
    fun ordering_smartspaceBeforeUmoBeforeWidgets() =
        testScope.runTest {
            tutorialRepository.setTutorialSettingState(HUB_MODE_TUTORIAL_COMPLETED)