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

Commit 05df1ab8 authored by Alex Stetson's avatar Alex Stetson Committed by Android (Google) Code Review
Browse files

Merge "Only call IStatusBarService from foreground user" into main

parents e1a4326f 1217cba8
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -1621,8 +1621,10 @@ class ActivityStarter {
                    currentTop, currentTop.mDisplayContent, false /* deferResume */);
        }

        if (!avoidMoveToFront() && mDoResume && mRootWindowContainer
                .hasVisibleWindowAboveButDoesNotOwnNotificationShade(started.launchedFromUid)) {
        if (!avoidMoveToFront() && mDoResume
                && !mService.getUserManagerInternal().isVisibleBackgroundFullUser(started.mUserId)
                && mRootWindowContainer.hasVisibleWindowAboveButDoesNotOwnNotificationShade(
                started.launchedFromUid)) {
            // If the UID launching the activity has a visible window on top of the notification
            // shade and it's launching an activity that's going to be at the front, we should move
            // the shade out of the way so the user can see it. We want to avoid the case where the
+9 −0
Original line number Diff line number Diff line
@@ -283,6 +283,7 @@ import com.android.server.am.PendingIntentRecord;
import com.android.server.am.UserState;
import com.android.server.firewall.IntentFirewall;
import com.android.server.grammaticalinflection.GrammaticalInflectionManagerInternal;
import com.android.server.pm.UserManagerInternal;
import com.android.server.pm.UserManagerService;
import com.android.server.policy.PermissionPolicyInternal;
import com.android.server.sdksandbox.SdkSandboxManagerLocal;
@@ -382,6 +383,7 @@ public class ActivityTaskManagerService extends IActivityTaskManager.Stub {
    private PermissionPolicyInternal mPermissionPolicyInternal;
    private StatusBarManagerInternal mStatusBarManagerInternal;
    private WallpaperManagerInternal mWallpaperManagerInternal;
    private UserManagerInternal mUserManagerInternal;
    @VisibleForTesting
    final ActivityTaskManagerInternal mInternal;
    private PowerManagerInternal mPowerManagerInternal;
@@ -5464,6 +5466,13 @@ public class ActivityTaskManagerService extends IActivityTaskManager.Stub {
        return mWallpaperManagerInternal;
    }

    UserManagerInternal getUserManagerInternal() {
        if (mUserManagerInternal == null) {
            mUserManagerInternal = LocalServices.getService(UserManagerInternal.class);
        }
        return mUserManagerInternal;
    }

    AppWarnings getAppWarningsLocked() {
        return mAppWarnings;
    }