|
|
Package com.dassault_systemes.catweb.base.awt |
Class DialogBox
|
Class Hierarchy |
java.lang.Object | +-java.awt.Component | +-java.awt.Container | +-java.awt.Window | +-java.awt.Dialog | +-com.dassault_systemes.catweb.base.awt.CATDialog | +-com.dassault_systemes.catweb.base.awt.DialogBox
Class Location |
Class Description |
public class DialogBox
Creates a DialogBox with default combination of buttons.
The default buttons combinations are:
OK_CANCEL
used: - when the user can see directly the result of his interactions into the dialog box
- when the task is so simple that the user does not need to do several attempts.
OK_CANCEL_PREVIEW
used: - when the user cannot see directly the result after modifying a parameter of the dialog box
OK_APPLY_CLOSE
used: - when interactions inside the command are not "undo-able"
CLOSE
used: - when interactions does not modify the document
- when the behavior of the dialog box is like a toolbar palette made up of several commands.
Field Summary |
int | OK_CANCEL |
int | OK_CANCEL_PREVIEW |
int | OK_APPLY_CLOSE |
int | CLOSE |
String | OK_CMD |
String | CANCEL_CMD |
String | APPLY_CMD |
String | PREVIEW_CMD |
String | CLOSE_CMD |
int | currentButtonsCombi |
Panel | workarea |
Panel | leftButtonsPanel |
Panel | rightButtonsPanel |
Vector | listOfButton |
Vector | listOfButton_old |
int | counterButton |
Constructor Summary |
DialogBox(Frame parent) |
DialogBox(Frame parent, boolean modal) |
DialogBox(Frame parent, String title) |
DialogBox(Frame parent, String title, boolean modal) |
DialogBox(Frame parent, String title, boolean modal, boolean useSettings) |
Method Summary |
void | setButtonsCombination(int buttonsType) |
Button | addButton(String label, String actionCmd) |
CATButtonIF | addCATButtonIF(String label, String actionCmd) |
Button | addRightButton(String label, String actionCmd) |
CATButtonIF | addRightCATButtonIF(String label, String actionCmd) |
Button | addLeftButton(String label, String actionCmd) |
CATButtonIF | addLeftCATButtonIF(String label, String actionCmd) |
Button[] | getButtons() |
CATButtonIF[] | getCATButtonsIF() |
void | setCATButtonIFName() |
Button | getButton(String actionCmd) |
CATButtonIF | getCATButtonIF(String actionCmd) |
boolean | isListenDefaultCommands() |
void | setListenDefaultCommand(boolean flag) |
void | addButtonActionListener(ActionListener listener) |
void | removeButtonActionListener(ActionListener listener) |
void | dispose() |
void | show() |
void | hide() |
void | cleanup() |
Container | getContentPane() |
Field Detail |
int OK_CANCELSpecifies the type of buttons combination
int OK_CANCEL_PREVIEW
int OK_APPLY_CLOSE
int CLOSE
String OK_CMDThe actions command associated to default buttons
String CANCEL_CMD
String APPLY_CMD
String PREVIEW_CMD
String CLOSE_CMD
int currentButtonsCombicurrent buttons combination
Panel workareathe area that will contain dialog components (no button)
Panel leftButtonsPanelsouth west panel for buttons
Panel rightButtonsPanelsouth east panel for buttons
Vector listOfButtoncontains the list of button (CATButtonIF) created and added to the dialog
Vector listOfButton_oldcontains the list of button (Button) created and added to the dialog
Deprecated. V5R10
int counterButton
Constructor Detail |
DialogBox(Frame parent)Constructor
parent
DialogBox(Frame parent, boolean modal)Constructor
parent
modal
DialogBox(Frame parent, String title)Constructor
parent
title
DialogBox(Frame parent, String title, boolean modal)Constructor
parent
title
modal
DialogBox(Frame parent, String title, boolean modal, boolean useSettings)Constructor
parent
title
modal
useSettings
Method Detail |
void setButtonsCombination(int buttonsType)Sets the type of buttons combination display in the dialog The possible combinations are OK_CANCEL, OK_CANCEL_PREVIEW, OK_APPLY_CLOSE and CLOSE
buttonsType
Button addButton(String label, String actionCmd)Creates a DialogButton with the label and the action command actionCmd, and add it to the dialog at South-East
Deprecated. V5R10 - Replaced by @href #addCATButtonIF
label
actionCmd
CATButtonIF addCATButtonIF(String label, String actionCmd)Creates a CATButtonIF with the label and the action command actionCmd, and add it to the dialog at South-East
label
actionCmd
Button addRightButton(String label, String actionCmd)Creates a DialogButton with the label and the action command actionCmd, and add it to the dialog at South-East
Deprecated. V5R10 - Replaced by @href #addRightCATButtonIF
label
actionCmd
CATButtonIF addRightCATButtonIF(String label, String actionCmd)Creates a CATButtonIF with the label and the action command actionCmd, and add it to the dialog at South-East
label
actionCmd
Button addLeftButton(String label, String actionCmd)Creates a DialogButton with the label and the action command actionCmd, and add it to the dialog at South-West
Deprecated. V5R10 - Replaced by @href #addLeftCATButtonIF
label
actionCmd
CATButtonIF addLeftCATButtonIF(String label, String actionCmd)Creates a CATButtonIF with the label and the action command actionCmd, and add it to the dialog at South-West
label
actionCmd
Button[] getButtons()Returns the list of buttons of the DialogBox
Deprecated. V5R10 - Replaced by @href #getCATButtonsIF
CATButtonIF[] getCATButtonsIF()Returns the list of CATButtonIF of the DialogBox
void setCATButtonIFName()
Button getButton(String actionCmd)Returns the button specified by its action command
Deprecated. V5R10 - Replaced by @href #getCATButtonIF
actionCmd
CATButtonIF getCATButtonIF(String actionCmd)Returns the button specified by its action command
actionCmd
boolean isListenDefaultCommands()Returns true if the Dialog Box listen to default command in order to close dialog for action OK, CANCEL or CLOSE.
void setListenDefaultCommand(boolean flag)Listens or not the default commands in order to close dialog for action OK, CANCEL or CLOSE.
flag
void addButtonActionListener(ActionListener listener)Adds an action listener instance to the subscriber list.
listener
void removeButtonActionListener(ActionListener listener)Removes an action listener instance from the subscriber list
listener
void dispose()Disposes of this dialog.
void show()Shows this dialog.
void hide()Hides this dialog.
void cleanup()Cleans the Dialog : removes buttons and listeners
Container getContentPane()This method is just here to give the dialog a 'add' mecanism similar to a swing JDialog