Request: Add option to require manual dismiss of loadingscreen
MrBillium opened this issue · 0 comments
Description
Users can suffer from a black screen on startup because their app starts slowly. With code refactoring using lazy loading of screens , this can be reduced but I doubt it can be eliminated for anything beyond 'hello world' using a screen manager ( which can't itself be lazy loaded).
From your API doc below I see there is a way to manually stop 'loadingscreen' which I assume could be my lottie file.....
__
Dismissing the splash screen
With the SDL2 bootstrap, the app's splash screen may be visible longer than necessary (with your app already being loaded) due to a limitation with the way we check if the app has properly started. In this case, the splash screen overlaps the app gui for a short time.To dismiss the loading screen explicitly in your code, use the android module:_
_
from android import loadingscreen
loadingscreen.hide_loading_screen()
You can call it e.g. using kivy.clock.Clock.schedule_once to run it in the first active frame of your app, or use the app build method.
My problem is the opposite of the above! - the splash screen is dismissed too early, leading to several seconds of black screen.
Request
Add a build option to Require using loadingscreen.hide_loading_screen() to kill the loading screen ( perhaps with a long failsafe timeout of say 60s) . Then I can call the above code in on_enter() of my home screen and perhaps eliminate the black screen no matter how long it takes my code to load since the splash will keep running until my code is ready to stop it.