commit
Updates
diff --git a/email/src/main/AndroidManifest.xml b/email/src/main/AndroidManifest.xml
index 72aa1cf..4f20965 100644
--- a/email/src/main/AndroidManifest.xml
+++ b/email/src/main/AndroidManifest.xml
@@ -37,6 +37,22 @@
android:name="android.support.customtabs.trusted.FALLBACK_STRATEGY"
android:value="customtabs" />
+ <!-- Splash: the icon on the app background until the page first
+ paints. The site's own splash starts on this exact frame
+ (128dp, centred) and animates from there. -->
+ <meta-data
+ android:name="android.support.customtabs.trusted.SPLASH_IMAGE_DRAWABLE"
+ android:resource="@drawable/splash" />
+ <meta-data
+ android:name="android.support.customtabs.trusted.SPLASH_SCREEN_BACKGROUND_COLOR"
+ android:resource="@color/background" />
+ <meta-data
+ android:name="android.support.customtabs.trusted.SPLASH_SCREEN_FADE_OUT_DURATION"
+ android:value="200" />
+ <meta-data
+ android:name="android.support.customtabs.trusted.FILE_PROVIDER_AUTHORITY"
+ android:value="gay.doughmination.mail.fileprovider" />
+
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
@@ -53,6 +69,17 @@
<activity android:name="com.google.androidbrowserhelper.trusted.FocusActivity" />
+ <!-- Hands the splash image to Chrome. -->
+ <provider
+ android:name="androidx.core.content.FileProvider"
+ android:authorities="gay.doughmination.mail.fileprovider"
+ android:exported="false"
+ android:grantUriPermissions="true">
+ <meta-data
+ android:name="android.support.FILE_PROVIDER_PATHS"
+ android:resource="@xml/filepaths" />
+ </provider>
+
<!-- Shows the Android 13+ notification permission prompt when the
site asks for it. Without it the request fails and nothing is
ever delivered. -->
diff --git a/email/src/main/res/drawable-hdpi/splash.png b/email/src/main/res/drawable-hdpi/splash.png
new file mode 100644
index 0000000..6e68d97
Binary files /dev/null and b/email/src/main/res/drawable-hdpi/splash.png differ
diff --git a/email/src/main/res/drawable-mdpi/splash.png b/email/src/main/res/drawable-mdpi/splash.png
new file mode 100644
index 0000000..b9d3c5d
Binary files /dev/null and b/email/src/main/res/drawable-mdpi/splash.png differ
diff --git a/email/src/main/res/drawable-xhdpi/splash.png b/email/src/main/res/drawable-xhdpi/splash.png
new file mode 100644
index 0000000..06b6320
Binary files /dev/null and b/email/src/main/res/drawable-xhdpi/splash.png differ
diff --git a/email/src/main/res/drawable-xxhdpi/splash.png b/email/src/main/res/drawable-xxhdpi/splash.png
new file mode 100644
index 0000000..6cfcea9
Binary files /dev/null and b/email/src/main/res/drawable-xxhdpi/splash.png differ
diff --git a/email/src/main/res/drawable-xxxhdpi/splash.png b/email/src/main/res/drawable-xxxhdpi/splash.png
new file mode 100644
index 0000000..0b7635e
Binary files /dev/null and b/email/src/main/res/drawable-xxxhdpi/splash.png differ
diff --git a/email/src/main/res/xml/filepaths.xml b/email/src/main/res/xml/filepaths.xml
new file mode 100644
index 0000000..6f99048
--- /dev/null
+++ b/email/src/main/res/xml/filepaths.xml
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- res/xml/filepaths.xml
+ Where the launcher drops the splash image for Chrome to pick up. -->
+<paths>
+ <files-path
+ name="twa_splash"
+ path="twa_splash/" />
+</paths>