vanMeerdervoort
vanMeerdervoort

Reputation: 77

Replacing the Cordova Splash screen Icon

I know this question has been asked many times, most posts are from a few years ago and I've read all the posts and tried the offered solutions to no avail.

It seems, when I run 'cordova run android' or 'cordova build android' a fresh, new ic_cdv_splashscreen.xml is generated in the folder platforms/android/app/src/main/res/drawable

It seems that this is the file that displays the cordova logo on the splash screen, even if I already placed my splash screen images in the correct folders under platforms/android/app/src/main/res/drawable/drawable-* (where * is replaced by hdpi and so on)

What happens:

I run 'cordova run android' cordova then rebuilds the app, and generates the ic_cdv_splashscreen.xml in my emulator, the app starts up the splash screen shows, with the cordova logo, for a few seconds on the splash screen, the cordova logo is replaced by my proper logo splash screen fades after the set time

I have searched long and wide and pulled a lot of hairs. How do I get rid of the cordova logo?

[Edit] I have temporarily fixed / hacked the issue by adding the following preference to my to my config.xml

<preference name="AndroidWindowSplashScreenAnimatedIcon" value="res/icons/splash_screen.png" />

The image used is 180px x 180px with a round icon centered in a 120px radius.

Still, my question stands: what is the proper way to do this?

Upvotes: -1

Views: 122

Answers (1)

vanMeerdervoort
vanMeerdervoort

Reputation: 77

It seems my 'hack' in my original post is the actual answer.

Upvotes: 0

Related Questions