Android 应用程序未在模拟器中启动

man*_*urt 0 android android-emulator

我在台式机上有一个 Eclipse 工作正常,但最近在一台带有 2.4 Ghz inter core 2 duo 的旧笔记本电脑上安装时,我遇到了一些问题。

当测试 Android 应用程序并运行模拟器时,它会启动,但在完成加载后,会以锁定屏幕启动。然后我解锁它并返回主页,但我找不到该应用程序的位置,因为它不在应用程序菜单中。所以我认为没有加载应用程序?

控制台消息:

[2011-12-11 22:13:58 - ha] ------------------------------
[2011-12-11 22:13:58 - ha] Android Launch!
[2011-12-11 22:13:58 - ha] adb is running normally.
[2011-12-11 22:13:58 - ha] No Launcher activity found!
[2011-12-11 22:13:58 - ha] The launch will only sync the application package on the device!
[2011-12-11 22:13:58 - ha] Performing sync
[2011-12-11 22:13:58 - ha] Automatic Target Mode: launching new emulator with compatible AVD '40'
[2011-12-11 22:13:58 - ha] Launching a new emulator with Virtual Device '40'
[2011-12-11 22:14:08 - Emulator] 2011-12-11 22:14:08.267 emulator-arm[2180:80b] Warning once: This application, or a library it uses, is using NSQuickDrawView, which has been deprecated. Apps should cease use of QuickDraw and move to Quartz.
[2011-12-11 22:14:08 - ha] New emulator found: emulator-5554
[2011-12-11 22:14:08 - ha] Waiting for HOME ('android.process.acore') to be launched...
[2011-12-11 22:15:00 - ha] HOME is up on device 'emulator-5554'
[2011-12-11 22:15:00 - ha] Uploading ha.apk onto device 'emulator-5554'
[2011-12-11 22:15:01 - ha] Installing ha.apk...
Run Code Online (Sandbox Code Playgroud)

请问如何解决这个问题?

Mar*_*era 5

注意这条线

[2011-12-11 22:13:58 - ha] No Launcher activity found!
Run Code Online (Sandbox Code Playgroud)

它表示没有将 Intent-Filter 活动指定为应用程序的 MAIN 和 LAUNCHER 活动

AndroidManifest.xml应该看起来像这样:

<activity
    android:name=".NameOfMainActivity">
    <intent-filter >
        <action android:name="android.intent.action.MAIN" />
        <category android:name="android.intent.category.LAUNCHER" />
    </intent-filter>
</activity>
Run Code Online (Sandbox Code Playgroud)

在这里阅读更多内容: