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

Commit cf963dcd authored by Xiaohui Chen's avatar Xiaohui Chen
Browse files

sys user split: fix default HOME activity

Only enable default HOME activity after user setup is complete.
When setup is not complete, it should be handled by setup
wizard.

Bug: 28275485
Change-Id: Ibc907a7252331a7315d0b70eda64dfb65d6c4dfe
(cherry picked from commit f01d63b35065654f8186daaf719ddb3065946bfa)
parent aacc2834
Loading
Loading
Loading
Loading
+6 −2
Original line number Diff line number Diff line
@@ -12805,8 +12805,12 @@ public final class ActivityManagerService extends ActivityManagerNative
            // Start up initial activity.
            mBooting = true;
            // Enable home activity for system user, so that the system can always boot
            if (UserManager.isSplitSystemUser()) {
            // Enable home activity for system user, so that the system can always boot. We don't
            // do this when the system user is not setup since the setup wizard should be the one
            // to handle home activity in this case.
            if (UserManager.isSplitSystemUser() &&
                    Settings.Secure.getInt(mContext.getContentResolver(),
                         Settings.Secure.USER_SETUP_COMPLETE, 0) != 0) {
                ComponentName cName = new ComponentName(mContext, SystemUserHomeActivity.class);
                try {
                    AppGlobals.getPackageManager().setComponentEnabledSetting(cName,