简体   繁体   中英

Cannot change launcher icon android

I am trying to change launcher icon for the application I am developing but the icon remains same (Android Studio 3.0). I have tried changing it from manifest.xml and minimap . It appears to be picking up icon from two XML files named as ic_launcher_background.xml and ic_launcher_forground.xml. I have tried deleting these files but safe delete is not allowing me to. I am attaching screenshot of my project. enter image description here

尝试将您的 ic_launcher_torch 图标移动到 mipmap 目录中

  1. Remove the ic_launcher_torch.png file from drawables folder.
  2. Right click on res folder> New Image Asset > Icon type > Action Bar and Tab Icons > Asset type - image > Choose your logo in path > finish.
  3. Add android:icon="@mipmap/yourLogoName"

The image will be saved in /res/drawable folder. Learn more: https://developer.android.com/studio/write/image-asset-studio.html

Copy & paste launcher icon .png file to mipmap folder. Better if you add icon to all screen types hdpi, mdpi, xhdpi & etc. Then change android manifest code like this.

android:icon="@mipmap/ic_launcher"
android:roundIcon="@mipmap/ic_launcher_round"

make changes in manifest file at both location android:icon="@mipmap/ic_launcher" android:roundIcon="@mipmap/ic_launcher_round"

First uninstall the app from the phone(dont reinstall when you already have it installed) After the app is uninstalled ,try installing it once again . I had the same issue ,wasted around 2 hrs and this worked for me

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM