|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.wings.SComponent
org.wings.SContainer
org.wings.SForm
org.wings.SWindow
org.wings.SDialog
public class SDialog
Top-level window with a title and a border that is typically used to take some form of input from the user.
As opposed to Swing, wingS dialogs are non modal. However, the dismission of the dialog is propagated by means of ActionEvents. The action command of the event tells, what kind of user activity caused the dialog to dismiss.
| Field Summary | |
|---|---|
static String |
CLOSE_ACTION
Action command if dialog window was closed |
static String |
DEFAULT_ACTION
Action command if user hit return |
protected boolean |
draggable
|
protected SIcon |
icon
|
protected boolean |
modal
|
protected String |
title
The Title of the Dialog Frame |
| Fields inherited from class org.wings.SWindow |
|---|
owner, x, y |
| Fields inherited from class org.wings.SForm |
|---|
actionCommand, ENC_TYPE_MULTIPART_FORM, ENC_TYPE_TEXT_PLAIN, listenerList, URL_ENCODING |
| Fields inherited from class org.wings.SComponent |
|---|
DONE_RENDERING, dynamicStyles, enabled, propertyChangeSupport, SELECTOR_ALL, START_RENDERING, visible, WHEN_FOCUSED_OR_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_IN_FOCUSED_FRAME |
| Constructor Summary | |
|---|---|
SDialog()
Creates a Dialog without parent SFrame or
SDialog and without Title |
|
SDialog(SFrame owner)
Creates a dialog with the specifed parent SFrame as its
owner. |
|
SDialog(SFrame owner,
boolean modal)
Creates a modal or non-modal dialog without a title and with the specified owner Frame. |
|
SDialog(SFrame owner,
String title)
Creates a dialog with the specified title and the specified owner frame. |
|
SDialog(SFrame owner,
String title,
boolean modal)
Creates a modal or non-modal dialog with the specified title and the specified owner Frame. |
|
| Method Summary | |
|---|---|
SIcon |
getIcon()
|
String |
getTitle()
Gets the title of the dialog. |
void |
hide()
Remove this window from its frame. |
boolean |
isClosable()
|
boolean |
isDraggable()
|
boolean |
isModal()
|
void |
setCG(DialogCG cg)
|
void |
setClosable(boolean v)
|
void |
setDraggable(boolean draggable)
|
void |
setIcon(SIcon i)
|
void |
setModal(boolean modal)
|
void |
setTitle(String t)
Sets the title of the dialog. |
| Methods inherited from class org.wings.SWindow |
|---|
dispose, getOwner, getX, getY, processLowLevelEvent, setVisible, setX, setY, show |
| Methods inherited from class org.wings.SContainer |
|---|
add, add, add, add, addComponent, addComponent, addComponent, addContainerListener, addNotify, clone, fireContainerEvent, getComponent, getComponentCount, getComponentList, getComponents, getConstraintAt, getConstraintList, getLayout, invite, inviteEachComponent, isShowingChildren, processContainerEvent, remove, remove, removeAll, removeContainerListener, removeNotify, setCG, setLayout, setParentFrame, updateCG |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.wings.LowLevelEventListener |
|---|
fireFinalEvents, fireIntermediateEvents, getLowLevelEventId, getName, isEnabled, isEpochCheckEnabled |
| Field Detail |
|---|
public static final String CLOSE_ACTION
public static final String DEFAULT_ACTION
protected String title
protected SIcon icon
protected boolean modal
protected boolean draggable
| Constructor Detail |
|---|
public SDialog()
SFrame or
SDialog and without Title
public SDialog(SFrame owner)
SFrame as its
owner.
owner - the parent SFrame
public SDialog(SFrame owner,
boolean modal)
Frame. If owner is
null, a shared, hidden frame will be set as the owner of
the dialog.
This constructor sets the component's locale property to the value
returned by JComponent.getDefaultLocale.
owner - the Frame from which the dialog is displayedmodal - true for a modal dialog, false for one that allows others
windows to be active at the same time returns true.
public SDialog(SFrame owner,
String title)
owner - the parent SFrametitle - the String to display as titke
public SDialog(SFrame owner,
String title,
boolean modal)
Frame. If owner is
null, a shared, hidden frame will be set as the owner of
this dialog. All constructors defer to this one.
NOTE: Any popup components (JComboBox,
JPopupMenu, JMenuBar) created within a
modal dialog will be forced to be lightweight.
This constructor sets the component's locale property to the value
returned by JComponent.getDefaultLocale.
owner - the Frame from which the dialog is displayedtitle - the String to display in the dialog's title barmodal - true for a modal dialog, false for one that allows other
windows to be active at the same time returns true.| Method Detail |
|---|
public void setTitle(String t)
t - the title displayed in the dialog's border; a null value
results in an empty titlepublic String getTitle()
public void setIcon(SIcon i)
public SIcon getIcon()
public boolean isModal()
public void setModal(boolean modal)
public boolean isDraggable()
public void setDraggable(boolean draggable)
public void hide()
SWindow
hide in class SWindowpublic void setClosable(boolean v)
public boolean isClosable()
public void setCG(DialogCG cg)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||