1

hi i am new in android application Development

after successfully Developed android application when i install apk of that application it is always under launcher list, and always ask to select default launcher when i press Home key. How to prevent app. to be in list under launcher.

manifest file code are as follow.

//Manifest
<application
    android:allowBackup="true"
    android:icon="@drawable/ic_launcher"
    android:label="@string/app_name"
    android:theme="@style/AppTheme" >
    <activity
        android:name="com.example.dewebclient.MainActivity"
        android:label="@string/app_name" >
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />
            <category android:name="android.intent.category.HOME" />
            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>
    <activity android:name="com.example.dewebclient.IpConfigure" ></activity>
    <activity android:name="com.example.dewebclient.WebViewClientDE"  />
      <!--android:theme="@android:style/Theme.NoTitleBar"-->
</application>

4 Answers4

1

Remove below line from your AndroidManifest.xml file.

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

Explanation :

The category HOME is used to declare your application as a Home launcher. By putting this in the AndroidManifest.xml, user will have the option to have your application open upon pressing the home button.

According to Developer Docs. This is the home activity, that is the first activity that is displayed when the device boots.

Chirag Savsani
  • 6,020
  • 4
  • 38
  • 74
0
<category android:name="android.intent.category.HOME"/>

Remove this and check.

This indicates that when you press home button, your app will be listed as an option to launch the launcher home or your home activity (along with all the applications which have this category in their manifest for an activity). To be more simple, whenever you press the home button, all the applications installed in your phone which have CATEGORY.HOME category and Action_Main in intent-filter in their AndroidManifest.xml will be listed (unless you have chosen some application as default) in a chooser for the user to select which HOME they want to launch.

Zumry Mohamed
  • 9,318
  • 5
  • 46
  • 51
0

change your intent filter look like below. and relaunch application.

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

referenc this link

Community
  • 1
  • 1
Vishal Patel
  • 2,931
  • 3
  • 24
  • 60
0
<category android:name="android.intent.category.HOME" />

Remove above line from AndroidManifest.xml .

Suhas Bachewar
  • 1,230
  • 7
  • 21