Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Honda10_y_
Beginner
252 Views

How to delay Splash screen for 3 seconds

Hi, how do I delay the splash screen to 3 seconds before it gets disappear.

The splashscreen disappear so fast not even 1 seconds.

Please help.

Tags (2)
0 Kudos
11 Replies
Kevin_L_3
Beginner
252 Views

These are the settings I use in the Additions file (intelxdk.config.additions.xml) for iOS, the value is in milliseconds so 3000 should equal 3 seconds.

<preference name="SplashScreen" value="splash"/>

<preference name="FadeSplashScreenDuration" value="3000"/>
<preference name="AutoHideSplashScreen" value="true" />

See https://github.com/apache/cordova-plugin-splashscreen for instructions.

I'm having some issues with Android Crosswalk settings but I'll post back if I sort it out.

Kevin_L_3
Beginner
252 Views

For Android Crosswalk - I did do this from a previous post:

<platform name="android">
    <preference name="SplashScreen" value="screen" />
    <preference name="AutoHideSplashScreen" value="true" />
    <preference name="SplashScreenDelay" value="3000" />
    <preference name="SplashMaintainAspectRatio" value="false" />
</platform>

But there is a blank screen for several seconds after the splashscreen which I don't know how to remove. If anyone finds a solution please post!

Honda10_y_
Beginner
252 Views

Do I need to update directly from the file or I need to update from the plugin setting
Honda10_y_
Beginner
252 Views

Thank you. It works

John_L_11
Beginner
252 Views

Kevin, did you or anyone else solve the blank screen delay after the splash screen? Having that same problem now as well. Splash screen comes up fine for a couple seconds, the a blank screen for about 2 or 3 seconds before the app actually presents the UI.

Hoping someone can help with this.

Kevin L. wrote:

For Android Crosswalk - I did do this from a previous post:

<platform name="android">
    <preference name="SplashScreen" value="screen" />
    <preference name="AutoHideSplashScreen" value="true" />
    <preference name="SplashScreenDelay" value="3000" />
    <preference name="SplashMaintainAspectRatio" value="false" />
</platform>

But there is a blank screen for several seconds after the splashscreen which I don't know how to remove. If anyone finds a solution please post!

 

PaulF_IntelCorp
Employee
252 Views

John -- if your code is calling the function to hide the splash screen, following the deviceready event, it will override those parameters in the additions file.

John_L_11
Beginner
252 Views

Paul F. (Intel) wrote:

John -- if your code is calling the function to hide the splash screen, following the deviceready event, it will override those parameters in the additions file.

I have not called any function to hide the splash screen. Not sure if the XDK generated something to call it either. The splash comes up fine, stays on the screen for about 2 or 3 seconds (which is fine), then a blank dark gray screen for another 3 seconds, then the index finally shows and the app is ready. Not sure how to fix the paused blank screen following the splash. Only plugins are the splash and notifications. Its a Twitter bootstrap app with only the notification plugin added.
Honda20
Beginner
252 Views

Hi John Can you please paste your index.html code here. Honda
PaulF_IntelCorp
Employee
252 Views

John -- depending on what template you used (sounds like you are using App Designer) there may be some code in there that is hiding the splash screen search for a file named init-dev.js inside www or a subfolder. If that script file is being used it will hide the splash screen on device ready (scan the file, it is well commented).

John_L_11
Beginner
252 Views

Thanks Paul. I located the init-dev.sj file in the www/xdk folder. The index.html file has a reference to it with "<script src="xdk/init-dev.js"></script>". Should I remove this reference? Not sure that will do anything since the only other reference to it is "init-app.js" and that file has the call commented out with "// App init point (runs on custom app.Ready event from init-dev.js)."

However, I did notice that if we extend the splash delay to 5 seconds with <preference name="SplashScreenDelay" value="5000" />, the blank gray screen that follows that splash screen is only there for a split second before the app main screen appears. The delay change seems to have helped a bit.

 

 

Paul F. (Intel) wrote:

John -- depending on what template you used (sounds like you are using App Designer) there may be some code in there that is hiding the splash screen search for a file named init-dev.js inside www or a subfolder. If that script file is being used it will hide the splash screen on device ready (scan the file, it is well commented).

PaulF_IntelCorp
Employee
252 Views

I was mistaken, it's the init-app.js file that is hiding the splash screen. I would remove that file, leave the init-dev.js file, I think some of the App Designer templates use that app.Ready event that it generates. Even if you don't end up using the app.Ready event, the init-dev.js file will not impact your app in any way.
 

Reply