fix(android): make the new launcher icon actually display (adaptive icon + roundIcon) #74

Merged
sirius merged 2 commits from wt/app-icon-adaptive into main 2026-09-15 02:31:22 +00:00
Owner

Why the new icon never showed up

The icon change landed as a bitmap in res/mipmap-anydpi-v26/ wired to android:icon only, and shipped that way in v0.1.0 / v0.2.0 / v0.2.1:

  • android:roundIcon still pointed at @mipmap/ic_launcher -- the old vector adaptive icon. Pixel Launcher, Samsung One UI and MIUI prefer roundIcon over icon, so they kept rendering the old art. Confirmed on the ow35 emulator app drawer (old cyan/green line-art onion) while the APK's android:icon was already the new PNG.
  • A bitmap under mipmap-anydpi-v26 is a legacy icon, not an adaptive icon: no mask-safe zone, launcher-generated plate, not density-aware.

Fix

  • drawable-nodpi/onionwire_app_icon.png: the artwork squared to 432x432 with the logo at 62% of the canvas (inside the 66dp/108dp adaptive-icon safe zone) over a seamless blurred backdrop of itself.
  • mipmap-anydpi-v26/ic_launcher.xml + ic_launcher_round.xml: adaptive icons, the bitmap as the background layer, transparent foreground.
  • Manifest: icon=@mipmap/ic_launcher, roundIcon=@mipmap/ic_launcher_round.
  • Retired the dead vectors (ic_launcher_background/foreground.xml) and the misplaced mipmap-anydpi-v26/onionwire_app_icon.png.

Verification

  • :app:assembleDebug (x86_64) and :app:assembleRelease (arm64-v8a) both green locally.
  • Release APK: application-icon = the adaptive XML at every density; icon / roundIcon resolve to res/BW.xml / res/0K.xml, both referencing drawable/onionwire_app_icon; the bitmaps inside the APK are pixel-identical (RMSE 0) to the source art.
  • Installed the release APK on the ow35 emulator: the launcher drawer now shows the new artwork.
## Why the new icon never showed up The icon change landed as a bitmap in `res/mipmap-anydpi-v26/` wired to `android:icon` only, and shipped that way in v0.1.0 / v0.2.0 / v0.2.1: - `android:roundIcon` still pointed at `@mipmap/ic_launcher` -- the **old** vector adaptive icon. Pixel Launcher, Samsung One UI and MIUI prefer `roundIcon` over `icon`, so they kept rendering the old art. Confirmed on the `ow35` emulator app drawer (old cyan/green line-art onion) while the APK's `android:icon` was already the new PNG. - A bitmap under `mipmap-anydpi-v26` is a **legacy** icon, not an adaptive icon: no mask-safe zone, launcher-generated plate, not density-aware. ## Fix - `drawable-nodpi/onionwire_app_icon.png`: the artwork squared to 432x432 with the logo at 62% of the canvas (inside the 66dp/108dp adaptive-icon safe zone) over a seamless blurred backdrop of itself. - `mipmap-anydpi-v26/ic_launcher.xml` + `ic_launcher_round.xml`: adaptive icons, the bitmap as the background layer, transparent foreground. - Manifest: `icon=@mipmap/ic_launcher`, `roundIcon=@mipmap/ic_launcher_round`. - Retired the dead vectors (`ic_launcher_background/foreground.xml`) and the misplaced `mipmap-anydpi-v26/onionwire_app_icon.png`. ## Verification - `:app:assembleDebug` (x86_64) and `:app:assembleRelease` (arm64-v8a) both green locally. - Release APK: `application-icon` = the adaptive XML at every density; `icon` / `roundIcon` resolve to `res/BW.xml` / `res/0K.xml`, both referencing `drawable/onionwire_app_icon`; the bitmaps inside the APK are pixel-identical (RMSE 0) to the source art. - Installed the release APK on the `ow35` emulator: the launcher drawer now shows the new artwork.
The icon change landed as a bitmap dropped straight into
res/mipmap-anydpi-v26/ and wired to android:icon only, so the installed app
kept showing the old art:

- android:roundIcon still pointed at @mipmap/ic_launcher (the old vector
  adaptive icon). Launchers that prefer roundIcon — Pixel Launcher, Samsung
  One UI — render it in preference to android:icon, so the new bitmap never
  appeared. Verified on the ow35 emulator drawer: old cyan/green line-art
  onion while android:icon was already the new PNG.
- a bitmap under mipmap-anydpi-v26 is a legacy icon, not an adaptive one: the
  launcher pads it into the mask itself and it is not density-aware.

Now:
- drawable-nodpi/onionwire_app_icon.png: the artwork squared to 432x432 with
  the logo at 62% of the canvas (inside the 66dp/108dp safe zone) over a
  seamless blurred backdrop of itself, so no launcher mask clips the logo.
- mipmap-anydpi-v26/ic_launcher.xml and ic_launcher_round.xml: adaptive icons
  with that bitmap as the background layer and a transparent foreground.
- AndroidManifest.xml: icon=@mipmap/ic_launcher, roundIcon=@mipmap/ic_launcher_round.
- Delete the retired vectors (ic_launcher_background/foreground.xml) and the
  misplaced mipmap-anydpi-v26/onionwire_app_icon.png.
Merge branch 'main' into wt/app-icon-adaptive
All checks were successful
ci / test (pull_request) Successful in 4m19s
ci / sdk (pull_request) Successful in 1m14s
android-ci / android (pull_request) Successful in 8m19s
6f69d629fb
sirius merged commit 3dc52edc71 into main 2026-09-15 02:31:22 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
sirius/onionwire!74
No description provided.