Splits out ACTION_MAIN intent filter for Settings and doesn't
forward it.
This is required so that general queries for ACTION_MAIN apps
do not get stuck with the IntentForwarderActivity.
Bug: 17053933
Change-Id: Ie04e2b29f2467e14fd82d27c1e94d93eda90f4c1
diff --git a/AndroidManifest.xml b/AndroidManifest.xml
index 58e7f70..4ddb679 100644
--- a/AndroidManifest.xml
+++ b/AndroidManifest.xml
@@ -86,15 +86,26 @@
android:label="@string/settings_label_launcher"
android:launchMode="singleTask">
<intent-filter>
- <action android:name="android.intent.action.MAIN" />
<action android:name="android.settings.SETTINGS" />
<category android:name="android.intent.category.DEFAULT" />
- <category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
<meta-data android:name="com.android.settings.PRIMARY_PROFILE_CONTROLLED"
android:value="true" />
</activity>
+ <!-- Alias for launcher activity only, as this belongs to each profile. -->
+ <activity-alias android:name="Settings"
+ android:taskAffinity="com.android.settings"
+ android:label="@string/settings_label_launcher"
+ android:launchMode="singleTask"
+ android:targetActivity="Settings">
+ <intent-filter>
+ <action android:name="android.intent.action.MAIN" />
+ <category android:name="android.intent.category.DEFAULT" />
+ <category android:name="android.intent.category.LAUNCHER" />
+ </intent-filter>
+ </activity-alias>
+
<receiver android:name="ManagedProfileSetup">
<intent-filter>
<action android:name="android.intent.action.USER_INITIALIZE"/>