Loading packages/SystemUI/AndroidManifest.xml +1 −1 Original line number Diff line number Diff line Loading @@ -459,7 +459,7 @@ android:label="@string/screenshot_scroll_label" android:finishOnTaskLaunch="true" /> <service android:name=".screenshot.ScreenshotProxyService" <service android:name=".screenshot.proxy.ScreenshotProxyService" android:permission="com.android.systemui.permission.SELF" android:exported="false" /> Loading packages/SystemUI/multivalentTests/src/com/android/systemui/screenshot/ActionIntentExecutorTest.kt +4 −4 Original line number Diff line number Diff line Loading @@ -17,13 +17,13 @@ package com.android.systemui.screenshot import android.content.Intent import androidx.test.ext.junit.runners.AndroidJUnit4 import android.os.Process.myUserHandle import android.platform.test.annotations.EnableFlags import android.testing.TestableContext import androidx.test.ext.junit.runners.AndroidJUnit4 import com.android.systemui.Flags import com.android.systemui.SysuiTestCase import com.android.systemui.screenshot.proxy.SystemUiProxy import com.android.systemui.screenshot.proxy.ScreenshotProxy import com.android.systemui.settings.DisplayTracker import com.android.systemui.shared.system.ActivityManagerWrapper import com.android.systemui.statusbar.phone.CentralSurfaces Loading @@ -45,7 +45,7 @@ class ActionIntentExecutorTest : SysuiTestCase() { private val testableContext = TestableContext(mContext) private val activityManagerWrapper = mock<ActivityManagerWrapper>() private val systemUiProxy = mock<SystemUiProxy>() private val screenshotProxy = mock<ScreenshotProxy>() private val displayTracker = mock<DisplayTracker>() Loading @@ -55,7 +55,7 @@ class ActionIntentExecutorTest : SysuiTestCase() { activityManagerWrapper, testScope, mainDispatcher, systemUiProxy, screenshotProxy, displayTracker, ) Loading packages/SystemUI/src/com/android/systemui/screenshot/ActionIntentExecutor.kt +4 −4 Original line number Diff line number Diff line Loading @@ -37,7 +37,7 @@ import com.android.systemui.Flags import com.android.systemui.dagger.SysUISingleton import com.android.systemui.dagger.qualifiers.Application import com.android.systemui.dagger.qualifiers.Main import com.android.systemui.screenshot.proxy.SystemUiProxy import com.android.systemui.screenshot.proxy.ScreenshotProxy import com.android.systemui.settings.DisplayTracker import com.android.systemui.shared.system.ActivityManagerWrapper import com.android.systemui.statusbar.phone.CentralSurfaces Loading @@ -55,7 +55,7 @@ constructor( private val activityManagerWrapper: ActivityManagerWrapper, @Application private val applicationScope: CoroutineScope, @Main private val mainDispatcher: CoroutineDispatcher, private val systemUiProxy: SystemUiProxy, private val screenshotProxy: ScreenshotProxy, private val displayTracker: DisplayTracker, ) { /** Loading Loading @@ -89,7 +89,7 @@ constructor( CentralSurfaces.SYSTEM_DIALOG_REASON_SCREENSHOT ) } systemUiProxy.dismissKeyguard() screenshotProxy.dismissKeyguard() var transitionOptions: ActivityOptions? = null if (transitionCoordinator?.decor?.isAttachedToWindow == true) { transitionCoordinator.startExit() Loading Loading @@ -127,7 +127,7 @@ constructor( private suspend fun launchCrossProfileIntent( user: UserHandle, intent: Intent, bundle: Bundle? bundle: Bundle?, ) { val connector = getCrossProfileConnector(user) val completion = CompletableDeferred<Unit>() Loading packages/SystemUI/src/com/android/systemui/screenshot/dagger/ScreenshotModule.java +2 −2 Original line number Diff line number Diff line Loading @@ -38,7 +38,7 @@ import com.android.systemui.screenshot.appclips.AppClipsScreenshotHelperService; import com.android.systemui.screenshot.appclips.AppClipsService; import com.android.systemui.screenshot.message.MessageModule; import com.android.systemui.screenshot.policy.ScreenshotPolicyModule; import com.android.systemui.screenshot.proxy.SystemUiProxyModule; import com.android.systemui.screenshot.proxy.ScreenshotProxyModule; import com.android.systemui.screenshot.ui.viewmodel.ScreenshotViewModel; import dagger.Binds; Loading @@ -50,7 +50,7 @@ import dagger.multibindings.IntoMap; /** * Defines injectable resources for Screenshots */ @Module(includes = {ScreenshotPolicyModule.class, SystemUiProxyModule.class, MessageModule.class}) @Module(includes = {ScreenshotPolicyModule.class, ScreenshotProxyModule.class, MessageModule.class}) public abstract class ScreenshotModule { @Binds Loading packages/SystemUI/src/com/android/systemui/screenshot/data/repository/DisplayContentRepositoryImpl.kt +5 −5 Original line number Diff line number Diff line Loading @@ -22,21 +22,21 @@ import android.app.IActivityTaskManager import com.android.systemui.dagger.qualifiers.Background import com.android.systemui.screenshot.data.model.DisplayContentModel import com.android.systemui.screenshot.data.model.SystemUiState import com.android.systemui.screenshot.proxy.SystemUiProxy import com.android.systemui.screenshot.proxy.ScreenshotProxy import javax.inject.Inject import kotlinx.coroutines.CoroutineDispatcher import kotlinx.coroutines.withContext /** * Implements DisplayTaskRepository using [IActivityTaskManager], along with [ProfileTypeRepository] * and [SystemUiProxy]. * and [ScreenshotProxy]. */ @SuppressLint("MissingPermission") class DisplayContentRepositoryImpl @Inject constructor( private val atmService: IActivityTaskManager, private val systemUiProxy: SystemUiProxy, private val screenshotProxy: ScreenshotProxy, @Background private val background: CoroutineDispatcher, ) : DisplayContentRepository { Loading @@ -53,8 +53,8 @@ constructor( ): DisplayContentModel { return DisplayContentModel( displayId, SystemUiState(systemUiProxy.isNotificationShadeExpanded()), rootTasks SystemUiState(screenshotProxy.isNotificationShadeExpanded()), rootTasks, ) } } Loading
packages/SystemUI/AndroidManifest.xml +1 −1 Original line number Diff line number Diff line Loading @@ -459,7 +459,7 @@ android:label="@string/screenshot_scroll_label" android:finishOnTaskLaunch="true" /> <service android:name=".screenshot.ScreenshotProxyService" <service android:name=".screenshot.proxy.ScreenshotProxyService" android:permission="com.android.systemui.permission.SELF" android:exported="false" /> Loading
packages/SystemUI/multivalentTests/src/com/android/systemui/screenshot/ActionIntentExecutorTest.kt +4 −4 Original line number Diff line number Diff line Loading @@ -17,13 +17,13 @@ package com.android.systemui.screenshot import android.content.Intent import androidx.test.ext.junit.runners.AndroidJUnit4 import android.os.Process.myUserHandle import android.platform.test.annotations.EnableFlags import android.testing.TestableContext import androidx.test.ext.junit.runners.AndroidJUnit4 import com.android.systemui.Flags import com.android.systemui.SysuiTestCase import com.android.systemui.screenshot.proxy.SystemUiProxy import com.android.systemui.screenshot.proxy.ScreenshotProxy import com.android.systemui.settings.DisplayTracker import com.android.systemui.shared.system.ActivityManagerWrapper import com.android.systemui.statusbar.phone.CentralSurfaces Loading @@ -45,7 +45,7 @@ class ActionIntentExecutorTest : SysuiTestCase() { private val testableContext = TestableContext(mContext) private val activityManagerWrapper = mock<ActivityManagerWrapper>() private val systemUiProxy = mock<SystemUiProxy>() private val screenshotProxy = mock<ScreenshotProxy>() private val displayTracker = mock<DisplayTracker>() Loading @@ -55,7 +55,7 @@ class ActionIntentExecutorTest : SysuiTestCase() { activityManagerWrapper, testScope, mainDispatcher, systemUiProxy, screenshotProxy, displayTracker, ) Loading
packages/SystemUI/src/com/android/systemui/screenshot/ActionIntentExecutor.kt +4 −4 Original line number Diff line number Diff line Loading @@ -37,7 +37,7 @@ import com.android.systemui.Flags import com.android.systemui.dagger.SysUISingleton import com.android.systemui.dagger.qualifiers.Application import com.android.systemui.dagger.qualifiers.Main import com.android.systemui.screenshot.proxy.SystemUiProxy import com.android.systemui.screenshot.proxy.ScreenshotProxy import com.android.systemui.settings.DisplayTracker import com.android.systemui.shared.system.ActivityManagerWrapper import com.android.systemui.statusbar.phone.CentralSurfaces Loading @@ -55,7 +55,7 @@ constructor( private val activityManagerWrapper: ActivityManagerWrapper, @Application private val applicationScope: CoroutineScope, @Main private val mainDispatcher: CoroutineDispatcher, private val systemUiProxy: SystemUiProxy, private val screenshotProxy: ScreenshotProxy, private val displayTracker: DisplayTracker, ) { /** Loading Loading @@ -89,7 +89,7 @@ constructor( CentralSurfaces.SYSTEM_DIALOG_REASON_SCREENSHOT ) } systemUiProxy.dismissKeyguard() screenshotProxy.dismissKeyguard() var transitionOptions: ActivityOptions? = null if (transitionCoordinator?.decor?.isAttachedToWindow == true) { transitionCoordinator.startExit() Loading Loading @@ -127,7 +127,7 @@ constructor( private suspend fun launchCrossProfileIntent( user: UserHandle, intent: Intent, bundle: Bundle? bundle: Bundle?, ) { val connector = getCrossProfileConnector(user) val completion = CompletableDeferred<Unit>() Loading
packages/SystemUI/src/com/android/systemui/screenshot/dagger/ScreenshotModule.java +2 −2 Original line number Diff line number Diff line Loading @@ -38,7 +38,7 @@ import com.android.systemui.screenshot.appclips.AppClipsScreenshotHelperService; import com.android.systemui.screenshot.appclips.AppClipsService; import com.android.systemui.screenshot.message.MessageModule; import com.android.systemui.screenshot.policy.ScreenshotPolicyModule; import com.android.systemui.screenshot.proxy.SystemUiProxyModule; import com.android.systemui.screenshot.proxy.ScreenshotProxyModule; import com.android.systemui.screenshot.ui.viewmodel.ScreenshotViewModel; import dagger.Binds; Loading @@ -50,7 +50,7 @@ import dagger.multibindings.IntoMap; /** * Defines injectable resources for Screenshots */ @Module(includes = {ScreenshotPolicyModule.class, SystemUiProxyModule.class, MessageModule.class}) @Module(includes = {ScreenshotPolicyModule.class, ScreenshotProxyModule.class, MessageModule.class}) public abstract class ScreenshotModule { @Binds Loading
packages/SystemUI/src/com/android/systemui/screenshot/data/repository/DisplayContentRepositoryImpl.kt +5 −5 Original line number Diff line number Diff line Loading @@ -22,21 +22,21 @@ import android.app.IActivityTaskManager import com.android.systemui.dagger.qualifiers.Background import com.android.systemui.screenshot.data.model.DisplayContentModel import com.android.systemui.screenshot.data.model.SystemUiState import com.android.systemui.screenshot.proxy.SystemUiProxy import com.android.systemui.screenshot.proxy.ScreenshotProxy import javax.inject.Inject import kotlinx.coroutines.CoroutineDispatcher import kotlinx.coroutines.withContext /** * Implements DisplayTaskRepository using [IActivityTaskManager], along with [ProfileTypeRepository] * and [SystemUiProxy]. * and [ScreenshotProxy]. */ @SuppressLint("MissingPermission") class DisplayContentRepositoryImpl @Inject constructor( private val atmService: IActivityTaskManager, private val systemUiProxy: SystemUiProxy, private val screenshotProxy: ScreenshotProxy, @Background private val background: CoroutineDispatcher, ) : DisplayContentRepository { Loading @@ -53,8 +53,8 @@ constructor( ): DisplayContentModel { return DisplayContentModel( displayId, SystemUiState(systemUiProxy.isNotificationShadeExpanded()), rootTasks SystemUiState(screenshotProxy.isNotificationShadeExpanded()), rootTasks, ) } }