0

I want to know the way to set the application name different at the time of launcher and at the time of browser sharing list by share . I know sharing functionality takes place by intent filter, but I am not able to set the name different. I want my application name on the name of main activity (e.g "Info Store") but name of application in browser sharing list custom(e.g in Share Via dialog "Add to your Info"). Currently I am getting "Info Store" at both place"

Here is my mainfest code

 <activity
        android:name=".views.activities.InfoStoreActivity"
        android:label="@string/title_activity_infostore" 
         >
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />

            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
       <intent-filter>
         <action android:name="android.intent.action.SEND" />
         <category android:name="android.intent.category.DEFAULT" / >
          <data android:mimeType="*/*" />
      </intent-filter>


    </activity>
kirti Hudda
  • 304
  • 3
  • 17

2 Answers2

1

Try adding android:label to your <intent-filter> for ACTION_SEND, with your alternative caption.

CommonsWare
  • 986,068
  • 189
  • 2,389
  • 2,491
  • how can we declare label in ? I think android:label is the property of activity not of intent-filter. – kirti Hudda Nov 12 '14 at 12:38
  • @kirtiHudda: Please click on the link in my answer, where I link to the documentation showing the `android:label` attribute on ``. – CommonsWare Nov 12 '14 at 12:42
0

with the help of @commonsWare, I am going to post complete code of my manifest file. It might help to others.

      <activity
        android:name=.views.activities.InfoStoreActivity"
            android:theme="@style/Theme.AppCompat"  

             >
         <intent-filter
             android:label="Add to Item Info"
             android:icon="@drawable/info_icon">
            <action android:name="android.intent.action.SEND" />

            <category android:name="android.intent.category.DEFAULT" >
            </category>

            <data android:mimeType="*/*" />
        </intent-filter>

    </activity>
kirti Hudda
  • 304
  • 3
  • 17