android 安装后显示多个启动图标

android showing multiple launch icon after installed

拜托,我有一个 android 应用程序,其中包含超过 3 个 android activity,一切正常,直到我在 splashScreen activity 上添加了每次只会显示一次安装了应用程序或清除了数据。现在的问题是,当我安装应用程序时,我会在屏幕上看到两个午餐图标,这是不正常的。请任何人在下面帮助我是我的 activity 和它的使用。

SplashScreen: 应用安装完成后,里面包含webview。

SplashScreenOnload: 每次应用程序启动时,它会显示 500 毫秒并重定向到 ApplicationMainActivity,里面没有 webview。

ApplicationMainActivity:这是主应用 activity,它包含 webview。

UriSchemActivity:这是为了url方案提取,没有webview。

PopLoginActivity:这是 url 弹出窗口,在 ApplicationMainActivity 中单击的任何外部 url 都会在此处打开,它包含 webview

AndroidManifest.xml

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="com.example.android.shop"
    android:installLocation="auto">

    <supports-screens
        android:anyDensity="true"
        android:largeScreens="true"
        android:normalScreens="true"
        android:resizeable="true"
        android:smallScreens="true"
        android:xlargeScreens="true" />

    <application
        android:hardwareAccelerated="true"
        android:allowBackup="true"
        android:icon="@mipmap/ic_launcher"
        android:roundIcon="@mipmap/ic_launcher_round"
        android:label="@string/app_name"
        android:supportsRtl="true"
        android:theme="@style/AppTheme">
        <activity
            android:name=".SplashScreen"
            android:label="@string/app_name"
            android:launchMode="singleTask"
            android:screenOrientation="sensorPortrait">
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>

        <activity
            android:name=".SplashScreenOnload"
            android:label="@string/app_name"
            android:launchMode="singleTask"
            android:screenOrientation="sensorPortrait">
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>

        <activity
            android:name=".ApplicationMainActivity"
            android:label="@string/app_name"
            android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize"
            android:screenOrientation="sensorPortrait">
            <intent-filter>
                <category android:name="android.intent.category.DEFAULT" />
                <category android:name="android.intent.category.BROWSABLE" />
            </intent-filter>
        </activity>

        <activity android:name=".UriSchemActivity"
            android:screenOrientation="sensorPortrait">
            <intent-filter>
                <action android:name="android.intent.action.VIEW" />
                <category android:name="android.intent.category.DEFAULT" />
                <category android:name="android.intent.category.BROWSABLE" />

                <data android:scheme="http" />
                <data android:scheme="https" />
                <data android:scheme="example" />
                <data android:scheme="fs" />
                <data android:host="www. example.com" />
                <data android:host="example.com" />
                <data android:pathPrefix="/app/www/" />
                <data android:pathPrefix="/app/" />
                <data android:pathPattern=".*" />
            </intent-filter>
        </activity>

        <activity
            android:name=".PopLoginActivity"
            android:screenOrientation="sensorPortrait"
            android:theme="@style/Theme.Transparent" />

        <service android:name=".FcmMessagingService">
            <intent-filter>
                <action android:name="com.google.firebase.MESSAGING_EVENT" />
            </intent-filter>
        </service>

        <meta-data
            android:name="com.google.android.gms.version"
            android:value="@integer/google_play_services_version" />
        <meta-data
            android:name="com.facebook.sdk.ApplicationId"
            android:value="@string/facebook_app_id" />
    </application>

</manifest>

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

在很多地方都会引起您的问题!

您需要选择一个启动器Activity