All apps should have an adaptive icon. If you are not familiar with these icons then start here: Adaptive Icons
Instruction steps:
Example: https://github.com/AnywhereSoftware/B4X-Pleroma/tree/master/B4A
Instruction steps:
- Create a new folder in the root project folder named icon.
- Create two folders inside that folder with the following files:
- mipmap:
- ic_launcher.png - non-adaptive icon for Android 7- devices. There is no specific size. Should be 128x128 or or more.
- background.png - 108x108 - the solid background layer.
- foreground.png - 108x108 - the foreground layer.
- mipmap-xxxhdpi (high resolution images):
- background.png - 432x432 - solid background layer
- foreground.png - 432x432 - foreground layer
- mipmap:
- Add to main module:
B4X:#AdditionalRes: ../icon
- Add to manifest editor:
B4X:SetApplicationAttribute(android:icon, "@mipmap/ic_launcher") CreateResource(mipmap-anydpi-v26, ic_launcher.xml, <adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android"> <background android:drawable="@mipmap/background"/> <foreground android:drawable="@mipmap/foreground"/> </adaptive-icon> )
Example: https://github.com/AnywhereSoftware/B4X-Pleroma/tree/master/B4A
Last edited: