dds dds - 9 months ago 72
Android Question

A lot of app icon in AVD

Hi I have an android application and it works fine in AVD. But I realized something, there are 6 icon in the menu of virtual device. When I uninstall the app with one of these icons, all icons remove. And each icon opens Main activity. There are 6 icon and I have 6 activity in my app. I am working in Android Studio.
How can I set only one application icon in device menu as normally it should be?
Thanks everyone.

I add a picture of avd menu with a lot of icons

enter image description here

Answer Source

If you have these following codes in inside all the activities in manifest file, just keep it in main activity and remove from all others.

    <action android:name="android.intent.action.MAIN" />
    <category android:name="android.intent.category.LAUNCHER" />

This lines will create a launcher icon for each activity.