|
||||||||||
| 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.google.gwt.user.client.ui.Panel
com.google.gwt.user.client.ui.ComplexPanel
com.google.gwt.user.client.ui.FlowPanel
com.github.gwtbootstrap.client.ui.base.DivWidget
com.github.gwtbootstrap.client.ui.Modal
public class Modal
Popup dialog with optional header and footer.
By default, all other Modals are closed once a new one is opened. This
setting can be overridden.
<b:Modal title="My Modal" backdrop="STATIC">
<g:Label>Modal Content!</g:Label>
<b:ModalFooter>
<b:Button icon="FILE">Save</b:Button>
</b:ModalFooter>
</b:Modal>
All arguments are optional.
PopupPanel| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class com.google.gwt.user.client.ui.UIObject |
|---|
UIObject.DebugIdImpl, UIObject.DebugIdImplEnabled |
| Nested classes/interfaces inherited from interface com.google.gwt.user.client.ui.InsertPanel |
|---|
InsertPanel.ForIsWidget |
| Nested classes/interfaces inherited from interface com.google.gwt.user.client.ui.HasWidgets |
|---|
HasWidgets.ForIsWidget |
| Field Summary |
|---|
| Fields inherited from class com.google.gwt.user.client.ui.UIObject |
|---|
DEBUG_ID_PREFIX |
| Constructor Summary | |
|---|---|
Modal()
Creates an empty, hidden widget. |
|
Modal(boolean animated)
Creates an empty, hidden widget with specified show behavior. |
|
Modal(boolean animated,
boolean dynamicSafe)
Creates an empty, hidden widget with specified show behavior. |
|
| Method Summary | |
|---|---|
void |
add(Widget w)
|
HandlerRegistration |
addHiddenHandler(HiddenHandler handler)
Adds a HiddenEvent handler. |
HandlerRegistration |
addHideHandler(HideHandler handler)
Adds a HideEvent handler. |
HandlerRegistration |
addShowHandler(ShowHandler handler)
Adds a ShowEvent handler. |
HandlerRegistration |
addShownHandler(ShownHandler handler)
Adds a ShownEvent handler. |
boolean |
getAnimation()
Gets whether the widget is animated. |
BackdropType |
getBackdropType()
Get backdrop type. |
void |
hide()
Hides the widget if it was previously shown. |
void |
insert(Widget w,
int beforeIndex)
|
boolean |
isKeyboardEnable()
Get Keyboard enable state |
protected void |
onAttach()
|
protected void |
onHidden()
This method is called once the widget is completely hidden. |
protected void |
onHide()
This method is called immediately when the widget's hide()
method is executed. |
protected void |
onShow()
This method is called immediately when the widget's show()
method is executed. |
protected void |
onShown()
This method is called once the widget is completely shown. |
protected void |
reconfigure()
Reconfigures the modal with changed settings. |
void |
setAnimation(boolean animated)
Sets whether the Widget should be animated. |
void |
setBackdrop(BackdropType type)
Sets the type of the backdrop. |
void |
setCloseVisible(boolean visible)
Show/Hide close button. |
void |
setDynamicSafe(boolean dynamicSafe)
Setup the modal to prevent memory leaks. |
void |
setHideOthers(boolean hideOthers)
Sets whether this Modal appears on top of others or is the only one visible on screen. |
void |
setKeyboard(boolean keyboard)
Sets whether the Modal is closed when the ESC is pressed. |
void |
setSize(String width,
String height)
Deprecated. modal do not support setSize method |
void |
setTitle(String title)
Sets the title of the Modal. |
void |
show()
Shows the widget if it was previously hidden. |
void |
toggle()
Toggles the view state of the widget. |
| Methods inherited from class com.github.gwtbootstrap.client.ui.base.DivWidget |
|---|
addStyle, pullRight, removeStyle, setHideOn, setShowOn, setStyle |
| Methods inherited from class com.google.gwt.user.client.ui.FlowPanel |
|---|
clear, insert |
| Methods inherited from class com.google.gwt.user.client.ui.ComplexPanel |
|---|
add, adjustIndex, checkIndexBoundsForAccess, checkIndexBoundsForInsertion, getChildren, getWidget, getWidgetCount, getWidgetIndex, getWidgetIndex, insert, insert, iterator, remove, remove |
| Methods inherited from class com.google.gwt.user.client.ui.Panel |
|---|
add, adopt, adopt, disown, doAttachChildren, doDetachChildren, orphan, remove |
| Methods inherited from class com.google.gwt.user.client.ui.Widget |
|---|
addAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, createHandlerManager, delegateEvent, fireEvent, getHandlerCount, getLayoutData, getParent, isAttached, isOrWasAttached, onBrowserEvent, onDetach, onLoad, onUnload, removeFromParent, setLayoutData, sinkEvents |
| Methods inherited from class com.google.gwt.user.client.ui.UIObject |
|---|
addStyleDependentName, addStyleName, ensureDebugId, ensureDebugId, ensureDebugId, getAbsoluteLeft, getAbsoluteTop, getElement, getOffsetHeight, getOffsetWidth, getStyleElement, getStyleName, getStyleName, getStylePrimaryName, getStylePrimaryName, getTitle, isVisible, isVisible, onEnsureDebugId, removeStyleDependentName, removeStyleName, resolvePotentialElement, setElement, setElement, setHeight, setPixelSize, setStyleDependentName, setStyleName, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setVisible, setVisible, setWidth, sinkBitlessEvent, toString, unsinkEvents |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface com.google.gwt.user.client.ui.InsertPanel.ForIsWidget |
|---|
add |
| Methods inherited from interface com.google.gwt.user.client.ui.IndexedPanel.ForIsWidget |
|---|
getWidgetIndex |
| Methods inherited from interface com.google.gwt.user.client.ui.IndexedPanel |
|---|
getWidget, getWidgetCount, getWidgetIndex, remove |
| Constructor Detail |
|---|
public Modal()
public Modal(boolean animated)
animated - true if the widget should be animated.
public Modal(boolean animated,
boolean dynamicSafe)
animated - true if the widget should be animated.dynamicSafe - true removes from RootPanel when hidden| Method Detail |
|---|
public void setDynamicSafe(boolean dynamicSafe)
dynamicSafe - public void setTitle(String title)
setTitle in class UIObjecttitle - the title of the Modalpublic void setAnimation(boolean animated)
setAnimation in interface IsAnimatedanimated - true if the widget should be animated.public boolean getAnimation()
getAnimation in interface IsAnimatedtrue if the widget is animatedpublic void setHideOthers(boolean hideOthers)
hideOthers - true to make sure that this modal is the only one
shown. All others will be hidden. Default: truepublic void setKeyboard(boolean keyboard)
ESC is pressed.
keyboard - true if the Modal is closed by ESC
key. Default: truepublic boolean isKeyboardEnable()
public void setBackdrop(BackdropType type)
type - the backdrop typepublic BackdropType getBackdropType()
protected void reconfigure()
public void add(Widget w)
add in interface HasWidgetsadd in interface InsertPaneladd in class FlowPanel
public void insert(Widget w,
int beforeIndex)
insert in interface InsertPanelinsert in class FlowPanelpublic void show()
protected void onAttach()
onAttach in class Widgetpublic void hide()
public void toggle()
It will be hidden if it was previously shown and shown if it was previously hidden.
protected void onHide()
hide()
method is executed.
protected void onHidden()
protected void onShow()
show()
method is executed.
protected void onShown()
public HandlerRegistration addHideHandler(HideHandler handler)
HideEvent handler.
addHideHandler in interface HasVisibleHandlershandler - the hide handler
HandlerRegistration used to remove this handlerpublic HandlerRegistration addHiddenHandler(HiddenHandler handler)
HiddenEvent handler.
addHiddenHandler in interface HasVisibleHandlershandler - the hidden handler
HandlerRegistration used to remove this handlerpublic HandlerRegistration addShowHandler(ShowHandler handler)
ShowEvent handler.
addShowHandler in interface HasVisibleHandlershandler - the show handler
HandlerRegistration used to remove this handlerpublic HandlerRegistration addShownHandler(ShownHandler handler)
ShownEvent handler.
addShownHandler in interface HasVisibleHandlershandler - the shown handler
HandlerRegistration used to remove this handlerpublic void setCloseVisible(boolean visible)
visible - true for show and false to hide. Defaults is
true.
public void setSize(String width,
String height)
setSize in class UIObject
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||