• Post Reply Bookmark Topic Watch Topic
  • New Topic

splash screen

 
AL thennakoon
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
can any one tell how tocreate swing splash screeen ??
 
Steven Wall
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You have at least a couple options.

1) If using Java 6, there is a SplashScreen class. Read the API documentation here

2) We are using Java 5, and the approach we have done is to create our own class that extends JFrame that we use as a splash screen. We create and show that class from our main class. We then use SwingWorker (you can get from SwingLabs) to do all our initialization off the EDT. When the worker finishes, we dispose of our splash screen and open the main window of our application.
 
Maneesh Godbole
Bartender
Posts: 11445
18
Android Eclipse IDE Google Web Toolkit Java Mac Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Steven Wall:
...create our own class that extends JFrame


One small suggestion.
It might be a better idea to use JWindow instead of JFrame.
 
Rob Spoor
Sheriff
Posts: 20822
68
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Indeed. JWindow does not show up in the task bar, and is undecorated from itself. Both are quite common for splash screens.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!