public class Dialog extends org.apache.wicket.markup.html.WebMarkupContainer implements IWiQueryPlugin
Displays a window wrapping this WebMarkupContainer markup.
This UI component is built from this WebMarkupContainer's HTML
markup. The correct markup should be a div HTML element
wrapping the contents to display in this window.
Example:
<div wicket:id="id" title="The window title">
The wrapped content
</div>
| Modifier and Type | Class and Description |
|---|---|
static class |
Dialog.WindowPosition
Eumeration of possible window position
|
| Constructor and Description |
|---|
Dialog(String id)
Builds a new instance of
Dialog for the given wicket id. |
| Modifier and Type | Method and Description |
|---|---|
JsStatement |
close()
Method to close the dialog
|
void |
close(org.apache.wicket.ajax.AjaxRequestTarget ajaxRequestTarget)
Method to close the dialog within the ajax request
|
void |
contribute(WiQueryResourceManager wiQueryResourceManager)
Declares resources (JavaScript and CSS files) to import.
|
JsStatement |
destroy()
Method to destroy the dialog
This will return the element back to its pre-init state.
|
void |
destroy(org.apache.wicket.ajax.AjaxRequestTarget ajaxRequestTarget)
Method to destroy the dialog within the ajax request
|
protected void |
detachModel() |
JsStatement |
disable()
Method to disable the dialog
|
void |
disable(org.apache.wicket.ajax.AjaxRequestTarget ajaxRequestTarget)
Method to disable the dialog within the ajax request
|
JsStatement |
enable()
Method to enable the dialog
|
void |
enable(org.apache.wicket.ajax.AjaxRequestTarget ajaxRequestTarget)
Method to enable the dialog within the ajax request
|
ListItemOptions<DialogButton> |
getButtons() |
String |
getCloseText() |
String |
getCssClass()
Returns the css class applied to customize this window.
|
String |
getDialogClass() |
int |
getHeight()
Returns the window's height.
|
String |
getHideEffect() |
int |
getMaxHeight()
Returns the window's max height.
|
int |
getMaxWidth()
Returns the window's max width.
|
int |
getMinHeight()
Returns the window's min height.
|
int |
getMinWidth()
Returns the window's max width.
|
protected Options |
getOptions()
Method retrieving the options of the component
|
Dialog.WindowPosition |
getPosition()
Returns the
Dialog.WindowPosition. |
String |
getShowEffect() |
String |
getTitle()
Returns the window's title.
|
int |
getWidth()
Returns the dialog's width.
|
int |
getZIndex() |
boolean |
isAutoOpen() |
boolean |
isBgiframe()
Deprecated.
will be removed in 1.3
|
boolean |
isCloseOnEscape() |
boolean |
isDisabled() |
boolean |
isDraggable() |
boolean |
isDraggrable()
Deprecated.
will be removed is 1.2
|
boolean |
isModal() |
JsStatement |
isOpen()
Method returning true if the dialog is currently open
|
boolean |
isResizable()
Returns
true if this window is resizable. |
boolean |
isStack() |
JsStatement |
moveToTop()
Method to move to top the dialog
|
void |
moveToTop(org.apache.wicket.ajax.AjaxRequestTarget ajaxRequestTarget)
Method to move to top the dialog within the ajax request
|
JsStatement |
open()
Method to open the dialog
|
void |
open(org.apache.wicket.ajax.AjaxRequestTarget ajaxRequestTarget)
Method to open the dialog within the ajax request
|
Dialog |
setAutoOpen(boolean autoOpen)
Sets if this window opens autmatically after the page is loaded.
|
Dialog |
setBeforeCloseEvent(JsScopeUiEvent beforeclose)
Deprecated.
will be removed when we will used jquery ui 1.9 (see ticket http://dev.jqueryui.com/ticket/4669)
|
Dialog |
setBgiframe(boolean bgiframe)
Deprecated.
will be removed in 1.3
|
Dialog |
setButtons(ListItemOptions<DialogButton> buttons)
Set's a list of dialog button
|
Dialog |
setCloseEvent(JsScopeUiEvent close)
Set's the callback before the dialog is closed.
|
Dialog |
setCloseOnEscape(boolean closeOnEscape)
Set's the close on escape keyboard shortcut
|
Dialog |
setCloseText(String closeText)
Sets a the text for the close button
|
Dialog |
setCssClass(String cssClass)
Sets a css class to customize the window's display.
|
Dialog |
setDialogClass(String dialogClass)
The specified class name(s) will be added to the dialog, for additional theming.
|
Dialog |
setDisabled(boolean disabled)
Disables (true) or enables (false) the dialog.
|
Dialog |
setDragEvent(JsScopeUiEvent drag)
Set's the callback when the dialog is dragged.
|
Dialog |
setDraggable(boolean draggable)
Enable or disable the draggable event
|
Dialog |
setDragStartEvent(JsScopeUiEvent dragStart)
Set's the callback when the dialog is being dragged.
|
Dialog |
setDragStopEvent(JsScopeUiEvent dragStop)
Set's the callback when the dialog has been dragged.
|
Dialog |
setFocusEvent(JsScopeUiEvent focus)
Set's the callback when the dialog gains focus.
|
Dialog |
setHeight(int height)
Sets the window's height.
|
Dialog |
setHideEffect(String hideEffect)
Sets the effect used when the window closes.
|
Dialog |
setMaxHeight(int maxHeight)
Sets the window's max height.
|
Dialog |
setMaxWidth(int maxWidth)
Sets the window's max width.
|
Dialog |
setMinHeight(int minHeight)
Sets the window's min height.
|
Dialog |
setMinWidth(int minWidth)
Sets the window's min width.
|
Dialog |
setModal(boolean modal)
Sets if this window is modal or not.
|
Dialog |
setOpenEvent(JsScopeUiEvent open)
Set's the callback before the dialog is opening.
|
Dialog |
setOverlayRatio(float ratio)
Deprecated.
will be removed in 1.3
|
Dialog |
setPosition(Dialog.WindowPosition windowPosition)
Sets the window's position.
|
Dialog |
setResizable(boolean resizable)
Sets if this window is resizable or not.
|
Dialog |
setResizeEvent(JsScopeUiEvent resize)
Set's the callback when the dialog is resized.
|
Dialog |
setResizeStartEvent(JsScopeUiEvent resizeStart)
Set's the callback when the dialog is being resized.
|
Dialog |
setResizeStopEvent(JsScopeUiEvent resizeStop)
Set's the callback when the dialog has been resized.
|
Dialog |
setShowEffect(String hideEffect)
Sets the effect used when the window shows itself.
|
Dialog |
setStack(boolean stack)
Specifies whether the dialog will stack on top of other dialogs.
|
Dialog |
setTitle(org.apache.wicket.model.IModel<String> title)
Sets the window's title.
|
Dialog |
setTitle(String title)
Sets the window's title.
|
Dialog |
setWidth(int width)
Sets the window's width.
|
Dialog |
setZIndex(int zIndex)
Set's the starting z-index
|
JsStatement |
statement()
Returns the main
JsStatement used to create the plugin. |
JsStatement |
widget()
Method to returns the .ui-dialog element
|
void |
widget(org.apache.wicket.ajax.AjaxRequestTarget ajaxRequestTarget)
Method to returns the .ui-dialog element within the ajax request
|
getMarkupType, getWebPage, getWebRequestadd, addOrReplace, autoAdd, autoAdd, contains, findMarkupStream, get, get, getAssociatedMarkupStream, getMarkupStream, hasAssociatedMarkup, internalAdd, isTransparentResolver, iterator, iterator, newMarkupResourceStream, onAfterRenderChildren, onComponentTagBody, onRender, remove, remove, removeAll, renderAll, renderAssociatedMarkup, renderComponentTagBody, renderNext, replace, setDefaultModel, setMarkupStream, size, swap, toString, toString, visitChildren, visitChildrenadd, addStateChange, afterRender, beforeRender, callOnBeforeRenderIfNotVisible, checkComponentTag, checkComponentTagAttribute, checkHierarchyChange, configure, continueToOriginalDestination, debug, detach, detachBehaviors, detachModels, determineVisibility, error, exceptionMessage, fatal, findPage, findParent, findParentWithAssociatedMarkup, getAjaxRegionMarkupId, getApplication, getBehaviors, getBehaviors, getBehaviorsRawList, getClassRelativePath, getComponentBorder, getConverter, getConverter, getDefaultModel, getDefaultModelObject, getDefaultModelObjectAsString, getDefaultModelObjectAsString, getEscapeModelStrings, getFeedbackMessage, getFlag, getFlag, getId, getInnermostModel, getInnermostModel, getLocale, getLocalizer, getMarkupAttributes, getMarkupId, getMarkupId, getMarkupIdImpl, getMetaData, getModelComparator, getOutputMarkupId, getOutputMarkupPlaceholderTag, getPage, getPageRelativePath, getParent, getPath, getRenderBodyOnly, getRequest, getRequestCycle, getResponse, getSession, getSizeInBytes, getStatelessHint, getString, getString, getString, getStyle, getVariation, hasBeenRendered, hasErrorMessage, hasFeedbackMessage, info, initModel, internalAttach, internalDetach, internalOnAttach, internalOnDetach, internalOnModelChanged, isActionAuthorized, isAncestorOf, isAttached, isBehaviorAccepted, isEnableAllowed, isEnabled, isEnabledInHierarchy, isIgnoreAttributeModifier, isRenderAllowed, isStateless, isVersioned, isVisibilityAllowed, isVisible, isVisibleInHierarchy, locateMarkupStream, markAttached, markRendering, modelChanged, modelChanging, onAfterRender, onAttach, onBeforeRender, onBeginRequest, onComponentTag, onConfigure, onDetach, onEndRequest, onInitialize, onModelChanged, onModelChanging, onRemove, prepareForRender, prepareForRender, redirectToInterceptPage, remove, remove, render, render, renderComponent, renderComponent, renderComponentTag, rendered, renderHead, renderPlaceholderTag, replaceComponentTagBody, replaceWith, sameInnermostModel, sameInnermostModel, setAuto, setComponentBorder, setDefaultModelObject, setEnabled, setEscapeModelStrings, setFlag, setFlag, setIgnoreAttributeModifier, setMarkupId, setMarkupIdImpl, setMetaData, setOutputMarkupId, setOutputMarkupPlaceholderTag, setRedirect, setRenderBodyOnly, setResponsePage, setResponsePage, setResponsePage, setVersioned, setVisibilityAllowed, setVisible, urlFor, urlFor, urlFor, urlFor, urlFor, urlFor, visitParents, warn, wrapprotected void detachModel()
detachModel in class org.apache.wicket.Componentpublic void contribute(WiQueryResourceManager wiQueryResourceManager)
contribute in interface IWiQueryPluginwiQueryResourceManager - The WiQueryResourceManager instance managing this
component resources.IWiQueryPlugin.contribute(org.odlabs.wiquery.core.commons.WiQueryResourceManager)public JsStatement statement()
IWiQueryPluginJsStatement used to create the plugin.statement in interface IWiQueryPluginJsStatement corresponding to this component.protected Options getOptions()
public JsStatement open()
public JsStatement close()
public void open(org.apache.wicket.ajax.AjaxRequestTarget ajaxRequestTarget)
ajaxRequestTarget - public void close(org.apache.wicket.ajax.AjaxRequestTarget ajaxRequestTarget)
ajaxRequestTarget - public Dialog setAutoOpen(boolean autoOpen)
autoOpen - true if the window auto opens, false otherwisepublic Dialog setModal(boolean modal)
modal - true if the window is modal, false otherwisepublic Dialog setOverlayRatio(float ratio)
setModal(boolean) method is call with true.ratio - a float value between 0 and 1 (1 is 100% black overlay)public boolean isAutoOpen()
public boolean isModal()
public Dialog setWidth(int width)
public int getWidth()
public Dialog setHeight(int height)
public int getHeight()
public Dialog setPosition(Dialog.WindowPosition windowPosition)
public Dialog.WindowPosition getPosition()
Dialog.WindowPosition.public Dialog setCloseText(String closeText)
public String getCloseText()
public Dialog setCssClass(String cssClass)
public String getCssClass()
public Dialog setHideEffect(String hideEffect)
a - String with the given effect's name.public String getHideEffect()
public Dialog setShowEffect(String hideEffect)
a - String with the given effect's name.public String getShowEffect()
public Dialog setMaxHeight(int maxHeight)
public int getMaxHeight()
public Dialog setMaxWidth(int maxWidth)
public int getMaxWidth()
public Dialog setMinHeight(int minHeight)
public int getMinHeight()
public Dialog setMinWidth(int minWidth)
public int getMinWidth()
public Dialog setResizable(boolean resizable)
public boolean isResizable()
true if this window is resizable.public Dialog setTitle(String title)
Note: the title can be automatically sets when the HTML
title attribute is set.
public Dialog setTitle(org.apache.wicket.model.IModel<String> title)
Note: the title can be automatically sets when the HTML
title attribute is set.
public String getTitle()
String containing the window's title.public Dialog setCloseOnEscape(boolean closeOnEscape)
closeOnEscape - public boolean isCloseOnEscape()
public Dialog setBgiframe(boolean bgiframe)
bgiframe - public boolean isBgiframe()
public Dialog setDialogClass(String dialogClass)
public String getDialogClass()
public Dialog setDisabled(boolean disabled)
disabled - public boolean isDisabled()
public Dialog setDraggable(boolean draggable)
draggable - public boolean isDraggable()
@Deprecated public boolean isDraggrable()
public Dialog setStack(boolean stack)
stack - public boolean isStack()
public Dialog setZIndex(int zIndex)
zIndex - public int getZIndex()
public Dialog setButtons(ListItemOptions<DialogButton> buttons)
buttons - public ListItemOptions<DialogButton> getButtons()
@Deprecated public Dialog setBeforeCloseEvent(JsScopeUiEvent beforeclose)
beforeclose - public Dialog setCloseEvent(JsScopeUiEvent close)
close - public Dialog setDragEvent(JsScopeUiEvent drag)
drag - public Dialog setDragStartEvent(JsScopeUiEvent dragStart)
dragStart - public Dialog setDragStopEvent(JsScopeUiEvent dragStop)
dragStop - public Dialog setFocusEvent(JsScopeUiEvent focus)
focus - public Dialog setOpenEvent(JsScopeUiEvent open)
open - public Dialog setResizeEvent(JsScopeUiEvent resize)
resize - public Dialog setResizeStartEvent(JsScopeUiEvent resizeStart)
resizeStart - public Dialog setResizeStopEvent(JsScopeUiEvent resizeStop)
resizeStop - public JsStatement destroy()
public void destroy(org.apache.wicket.ajax.AjaxRequestTarget ajaxRequestTarget)
ajaxRequestTarget - public JsStatement disable()
public void disable(org.apache.wicket.ajax.AjaxRequestTarget ajaxRequestTarget)
ajaxRequestTarget - public JsStatement enable()
public void enable(org.apache.wicket.ajax.AjaxRequestTarget ajaxRequestTarget)
ajaxRequestTarget - public JsStatement isOpen()
public JsStatement moveToTop()
public void moveToTop(org.apache.wicket.ajax.AjaxRequestTarget ajaxRequestTarget)
ajaxRequestTarget - public JsStatement widget()
public void widget(org.apache.wicket.ajax.AjaxRequestTarget ajaxRequestTarget)
ajaxRequestTarget - Copyright © 2009-2012. All Rights Reserved.