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

Commit 49e98eb5 authored by Rhed Jao's avatar Rhed Jao Committed by Automerger Merge Worker
Browse files

Merge "Using internal user manager for the lock state checking" into sc-dev am: e3f114e7

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14048287

Change-Id: If7b155d1458f751ccefe0dbee808303f34852cf3
parents fb9c11c7 e3f114e7
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -4217,8 +4217,9 @@ public class PackageManagerService extends IPackageManager.Stub
                // aware/unaware components they want to see, so fall through and
                // give them what they want
            } else {
                final UserManagerInternal umInternal = mInjector.getUserManagerInternal();
                // Caller expressed no opinion, so match based on user state
                if (mUserManager.isUserUnlockingOrUnlocked(userId)) {
                if (umInternal.isUserUnlockingOrUnlocked(userId)) {
                    flags |= PackageManager.MATCH_DIRECT_BOOT_AWARE | MATCH_DIRECT_BOOT_UNAWARE;
                } else {
                    flags |= PackageManager.MATCH_DIRECT_BOOT_AWARE;
@@ -15242,7 +15243,8 @@ public class PackageManagerService extends IPackageManager.Stub
                    userId);
            // Deliver BOOT_COMPLETED only if user is unlocked
            if (mUserManager.isUserUnlockingOrUnlocked(userId)) {
            final UserManagerInternal umInternal = mInjector.getUserManagerInternal();
            if (umInternal.isUserUnlockingOrUnlocked(userId)) {
                Intent bcIntent = new Intent(Intent.ACTION_BOOT_COMPLETED).setPackage(packageName);
                if (includeStopped) {
                    bcIntent.addFlags(Intent.FLAG_INCLUDE_STOPPED_PACKAGES);