Skip to content

Commit

Permalink
android/ui: add support for themeing launcher icon
Browse files Browse the repository at this point in the history
Updates tailscale/corp#19045

Signed-off-by: Percy Wegmann <percy@tailscale.com>
  • Loading branch information
oxtoacart committed Apr 11, 2024
1 parent d396fda commit a77edc6
Show file tree
Hide file tree
Showing 25 changed files with 39 additions and 33 deletions.
Binary file modified android/src/main/ic_launcher-playstore.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
66 changes: 34 additions & 32 deletions android/src/main/res/drawable/ic_launcher_foreground.xml
Original file line number Diff line number Diff line change
@@ -1,36 +1,38 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="108dp"
android:height="108dp"
android:viewportWidth="100"
android:viewportHeight="100">
<group android:translateX="20"
android:translateY="20">
<path
android:pathData="M15,30.0002m-5,0a5,5 0,1 1,10 0a5,5 0,1 1,-10 0"
android:fillColor="#FFFDFA"/>
<path
android:pathData="M30,30.0002m-5,0a5,5 0,1 1,10 0a5,5 0,1 1,-10 0"
android:fillColor="#FFFDFA"/>
<path
android:pathData="M15,45.0002m-5,0a5,5 0,1 1,10 0a5,5 0,1 1,-10 0"
android:fillColor="#54514D"/>
<path
android:pathData="M45,45.0002m-5,0a5,5 0,1 1,10 0a5,5 0,1 1,-10 0"
android:fillColor="#54514D"/>
<path
android:pathData="M30,45.0002m-5,0a5,5 0,1 1,10 0a5,5 0,1 1,-10 0"
android:fillColor="#FFFDFA"/>
<path
android:pathData="M45,30.0002m-5,0a5,5 0,1 1,10 0a5,5 0,1 1,-10 0"
android:fillColor="#FFFDFA"/>
<path
android:pathData="M15,15.0002m-5,0a5,5 0,1 1,10 0a5,5 0,1 1,-10 0"
android:fillColor="#54514D"/>
<path
android:pathData="M30,14.9999m-5,0a5,5 0,1 1,10 0a5,5 0,1 1,-10 0"
android:fillColor="#54514D"/>
<path
android:pathData="M45,14.9999m-5,0a5,5 0,1 1,10 0a5,5 0,1 1,-10 0"
android:fillColor="#54514D"/>
</group>
android:viewportWidth="108"
android:viewportHeight="108">
<path
android:pathData="M34.5,39.37a4.87,4.88 0,1 0,9.75 0a4.87,4.88 0,1 0,-9.75 0z"
android:fillColor="#ffffff"
android:fillAlpha="0.4"/>
<path
android:pathData="M49.13,39.37a4.87,4.88 0,1 0,9.75 0a4.87,4.88 0,1 0,-9.75 0z"
android:fillColor="#ffffff"
android:fillAlpha="0.4"/>
<path
android:pathData="M63.75,39.37a4.87,4.88 0,1 0,9.75 0a4.87,4.88 0,1 0,-9.75 0z"
android:fillColor="#ffffff"
android:fillAlpha="0.4"/>
<path
android:pathData="M34.5,54a4.87,4.88 0,1 0,9.75 0a4.87,4.88 0,1 0,-9.75 0z"
android:fillColor="#ffffff"/>
<path
android:pathData="M49.13,54a4.87,4.88 0,1 0,9.75 0a4.87,4.88 0,1 0,-9.75 0z"
android:fillColor="#ffffff"/>
<path
android:pathData="M63.75,54a4.87,4.88 0,1 0,9.75 0a4.87,4.88 0,1 0,-9.75 0z"
android:fillColor="#ffffff"/>
<path
android:pathData="M34.5,68.62a4.87,4.88 0,1 0,9.75 0a4.87,4.88 0,1 0,-9.75 0z"
android:fillColor="#ffffff"
android:fillAlpha="0.4"/>
<path
android:pathData="M49.13,68.62a4.87,4.88 0,1 0,9.75 0a4.87,4.88 0,1 0,-9.75 0z"
android:fillColor="#ffffff"/>
<path
android:pathData="M63.75,68.62a4.87,4.88 0,1 0,9.75 0a4.87,4.88 0,1 0,-9.75 0z"
android:fillColor="#ffffff"
android:fillAlpha="0.4"/>
</vector>
2 changes: 2 additions & 0 deletions android/src/main/res/mipmap-anydpi-v26/ic_launcher.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,6 @@
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@color/ic_launcher_background"/>
<foreground android:drawable="@drawable/ic_launcher_foreground"/>

<monochrome android:drawable="@drawable/ic_launcher_foreground" />
</adaptive-icon>
2 changes: 2 additions & 0 deletions android/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,6 @@
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@color/ic_launcher_background"/>
<foreground android:drawable="@drawable/ic_launcher_foreground"/>

<monochrome android:drawable="@drawable/ic_launcher_foreground" />
</adaptive-icon>
Binary file removed android/src/main/res/mipmap-hdpi/ic_launcher.png
Binary file not shown.
Binary file added android/src/main/res/mipmap-hdpi/ic_launcher.webp
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed android/src/main/res/mipmap-mdpi/ic_launcher.png
Binary file not shown.
Binary file added android/src/main/res/mipmap-mdpi/ic_launcher.webp
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed android/src/main/res/mipmap-xhdpi/ic_launcher.png
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed android/src/main/res/mipmap-xxhdpi/ic_launcher.png
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed android/src/main/res/mipmap-xxxhdpi/ic_launcher.png
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
2 changes: 1 addition & 1 deletion android/src/main/res/values/ic_launcher_background.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="ic_launcher_background">#1F2125</color>
<color name="ic_launcher_background">#1F1E1E</color>
</resources>

0 comments on commit a77edc6

Please sign in to comment.