开发者

Multiple program shortcuts from one application

In my application I have a number of Activity classes. When I run on e开发者_Go百科mulator (or install to a device) a corresponding number of program shortcuts show up in the programs menu. Why does this happen and how can I avoid it? Many thanks.


I think you have added LAUNCHER attribute in every activity...so multiple shortcuts showing up in your program menu.

But, There should(mostly) only one "LAUNCHER" activity....
Do like Following:

    <activity android:name=".Testing"
              android:label="Showing Testing">
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />
            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>

    <activity android:name=".Activity1"
              android:label="@string/Activity1">
    </activity>

    <activity android:name=".Activity2"
              android:label="@string/Activity2">
    </activity>
    <activity android:name=".Activity3"
              android:label="@string/Activity3">

    </activity>

</application>


I think you need to look in your manifest file. I believe that is where the intents are defined.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜