|
Version: 1.1.1 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.awt.Component java.awt.Container java.awt.Window ca.ucalgary.seahawk.gui.splash.SplashWindow
public class SplashWindow
A Splash window.
Usage: MyApplication is your application class. Create a Splasher class which opens the splash window, invokes the main method of your Application class, and disposes the splash window afterwards. Please note that we want to keep the Splasher class and the SplashWindow class as small as possible. The less code and the less classes must be loaded into the JVM to open the splash screen, the faster it will appear.
class Splasher { public static void main(String[] args) { SplashWindow.splash(Splasher.class.getResource("splash.gif")); MyApplication.main(args); SplashWindow.disposeSplash(); } }
Nested Class Summary |
---|
Nested classes/interfaces inherited from class java.awt.Component |
---|
Component.BaselineResizeBehavior |
Field Summary |
---|
Fields inherited from class java.awt.Component |
---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface java.awt.image.ImageObserver |
---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Method Summary | |
---|---|
static void |
disposeSplash()
Closes the splash window. |
static void |
invokeInit(String className,
JApplet applet)
Invokes the init method of the JApplet class provided by name. |
static void |
invokeMain(String className,
String[] args)
Invokes the main method of the provided class name. |
static void |
invokeStaticMethod(String className,
String methodName)
Invokes a method of the provided class name with no arguments. |
static void |
invokeStaticMethod(String className,
String methodName,
boolean arg)
Invokes a method of the provided class name with a boolean argument. |
static void |
invokeStaticMethod(String className,
String methodName,
double arg)
Invokes a method of the provided class name with a double (real number) argument. |
static void |
invokeStaticMethod(String className,
String methodName,
int arg)
Invokes a method of the provided class name with an integer argument. |
void |
paint(Graphics g)
Paints the image on the window. |
static void |
setStatus(String status)
|
static void |
setStatus(String status,
boolean wait)
|
static void |
setStatusPosition(int x,
int y)
|
static void |
setTitlePosition(int x,
int y)
|
static void |
splash(Image image)
Open's a splash window using the specified image |
static void |
splash(Image image,
String title)
Open's a splash window using the specified image and title |
static void |
splash(URL imageURL)
Open's a splash window using the specified image URL |
static void |
splash(URL imageURL,
String title)
Open's a splash window using the specified image URL and title |
void |
update(Graphics g)
Updates the display area of the window. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Method Detail |
---|
public static void setTitlePosition(int x, int y)
public static void setStatusPosition(int x, int y)
public void update(Graphics g)
update
in class Container
public void paint(Graphics g)
paint
in class Window
public static void setStatus(String status)
public static void setStatus(String status, boolean wait)
public static void splash(Image image, String title)
image
- The splash imagetitle
- The title of the splash windowpublic static void splash(Image image)
image
- The splash imagepublic static void splash(URL imageURL, String title)
imageURL
- The url of the splash imagetitle
- The title of the splash windowpublic static void splash(URL imageURL)
imageURL
- The url of the splash imagepublic static void disposeSplash()
public static void invokeStaticMethod(String className, String methodName, int arg)
arg
- the int to be passed into the method.public static void invokeStaticMethod(String className, String methodName, boolean arg)
arg
- the boolean to be passed into the method.public static void invokeStaticMethod(String className, String methodName, double arg)
arg
- the double precision floating point number to be passed into the method.public static void invokeStaticMethod(String className, String methodName)
public static void invokeMain(String className, String[] args)
args
- the command line argumentspublic static void invokeInit(String className, JApplet applet)
applet
- the applet that was actually launched
|
Version: 1.1.1 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |