Loading packages/SystemUI/multivalentTests/src/com/android/systemui/communal/view/viewmodel/CommunalEditModeViewModelTest.kt +2 −1 Original line number Diff line number Diff line Loading @@ -39,6 +39,7 @@ import com.android.systemui.smartspace.data.repository.FakeSmartspaceRepository import com.android.systemui.util.mockito.mock import com.android.systemui.util.mockito.whenever import com.google.common.truth.Truth.assertThat import javax.inject.Provider import kotlinx.coroutines.test.TestScope import kotlinx.coroutines.test.runTest import org.junit.Before Loading Loading @@ -83,7 +84,7 @@ class CommunalEditModeViewModelTest : SysuiTestCase() { underTest = CommunalEditModeViewModel( withDeps.communalInteractor, shadeViewController, Provider { shadeViewController }, powerManager, mediaHost, ) Loading packages/SystemUI/multivalentTests/src/com/android/systemui/communal/view/viewmodel/CommunalViewModelTest.kt +2 −1 Original line number Diff line number Diff line Loading @@ -39,6 +39,7 @@ import com.android.systemui.smartspace.data.repository.FakeSmartspaceRepository import com.android.systemui.util.mockito.mock import com.android.systemui.util.mockito.whenever import com.google.common.truth.Truth.assertThat import javax.inject.Provider import kotlinx.coroutines.test.TestScope import kotlinx.coroutines.test.runTest import org.junit.Before Loading Loading @@ -84,7 +85,7 @@ class CommunalViewModelTest : SysuiTestCase() { CommunalViewModel( withDeps.communalInteractor, withDeps.tutorialInteractor, shadeViewController, Provider { shadeViewController }, powerManager, mediaHost, ) Loading packages/SystemUI/src/com/android/systemui/communal/ui/viewmodel/BaseCommunalViewModel.kt +3 −2 Original line number Diff line number Diff line Loading @@ -24,13 +24,14 @@ import com.android.systemui.communal.domain.model.CommunalContentModel import com.android.systemui.communal.shared.model.CommunalSceneKey import com.android.systemui.media.controls.ui.MediaHost import com.android.systemui.shade.ShadeViewController import javax.inject.Provider import kotlinx.coroutines.flow.Flow import kotlinx.coroutines.flow.StateFlow /** The base view model for the communal hub. */ abstract class BaseCommunalViewModel( private val communalInteractor: CommunalInteractor, private val shadeViewController: ShadeViewController, private val shadeViewController: Provider<ShadeViewController>, private val powerManager: PowerManager, val mediaHost: MediaHost, ) { Loading @@ -48,7 +49,7 @@ abstract class BaseCommunalViewModel( fun onOuterTouch(motionEvent: MotionEvent) { // Forward the touch to the shade so that basic gestures like swipe up/down for // shade/bouncer work. shadeViewController.handleExternalTouch(motionEvent) shadeViewController.get().handleExternalTouch(motionEvent) } // TODO(b/308813166): remove once CommunalContainer is moved lower in z-order and doesn't block Loading packages/SystemUI/src/com/android/systemui/communal/ui/viewmodel/CommunalEditModeViewModel.kt +2 −1 Original line number Diff line number Diff line Loading @@ -25,6 +25,7 @@ import com.android.systemui.media.dagger.MediaModule import com.android.systemui.shade.ShadeViewController import javax.inject.Inject import javax.inject.Named import javax.inject.Provider import kotlinx.coroutines.flow.Flow /** The view model for communal hub in edit mode. */ Loading @@ -33,7 +34,7 @@ class CommunalEditModeViewModel @Inject constructor( private val communalInteractor: CommunalInteractor, shadeViewController: ShadeViewController, shadeViewController: Provider<ShadeViewController>, powerManager: PowerManager, @Named(MediaModule.COMMUNAL_HUB) mediaHost: MediaHost, ) : BaseCommunalViewModel(communalInteractor, shadeViewController, powerManager, mediaHost) { Loading packages/SystemUI/src/com/android/systemui/communal/ui/viewmodel/CommunalViewModel.kt +2 −1 Original line number Diff line number Diff line Loading @@ -26,6 +26,7 @@ import com.android.systemui.media.dagger.MediaModule import com.android.systemui.shade.ShadeViewController import javax.inject.Inject import javax.inject.Named import javax.inject.Provider import kotlinx.coroutines.ExperimentalCoroutinesApi import kotlinx.coroutines.flow.Flow import kotlinx.coroutines.flow.combine Loading @@ -39,7 +40,7 @@ class CommunalViewModel constructor( private val communalInteractor: CommunalInteractor, tutorialInteractor: CommunalTutorialInteractor, shadeViewController: ShadeViewController, shadeViewController: Provider<ShadeViewController>, powerManager: PowerManager, @Named(MediaModule.COMMUNAL_HUB) mediaHost: MediaHost, ) : BaseCommunalViewModel(communalInteractor, shadeViewController, powerManager, mediaHost) { Loading Loading
packages/SystemUI/multivalentTests/src/com/android/systemui/communal/view/viewmodel/CommunalEditModeViewModelTest.kt +2 −1 Original line number Diff line number Diff line Loading @@ -39,6 +39,7 @@ import com.android.systemui.smartspace.data.repository.FakeSmartspaceRepository import com.android.systemui.util.mockito.mock import com.android.systemui.util.mockito.whenever import com.google.common.truth.Truth.assertThat import javax.inject.Provider import kotlinx.coroutines.test.TestScope import kotlinx.coroutines.test.runTest import org.junit.Before Loading Loading @@ -83,7 +84,7 @@ class CommunalEditModeViewModelTest : SysuiTestCase() { underTest = CommunalEditModeViewModel( withDeps.communalInteractor, shadeViewController, Provider { shadeViewController }, powerManager, mediaHost, ) Loading
packages/SystemUI/multivalentTests/src/com/android/systemui/communal/view/viewmodel/CommunalViewModelTest.kt +2 −1 Original line number Diff line number Diff line Loading @@ -39,6 +39,7 @@ import com.android.systemui.smartspace.data.repository.FakeSmartspaceRepository import com.android.systemui.util.mockito.mock import com.android.systemui.util.mockito.whenever import com.google.common.truth.Truth.assertThat import javax.inject.Provider import kotlinx.coroutines.test.TestScope import kotlinx.coroutines.test.runTest import org.junit.Before Loading Loading @@ -84,7 +85,7 @@ class CommunalViewModelTest : SysuiTestCase() { CommunalViewModel( withDeps.communalInteractor, withDeps.tutorialInteractor, shadeViewController, Provider { shadeViewController }, powerManager, mediaHost, ) Loading
packages/SystemUI/src/com/android/systemui/communal/ui/viewmodel/BaseCommunalViewModel.kt +3 −2 Original line number Diff line number Diff line Loading @@ -24,13 +24,14 @@ import com.android.systemui.communal.domain.model.CommunalContentModel import com.android.systemui.communal.shared.model.CommunalSceneKey import com.android.systemui.media.controls.ui.MediaHost import com.android.systemui.shade.ShadeViewController import javax.inject.Provider import kotlinx.coroutines.flow.Flow import kotlinx.coroutines.flow.StateFlow /** The base view model for the communal hub. */ abstract class BaseCommunalViewModel( private val communalInteractor: CommunalInteractor, private val shadeViewController: ShadeViewController, private val shadeViewController: Provider<ShadeViewController>, private val powerManager: PowerManager, val mediaHost: MediaHost, ) { Loading @@ -48,7 +49,7 @@ abstract class BaseCommunalViewModel( fun onOuterTouch(motionEvent: MotionEvent) { // Forward the touch to the shade so that basic gestures like swipe up/down for // shade/bouncer work. shadeViewController.handleExternalTouch(motionEvent) shadeViewController.get().handleExternalTouch(motionEvent) } // TODO(b/308813166): remove once CommunalContainer is moved lower in z-order and doesn't block Loading
packages/SystemUI/src/com/android/systemui/communal/ui/viewmodel/CommunalEditModeViewModel.kt +2 −1 Original line number Diff line number Diff line Loading @@ -25,6 +25,7 @@ import com.android.systemui.media.dagger.MediaModule import com.android.systemui.shade.ShadeViewController import javax.inject.Inject import javax.inject.Named import javax.inject.Provider import kotlinx.coroutines.flow.Flow /** The view model for communal hub in edit mode. */ Loading @@ -33,7 +34,7 @@ class CommunalEditModeViewModel @Inject constructor( private val communalInteractor: CommunalInteractor, shadeViewController: ShadeViewController, shadeViewController: Provider<ShadeViewController>, powerManager: PowerManager, @Named(MediaModule.COMMUNAL_HUB) mediaHost: MediaHost, ) : BaseCommunalViewModel(communalInteractor, shadeViewController, powerManager, mediaHost) { Loading
packages/SystemUI/src/com/android/systemui/communal/ui/viewmodel/CommunalViewModel.kt +2 −1 Original line number Diff line number Diff line Loading @@ -26,6 +26,7 @@ import com.android.systemui.media.dagger.MediaModule import com.android.systemui.shade.ShadeViewController import javax.inject.Inject import javax.inject.Named import javax.inject.Provider import kotlinx.coroutines.ExperimentalCoroutinesApi import kotlinx.coroutines.flow.Flow import kotlinx.coroutines.flow.combine Loading @@ -39,7 +40,7 @@ class CommunalViewModel constructor( private val communalInteractor: CommunalInteractor, tutorialInteractor: CommunalTutorialInteractor, shadeViewController: ShadeViewController, shadeViewController: Provider<ShadeViewController>, powerManager: PowerManager, @Named(MediaModule.COMMUNAL_HUB) mediaHost: MediaHost, ) : BaseCommunalViewModel(communalInteractor, shadeViewController, powerManager, mediaHost) { Loading