Skip to content

Commit 8c9fe93

Browse files
authored
chore(android): remove unused launch_splash.xml (#2411)
1 parent dae3510 commit 8c9fe93

File tree

2 files changed

+4
-35
lines changed

2 files changed

+4
-35
lines changed

android-template/app/src/main/res/drawable/launch_splash.xml

Lines changed: 0 additions & 5 deletions
This file was deleted.

site/docs-md/apis/splash-screen/index.md

Lines changed: 4 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -132,38 +132,12 @@ These config parameters are available in `capacitor.config.json`:
132132

133133
### Android
134134

135-
If your splash screen images aren't named "splash.png" but for example "screen.png" you have to change `"androidSplashResourceName": "screen"` in `capacitor.config.json` and change the following files in you're Android app as well:
135+
To use splash screen images named something other than `splash.png`, set `androidSplashResourceName` to the new resource name in `capacitor.config.json`. Additionally, in `android/app/src/main/res/values/styles.xml`, change the resource name in the following block:
136136

137-
`android/app/src/main/res/drawable/launch_splash.xml`
138-
139-
replace
140-
```xml
141-
<bitmap xmlns:android="http://schemas.android.com/apk/res/android"
142-
android:src="@drawable/splash"
143-
android:scaleType="centerCrop"
144-
/>
145-
```
146-
with
147-
```xml
148-
<bitmap xmlns:android="http://schemas.android.com/apk/res/android"
149-
android:src="@drawable/screen"
150-
android:scaleType="centerCrop"
151-
/>
152-
```
153-
154-
`android/app/src/main/res/values/styles.xml`
155-
156-
replace
157-
```xml
158-
<style name="AppTheme.NoActionBarLaunch" parent="AppTheme.NoActionBar">
159-
<item name="android:background">@drawable/splash</item>
160-
</style>
161-
```
162-
with
163137
```xml
164-
<style name="AppTheme.NoActionBarLaunch" parent="AppTheme.NoActionBar">
165-
<item name="android:background">@drawable/screen</item>
166-
</style>
138+
<style name="AppTheme.NoActionBarLaunch" parent="AppTheme.NoActionBar">
139+
<item name="android:background">@drawable/NAME</item>
140+
</style>
167141
```
168142

169143
## Example Guides

0 commit comments

Comments
 (0)