Android Studio 运行Android Emulator不会给予任何结果

9q78igpj  于 8个月前  发布在  Android
关注(0)|答案(1)|浏览(81)

我有一个问题,老实说,我不明白我做错了什么。每次我尝试在Android Emulator中运行我的布局时,它都会显示手机本身的主菜单。
我试图在AndroidManifest.xml中编辑代码,但它不起作用,我改变了设备,冷启动,重新启动应用程序并删除模拟器,没有一个工作。
AndroidManifest.xml

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools">

    <application
        android:allowBackup="true"
        android:dataExtractionRules="@xml/data_extraction_rules"
        android:fullBackupContent="@xml/backup_rules"
        android:icon="@mipmap/ic_launcher"
        android:label="@string/app_name"
        android:roundIcon="@mipmap/ic_launcher_round"
        android:supportsRtl="true"
        android:theme="@style/Theme.TATTOFOUNDLER"
        tools:targetApi="31">
        <activity
            android:theme="@style/LoginPage"
            android:windowSoftInputMode="adjustResize"
            android:name=".LoginActivity"
            android:exported="true">
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />

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

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

                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>
    </application>

</manifest>
5us2dqdw

5us2dqdw1#

<?xml version="1.0" encoding="utf-8"?>
 <manifest xmlns:android="http://schemas.android.com/apk/res/android"
 xmlns:tools="http://schemas.android.com/tools">
<application
    android:allowBackup="true"
    android:dataExtractionRules="@xml/data_extraction_rules"
    android:fullBackupContent="@xml/backup_rules"
    android:icon="@mipmap/ic_launcher"
    android:label="@string/app_name"
    android:roundIcon="@mipmap/ic_launcher_round"
    android:supportsRtl="true"
    android:theme="@style/Theme.TATTOFOUNDLER"
    tools:targetApi="31">
    <activity
        android:theme="@style/LoginPage"
        android:windowSoftInputMode="adjustResize"
        android:name=".LoginActivity"
        android:exported="false">
    </activity>
    <activity
        android:name=".RegisterActivity"
        android:exported="false">
    </activity>
    <activity
        android:name=".LoginActivity"
        android:exported="true">
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />
        <category android:name="android.intent.category.LAUNCHER"/>
        </intent-filter>
        </activity>
       </application>

     </manifest>

相关问题