Skip to content

Commit d58ee4b

Browse files
SUPERCILEXsamtstern
authored andcommitted
Add adaptive icons! (#851)
1 parent e91edda commit d58ee4b

21 files changed

+15
-22
lines changed

app/src/main/AndroidManifest.xml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,8 @@
1212
android:label="@string/app_name"
1313
android:allowBackup="true"
1414
android:fullBackupContent="true"
15-
android:icon="@drawable/ic_launcher"
15+
android:icon="@mipmap/ic_launcher"
16+
android:roundIcon="@mipmap/ic_launcher_round"
1617
android:supportsRtl="true"
1718
android:theme="@style/AppTheme"
1819
tools:ignore="GoogleAppIndexingWarning">

app/src/main/res/drawable/ic_launcher.xml

Lines changed: 0 additions & 19 deletions
This file was deleted.
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
3+
<background android:drawable="@android:color/white"/>
4+
<foreground android:drawable="@mipmap/ic_launcher_foreground"/>
5+
</adaptive-icon>
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
3+
<background android:drawable="@android:color/white"/>
4+
<foreground android:drawable="@mipmap/ic_launcher_foreground"/>
5+
</adaptive-icon>
1.73 KB
Loading
Loading
Loading
1.18 KB
Loading
Loading
Loading
2.31 KB
Loading
Loading
Loading
3.77 KB
Loading
Loading
Loading
5.22 KB
Loading
Loading
Loading

app/src/main/res/xml-v25/shortcuts.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<shortcut
44
android:shortcutId="storage"
55
android:enabled="true"
6-
android:icon="@drawable/ic_launcher"
6+
android:icon="@mipmap/ic_launcher"
77
android:shortcutShortLabel="@string/name_image">
88
<intent
99
android:action="android.intent.action.VIEW"
@@ -25,7 +25,7 @@
2525
<shortcut
2626
android:shortcutId="database"
2727
android:enabled="true"
28-
android:icon="@drawable/ic_launcher"
28+
android:icon="@mipmap/ic_launcher"
2929
android:shortcutShortLabel="@string/name_chat">
3030
<intent
3131
android:action="android.intent.action.VIEW"

library/quality/quality.gradle

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,7 @@ android {
7777
// using Java 8 nio packages. Safely downgrading them to warning.
7878
// https://github.com/square/okio/issues/58
7979
disable 'InvalidPackage',
80+
'IconLauncherFormat', 'IconExpectedSize', // TODO remove with 3.0 Gradle Plugin
8081
'NewerVersionAvailable', 'GradleDependency' // For reproducible builds
8182

8283
baseline file("$configDir/lint-baseline.xml")

0 commit comments

Comments
 (0)