|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.google.gwt.user.client.ui.UIObject
com.google.gwt.user.client.ui.Widget
com.smartgwt.client.widgets.BaseWidget
com.smartgwt.client.widgets.Canvas
com.smartgwt.client.widgets.layout.Layout
com.smartgwt.client.widgets.layout.VLayout
com.smartgwt.client.widgets.Window
com.smartgwt.client.widgets.Dialog
public class Dialog
Dialogs are a specialized version of Window
used for small windows such as alerts,
prompts, and confirmations. They can be modal or modeless (via the 'isModal'
property) and will contain various children by default ("titlebar", "resizer", etc).
NOTE: If you are
building a custom component that will add components to the Window via Window.addItem(com.google.gwt.user.client.ui.Widget)
, in most cases it makes sense
Nested Class Summary |
---|
Nested classes/interfaces inherited from class com.google.gwt.user.client.ui.UIObject |
---|
UIObject.DebugIdImpl, UIObject.DebugIdImplEnabled |
Field Summary |
---|
Fields inherited from class com.smartgwt.client.widgets.BaseWidget |
---|
config, configOnly, id, isElementSet, scClassName |
Fields inherited from class com.google.gwt.user.client.ui.UIObject |
---|
DEBUG_ID_PREFIX |
Constructor Summary | |
---|---|
Dialog()
|
|
Dialog(JavaScriptObject jsObj)
|
Method Summary | |
---|---|
void |
applyClick()
Handle a click on the 'apply' button of this Dialog. |
void |
cancelClick()
Handle a click on the 'cancel' button of this Dialog. |
void |
closeClick()
Handles a click on the close button of this window. |
protected JavaScriptObject |
create()
|
static Dialog |
getOrCreateRef(JavaScriptObject jsObj)
|
Boolean |
getShowToolbar()
Whether to show a toolbar of buttons at the bottom of the Dialog. |
String |
getStyleName()
Style of the Dialog background |
void |
noClick()
Handle a click on the 'no' button of this Dialog. |
void |
okClick()
Handle a click on the 'ok' button of this Dialog. |
void |
saveData()
Method to save this Dialog's data. |
void |
setMessageStyle(String messageStyle)
Style to apply to the message text shown in the center of the dialog |
void |
setShowToolbar(Boolean showToolbar)
Whether to show a toolbar of buttons at the bottom of the Dialog. |
void |
setStyleName(String styleName)
Style of the Dialog background |
void |
setToolbarButtons(Canvas... toolbarButtons)
Array of Buttons to show in the showToolbar , if shown. |
void |
yesClick()
Handle a click on the 'yes' button of this Dialog. |
Methods inherited from class com.google.gwt.user.client.ui.Widget |
---|
addDomHandler, addHandler, delegateEvent, doAttachChildren, doDetachChildren, getLayoutData, getParent, isAttached, isOrWasAttached, onAttach, onBrowserEvent, onDetach, onLoad, onUnload, removeFromParent, setLayoutData, sinkEvents |
Methods inherited from class com.google.gwt.user.client.ui.UIObject |
---|
addStyleDependentName, ensureDebugId, ensureDebugId, ensureDebugId, getStyleElement, getStyleName, getStylePrimaryName, getStylePrimaryName, isVisible, onEnsureDebugId, removeStyleDependentName, removeStyleName, setElement, setPixelSize, setSize, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setVisible, unsinkEvents |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Constructor Detail |
---|
public Dialog()
public Dialog(JavaScriptObject jsObj)
Method Detail |
---|
public static Dialog getOrCreateRef(JavaScriptObject jsObj)
protected JavaScriptObject create()
create
in class Window
public void setStyleName(String styleName)
setStyleName
in class Canvas
styleName
- styleName Default value is "dialogBackground"public String getStyleName()
getStyleName
in class Canvas
public void setShowToolbar(Boolean showToolbar)
showToolbar
- showToolbar Default value is falsepublic Boolean getShowToolbar()
public void saveData()
okClick()
, applyClick()
. No default
implementation - override to perform some action if required.
public void closeClick()
public void cancelClick()
public void okClick()
saveData()
, hide the
Dialog, then return true
. Override to do something else.
public void applyClick()
saveData()
, but
NOT close the Dialog.
public void yesClick()
true
. Override to do
something else
public void noClick()
false
. Override to do
something else.
public void setToolbarButtons(Canvas... toolbarButtons)
showToolbar
, if shown.
The set of buttons to use is typically set by calling one of the shortcuts.
toolbarButtons
- the toolbar buttons
IllegalStateException
- this property cannot be changed after the component has been renderedpublic void setMessageStyle(String messageStyle) throws IllegalStateException
Note : This is an advanced setting
messageStyle
- messageStyle Default value is "normal"
IllegalStateException
- this property cannot be changed after the component has been created
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |