Android应用程序没有启动图标应用程序、图标、Android

由网友(我叫好坚强i)分享简介:我已经把一个简单的应用程序,当我安装的应用程序的图标显示,但一旦它的安装也没有启动图标。这是我的Andr​​oidManifest.xml:I have put together a simple application and when I am installing the app the icon displ...

我已经把一个简单的应用程序,当我安装的应用程序的图标显示,但一旦它的安装也没有启动图标。 这是我的Andr​​oidManifest.xml:

I have put together a simple application and when I am installing the app the icon displays but once it's installed there is no launch icon. Here is my AndroidManifest.xml:

<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.SiteTools.convertme"
android:versionCode="1"
android:versionName="1.0" >

<uses-sdk
android:minSdkVersion="8"
android:targetSdkVersion="16" />

<application
android:allowBackup="true"
android:icon="@drawable/launch_icon"
android:label="@string/app_name"
android:theme="@style/AppTheme" >
</application>

</manifest>

我试图重新命名的图标,但它并没有帮助,我已经测试了两台设备,并没有得到启动图标。 我用eclipse。

I have tried renaming the icons but it hasn't helped, I have tested on two devices and neither get the launch icon. I use eclipse.

推荐答案

您需要添加一个意图过滤器,否则Android将不知道什么应用程序启动。此外,应用程序应该包括应用程序的名称。我已经包括以下为 someActivity 的名称,将其更改为你的应用程序适当。这可以通过更改您的应用程序如下进行:

You need to add an Intent Filter, or else Android won't know what application to launch. Also, your application should include the name of the app. I've included a name below as someActivity, change it to your app as appropriate. This can be done by changing your application to the following:

<application
android:allowBackup="true"
android:icon="@drawable/launch_icon"
android:label="@string/app_name"
android:theme="@style/AppTheme" >
    <activity 
        android:name="someActivity"
        android:label="@string/app_name" >
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />
            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>
</application>
阅读全文

相关推荐

最新文章