Android 某些手机上未显示图像资产(图标)
Android Image Assets (Icon) not Showing on Some Phones
我已将新的图像资产添加到我的构建中,在虚拟和物理设备上对其进行了测试,然后作为 Beta 版推送到 Play 商店。一切都在我这边检查,但我的一位测试人员说应用程序图标没有显示!?他使用的是 Google Pixel phone 运行 Android 8.0。有谁知道是什么原因造成的?
Android Oreo 需要几个版本的图标,您必须创建自适应图标
https://developer.android.com/guide/practices/ui_guidelines/icon_design_adaptive.html
1. Select app folder from your project
2. Select File → New → Image Asset
3. On "Foreground Layer" choose the path of your image and resize in order to get the proper aspect for the icon
4. On “Background Layer" use the provided background color
5. Click on Finish and mipmap icons are created in different sizes
In your manifest file do the following changes
<application
...
android:icon="@mipmap/ic_launcher"
android:roundIcon="@mipmap/ic_launcher_round"
...>
</application>
我已将新的图像资产添加到我的构建中,在虚拟和物理设备上对其进行了测试,然后作为 Beta 版推送到 Play 商店。一切都在我这边检查,但我的一位测试人员说应用程序图标没有显示!?他使用的是 Google Pixel phone 运行 Android 8.0。有谁知道是什么原因造成的?
Android Oreo 需要几个版本的图标,您必须创建自适应图标 https://developer.android.com/guide/practices/ui_guidelines/icon_design_adaptive.html
1. Select app folder from your project
2. Select File → New → Image Asset
3. On "Foreground Layer" choose the path of your image and resize in order to get the proper aspect for the icon
4. On “Background Layer" use the provided background color
5. Click on Finish and mipmap icons are created in different sizes
In your manifest file do the following changes
<application
...
android:icon="@mipmap/ic_launcher"
android:roundIcon="@mipmap/ic_launcher_round"
...>
</application>