把android studio工程中mipmap修改成drawable后出现ic_launcher冲突的解决方法

  • 将所有的mipmap修改成drawable
  • 修改Manifest.xml中的
1
2
<!--android:icon="@mipmap/ic_launcher"-->
android:icon="@drawable/ic_ls"
  • 在Manifest.xml的application区段增加如下内容:
1
tools:replace="android:icon"
  • 在Manifest.xml头部manifest标签增加如下内容:
1
xmlns:tools="http://schemas.android.com/tools"
  • 重新编译。