I have one activity and three intet filters, each with different label set on, (AndroidManifiest.xml below)
<activity android:name=".activities.RecordActivity">
<intent-filter>
<category android:name="android.intent.category.DEFAULT" />
<action android:name="com.keitai.enigma.OPEN_RECORD" />
</intent-filter>
<intent-filter android:label="@string/newRecord">
<category android:name="android.intent.category.DEFAULT" />
<action android:name="com.keitai.enigma.NEW_RECORD" />
</intent-filter>
<intent-filter android:label="@string/editRecord">
<category android:name="android.intent.category.DEFAULT" />
<action android:name="com.keitai.enigma.EDIT_RECORD" />
</intent-filter>
</activity>
But activity title is not changing to label set in intent filter 🙁 Activity always contains application label.
What I’m donig wrong?
Are you sure you don’t have code that is setting the title explicitly?
Are you sure that the
OPEN_RECORDintent isn’t the one being triggered every time?Have you tried debugging by making sure everything has a distinct label (application, activity, each intent-filter) and seeing what happens?
I agree with you that what you expected to happen is what the docs say should happen. But it seems like the default
<application>label is being used regardless. I’m afraid if one of the above ideas doesn’t help, then I’m out of ideas. I might try it myself later on my system to see if it happens for me.http://developer.android.com/guide/topics/manifest/intent-filter-element.html#label
http://developer.android.com/guide/topics/manifest/manifest-intro.html#iconlabel