Skip to content

Commit 3bf7051

Browse files
authored
Update: support android version 14 (#42)
* update: android version 32 -> 34 * fix: storage permission for android 13 * fix: double splash screen in android 12 or later I disable the default splash screen but we should consider migrating to SplashScreen API * update: android version 32 -> 34 - fix double splash screen in android 12 or later I disable the default splash screen but we should consider migrating to SplashScreen API - add media permission for android 13 or later
1 parent 4fa74ef commit 3bf7051

File tree

3 files changed

+11
-3
lines changed

3 files changed

+11
-3
lines changed

app/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,12 @@ plugins {
88

99
android {
1010
namespace 'com.example.cyclofit'
11-
compileSdk 32
11+
compileSdk 34
1212

1313
defaultConfig {
1414
applicationId "com.example.cyclofit"
1515
minSdk 23
16-
targetSdk 32
16+
targetSdk 34
1717
versionCode 1
1818
versionName "1.0"
1919

app/src/main/AndroidManifest.xml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,9 @@
22
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
33
xmlns:tools="http://schemas.android.com/tools">
44

5-
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
5+
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"
6+
android:maxSdkVersion="32" />
7+
<uses-permission android:name="android.permission.READ_MEDIA_IMAGES"/>
68
<uses-permission android:name="android.permission.INTERNET"/>
79

810
<application
@@ -50,6 +52,7 @@
5052
<activity android:name=".ui.activities.DashboardActivity" />
5153
<activity
5254
android:name=".ui.activities.SplashScreen"
55+
android:theme="@style/Theme.RemoveSplashScreenTheme"
5356
android:exported="true">
5457
<intent-filter>
5558
<action android:name="android.intent.action.MAIN" />

app/src/main/res/values/themes.xml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,4 +33,9 @@
3333
<item name="cornerSize">16dp</item>
3434
</style>
3535

36+
<!-- Disable Android 12 default splash screen -->
37+
<style name="Theme.RemoveSplashScreenTheme" parent="@style/Theme.CycloFit">
38+
<item name="android:windowIsTranslucent">true</item>
39+
</style>
40+
3641
</resources>

0 commit comments

Comments
 (0)