|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.jaxfront.swing.ui.tools.Dialog
public class Dialog
This class represents a default JAXFront dialog that can be used in various contexts.
| Field Summary | |
|---|---|
static int |
DEFAULT_OK_BUTTON_SEQUENCE
|
| Constructor Summary | |
|---|---|
Dialog(java.awt.Component root,
java.awt.Component content,
Type rootType)
Default constructor. |
|
Dialog(java.awt.Component root,
java.awt.Component content,
Type rootType,
int okButtonSequence)
Default constructor. |
|
Dialog(java.awt.Component root,
Type rootType)
Default constructor. |
|
Dialog(java.awt.Component root,
Type rootType,
int okButtonSequence)
Default constructor. |
|
| Method Summary | |
|---|---|
void |
actionPerformed(java.awt.event.ActionEvent e)
|
javax.swing.JDialog |
build()
Builds the dialog. |
void |
componentAdded(java.awt.event.ContainerEvent e)
|
void |
componentRemoved(java.awt.event.ContainerEvent e)
|
void |
computeDialogBounds(java.awt.Component containerComponent)
Computes the bounds for the dialog (x/y-Position, height/width). |
static java.awt.Rectangle |
computeDialogBounds(java.awt.Component window,
java.awt.Component dialog)
|
void |
doLayout()
Do the layout. |
static java.lang.String |
getCANCELButtonName()
|
java.awt.Container |
getContentPane()
|
javax.swing.JDialog |
getDialogComponent()
|
int |
getHeight()
Returns the height of the dialog. |
static java.lang.String |
getOKButtonName()
|
int |
getWidth()
Returns the width of the dialog. |
boolean |
isCanceled()
|
void |
keyPressed(java.awt.event.KeyEvent e)
|
void |
keyReleased(java.awt.event.KeyEvent e)
|
void |
keyTyped(java.awt.event.KeyEvent e)
|
void |
release()
Releases cache and initializes all variables. |
void |
repaint()
Do the layout. |
void |
setBackground(java.awt.Color c)
Sets a background color for the dialog. |
void |
setContent(java.awt.Component content)
Sets the content for the dialog (Component) |
void |
setDialogListener(java.awt.event.ActionListener dialogListener)
Sets a dialogListener to the buttons. |
void |
setForeground(java.awt.Color c)
Sets a foreground color for the dialog. |
void |
setLocation(int x,
int y)
Sets the location of the dialog. |
void |
setLocation(java.awt.Point location)
|
void |
setModal(boolean b)
Sets the dialog modal or not. |
void |
setSize(java.awt.Dimension d)
Sets the size of the dialog. |
void |
setTitle(java.lang.String title)
Sets a title for the dialog. |
void |
setUndecorated(boolean undecorated)
Removes the decoration of the dialog if true. |
void |
setVisible(boolean visible)
Sets the visibility of the dialog. |
static int |
showComponentDialog(java.awt.Component parent,
java.awt.Component component,
java.lang.String title)
|
static int |
showComponentDialog(java.awt.Component component,
java.lang.String title)
|
static int |
showConfirmDialog(java.awt.Component parent,
java.lang.String message)
|
static int |
showConfirmDialog(java.awt.Component parent,
java.lang.String title,
java.lang.String message)
|
static int |
showConfirmDialog(java.lang.String message)
|
static void |
showErrorDialog(java.awt.Component parent,
java.awt.Component content,
java.lang.String title)
|
static void |
showErrorDialog(java.awt.Component parent,
java.lang.String message)
|
static void |
showErrorDialog(java.awt.Component parent,
java.lang.String message,
java.lang.String title)
|
static void |
showErrorDialog(java.awt.Component parent,
java.lang.String message,
java.lang.Throwable t,
java.lang.String title)
|
static void |
showErrorDialog(java.lang.String message)
|
static void |
showInformationDialog(java.awt.Component parent,
java.lang.String message)
|
static void |
showInformationDialog(java.awt.Component parent,
java.lang.String title,
java.lang.String message)
|
static void |
showInformationDialog(java.lang.String message)
|
static boolean |
showListDeletionDialog(Type viewType,
Type typeToDelete)
|
static void |
showWarningDialog(java.awt.Component parent,
java.lang.String message)
|
static void |
showWarningDialog(java.awt.Component parent,
java.lang.String message,
java.lang.String title)
|
static void |
showWarningDialog(java.lang.String message)
|
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final int DEFAULT_OK_BUTTON_SEQUENCE
| Constructor Detail |
|---|
public Dialog(java.awt.Component root,
Type rootType)
root - a root component (container) that should hold this dialogrootType - a JAXFront type
public Dialog(java.awt.Component root,
Type rootType,
int okButtonSequence)
root - a root component (container) that should hold this dialogrootType - a JAXFront typeokButtonSequence - defines the sequence of the buttons (if 0 -> ok button is on
the left, if 1 -> ok button is on the right)
public Dialog(java.awt.Component root,
java.awt.Component content,
Type rootType)
root - a root component (container) that should hold this dialogcontent - the content for the dialog (Component)rootType - a JAXFront type
public Dialog(java.awt.Component root,
java.awt.Component content,
Type rootType,
int okButtonSequence)
root - a root component (container) that should hold this dialogcontent - the content for the dialog (Component)rootType - a JAXFront typeokButtonSequence - defines the sequence of the buttons (if 0 -> ok button is on
the left, if 1 -> ok button is on the right)| Method Detail |
|---|
public javax.swing.JDialog build()
public void computeDialogBounds(java.awt.Component containerComponent)
containerComponent - the container that holds the dialogpublic void setContent(java.awt.Component content)
content - the content of the dialog (Component)public void setUndecorated(boolean undecorated)
undecorated - true if the decoration of the dialog should be invisiblepublic void setSize(java.awt.Dimension d)
d - a dimension
public void setLocation(int x,
int y)
x - horizontal location on the screeny - vertical location on the screenpublic void setLocation(java.awt.Point location)
public void setVisible(boolean visible)
visible - true, if visible, false otherwisepublic void setTitle(java.lang.String title)
title - a textpublic void setBackground(java.awt.Color c)
c - a colorpublic void setForeground(java.awt.Color c)
c - a colorpublic void doLayout()
public void repaint()
public int getWidth()
public int getHeight()
public void release()
public static java.lang.String getOKButtonName()
public static java.lang.String getCANCELButtonName()
public void actionPerformed(java.awt.event.ActionEvent e)
actionPerformed in interface java.awt.event.ActionListenerActionListener.actionPerformed(java.awt.event.ActionEvent)public void setModal(boolean b)
b - true if the dialog should be set modalpublic void setDialogListener(java.awt.event.ActionListener dialogListener)
dialogListener - a dialogListener
public static java.awt.Rectangle computeDialogBounds(java.awt.Component window,
java.awt.Component dialog)
public void componentAdded(java.awt.event.ContainerEvent e)
componentAdded in interface java.awt.event.ContainerListenerpublic void componentRemoved(java.awt.event.ContainerEvent e)
componentRemoved in interface java.awt.event.ContainerListenerpublic void keyPressed(java.awt.event.KeyEvent e)
keyPressed in interface java.awt.event.KeyListenerpublic void keyReleased(java.awt.event.KeyEvent e)
keyReleased in interface java.awt.event.KeyListenerpublic void keyTyped(java.awt.event.KeyEvent e)
keyTyped in interface java.awt.event.KeyListenerpublic boolean isCanceled()
public javax.swing.JDialog getDialogComponent()
public static void showErrorDialog(java.lang.String message)
public static void showInformationDialog(java.lang.String message)
public static int showConfirmDialog(java.lang.String message)
public static void showWarningDialog(java.lang.String message)
public static void showErrorDialog(java.awt.Component parent,
java.lang.String message)
public static void showErrorDialog(java.awt.Component parent,
java.lang.String message,
java.lang.String title)
public static void showErrorDialog(java.awt.Component parent,
java.lang.String message,
java.lang.Throwable t,
java.lang.String title)
public static void showErrorDialog(java.awt.Component parent,
java.awt.Component content,
java.lang.String title)
public static void showInformationDialog(java.awt.Component parent,
java.lang.String message)
public static void showInformationDialog(java.awt.Component parent,
java.lang.String title,
java.lang.String message)
public static int showComponentDialog(java.awt.Component component,
java.lang.String title)
public static int showComponentDialog(java.awt.Component parent,
java.awt.Component component,
java.lang.String title)
public static int showConfirmDialog(java.awt.Component parent,
java.lang.String message)
public static int showConfirmDialog(java.awt.Component parent,
java.lang.String title,
java.lang.String message)
public static void showWarningDialog(java.awt.Component parent,
java.lang.String message)
public static void showWarningDialog(java.awt.Component parent,
java.lang.String message,
java.lang.String title)
public static boolean showListDeletionDialog(Type viewType,
Type typeToDelete)
public java.awt.Container getContentPane()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||