Reputation: 65
I am troubleshooting my deployment on Android (not yet tested on iOS also).
I have a simple SplashView class that just centers an image.
public class MySplashView extends SplashView {
public MySplashView(String nextView) {
super(nextView);
Image image = new Image(MySplashView.class.getResourceAsStream("/my_logo.jpg"));
ImageView imageView = new ImageView(image);
imageView.setFitWidth(AppManager.getInstance().getGlassPane().getWidth() * .75);
imageView.setPreserveRatio(true);
StackPane stackPane = new StackPane(imageView);
super.setCenter(stackPane);
}
I've tried to declare this SplashView as soon as possible in the Application's workflow.
public class MyApplication extends Application {
@Override
public void init() {
AppManager.getInstance().addViewFactory(SPLASH_VIEW, () -> new MySplashView("loginView"));
}
Before introducing this SplashView, the order I'd see at application start would be:
Now I see:
What more/else can I do so to stop showing the User an initial black screen?
Upvotes: 1
Views: 51