com.hp.hpl.guess.ui
Class ExtendedOptionPane
java.lang.Object
com.hp.hpl.guess.ui.ExtendedOptionPane
- public class ExtendedOptionPane
- extends Object
ExtendedOptionPane
public ExtendedOptionPane()
showOptionDialog
public static int showOptionDialog(Component parentComponent,
Object message,
String title,
int optionType,
int messageType,
Icon icon,
Object[] options,
Object initialValue)
throws HeadlessException
- Throws:
HeadlessException
createDialog
public static JDialog createDialog(Component t,
Component parentComponent,
String title)
throws HeadlessException
- Creates and returns a new
JDialog
wrapping
this
centered on the parentComponent
in the parentComponent
's frame.
title
is the title of the returned dialog.
The returned JDialog
will not be resizable by the
user, however programs can invoke setResizable
on
the JDialog
instance to change this property.
The returned JDialog
will be set up such that
once it is closed, or the user clicks on one of the buttons,
the optionpane's value property will be set accordingly and
the dialog will be closed. Each time the dialog is made visible,
it will reset the option pane's value property to
JOptionPane.UNINITIALIZED_VALUE
to ensure the
user's subsequent action closes the dialog properly.
- Parameters:
parentComponent
- determines the frame in which the dialog
is displayed; if the parentComponent
has
no Frame
, a default Frame
is usedtitle
- the title string for the dialog
- Returns:
- a new
JDialog
containing this instance
- Throws:
HeadlessException
- if
GraphicsEnvironment.isHeadless
returns
true
- See Also:
GraphicsEnvironment.isHeadless()
getRootFrame
public static Frame getRootFrame()
throws HeadlessException
- Throws:
HeadlessException