|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.awt.Component
java.awt.Container
java.awt.Window
java.awt.Dialog
javax.swing.JDialog
org.basex.gui.dialog.Dialog
public abstract class Dialog
This class provides the architecture for consistent dialog windows.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class java.awt.Dialog |
---|
Dialog.ModalExclusionType, Dialog.ModalityType |
Nested classes/interfaces inherited from class java.awt.Component |
---|
Component.BaselineResizeBehavior |
Field Summary | |
---|---|
GUI |
gui
Reference to main window. |
Fields inherited from class java.awt.Dialog |
---|
DEFAULT_MODALITY_TYPE |
Fields inherited from class java.awt.Component |
---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface javax.swing.WindowConstants |
---|
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, EXIT_ON_CLOSE, HIDE_ON_CLOSE |
Fields inherited from interface java.awt.image.ImageObserver |
---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
---|---|
Dialog(GUI main,
String title)
Default constructor. |
|
Dialog(GUI main,
String title,
boolean modal)
Default constructor. |
Method Summary | |
---|---|
void |
action(Object comp)
Reacts on user input; can be overwritten. |
void |
cancel()
Cancels the dialog; can be overwritten. |
void |
close()
Closes the dialog; can be overwritten and stores the dialog position if it has been specified before. |
static boolean |
confirm(Component comp,
String text)
Static yes/no dialog. |
void |
dispose()
|
static void |
error(GUI gui,
String text)
Static error dialog. |
static void |
info(GUI gui,
String text)
Static information dialog. |
boolean |
ok()
States if the dialog window was confirmed or canceled. |
void |
refresh()
Called when GUI design has changed. |
void |
setLocation(int x,
int y)
|
static void |
warn(GUI gui,
String text)
Static information dialog. |
Methods inherited from class javax.swing.JDialog |
---|
getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getGraphics, getJMenuBar, getLayeredPane, getRootPane, getTransferHandler, isDefaultLookAndFeelDecorated, remove, repaint, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setJMenuBar, setLayeredPane, setLayout, setTransferHandler, update |
Methods inherited from class java.awt.Dialog |
---|
addNotify, getModalityType, getTitle, hide, isModal, isResizable, isUndecorated, setModal, setModalityType, setResizable, setTitle, setUndecorated, setVisible, show, toBack |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public final GUI gui
Constructor Detail |
---|
public Dialog(GUI main, String title)
main
- reference to main windowtitle
- dialog titlepublic Dialog(GUI main, String title, boolean modal)
main
- reference to the main windowtitle
- dialog titlemodal
- modal flagMethod Detail |
---|
public void setLocation(int x, int y)
setLocation
in class Component
public void action(Object comp)
comp
- the action componentpublic void refresh()
public void cancel()
public void close()
public void dispose()
dispose
in class Window
public final boolean ok()
public static boolean confirm(Component comp, String text)
comp
- parent referencetext
- text
public static void info(GUI gui, String text)
gui
- parent referencetext
- textpublic static void warn(GUI gui, String text)
gui
- parent referencetext
- textpublic static void error(GUI gui, String text)
gui
- parent referencetext
- text
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |