Android - 我自己的应用在已安装应用程序部分显示包名而不是应用程序名称

3
我创建了一个小的拼图应用程序。我将android:label设置为Math。在菜单网格中安装应用程序后,它显示为“Math”,但在已安装的应用程序部分中,它显示包名称。请帮助我解决问题。 清单代码
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="com.tam.prasanth.MathFunDemo" >

    <uses-permission android:name="android.permission.INTERNET" />
    <application
        android:allowBackup="true"
        android:icon="@drawable/logo"
        android:supportsRtl="true"
        android:theme="@style/AppTheme" >
        <activity
            android:name=".MainActivity"
            android:label="@string/app_name"
            android:theme="@style/AppTheme.NoActionBar" >
            <intent-filter >
                <action android:name="android.intent.action.MAIN" />

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

在Strings.xml文件中,字符串"@string/app_name"的值是什么? - Andrey E
"Math Fun" 是该值。 - Sathya Apps
2个回答

8
应用程序名称(标签)应该在application标签中,而不是activity标签中。
<application 
android:label="@string/app_name"
>
....

非常顺利!非常感谢!:) :) - Sathya Apps

0
请在标签中指定android:label="@string/app_name"属性,并在string.xml文件中将app_name属性的值设置为您的应用程序名称(Math)。

谢谢你的解决方案! :) - Sathya Apps

网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接