Change DeepLinkHomepageActivity enable state for ACTION_USER_INITIALIZE

Each user has different components enable state,
should update enable state of DeepLinkHomepageActivity
for Intent#ACTION_USER_INITIALIZE.

Bug: 202364984
Test: manual
      Switch user -> long click Launcher -> Wallpaper & style
      See if it shows wallpaper app's Activity.
Change-Id: If50de0f017f5cd606ba0cbf88d41eeabf3f47506
This commit is contained in:
Arc Wang
2021-10-08 16:07:46 +08:00
parent d754409050
commit 3648d67201

View File

@@ -34,7 +34,6 @@ import android.content.pm.ShortcutManager;
import android.content.pm.UserInfo;
import android.os.UserHandle;
import android.os.UserManager;
import android.text.TextUtils;
import android.util.Log;
import androidx.annotation.VisibleForTesting;
@@ -150,10 +149,6 @@ public class SettingsInitialize extends BroadcastReceiver {
}
private void enableTwoPaneDeepLinkActivityIfNecessary(PackageManager pm, Intent intent) {
if (!TextUtils.equals(intent.getAction(), Intent.ACTION_PRE_BOOT_COMPLETED)) {
return;
}
final ComponentName deepLinkHome = new ComponentName(Utils.SETTINGS_PACKAGE_NAME,
SettingsHomepageActivity.ALIAS_DEEP_LINK);
final int enableState = SplitController.getInstance().isSplitSupported()