|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.wicket.Component
org.apache.wicket.MarkupContainer
org.apache.wicket.markup.html.WebMarkupContainer
org.apache.wicket.markup.html.panel.Panel
com.googlecode.wicket.jquery.core.JQueryPanel
com.googlecode.wicket.jquery.ui.widget.dialog.AbstractDialog<T>
T
- the type of the model objectpublic abstract class AbstractDialog<T extends Serializable>
Base class for implementing jQuery dialogs
Nested Class Summary |
---|
Nested classes/interfaces inherited from interface com.googlecode.wicket.jquery.core.IJQueryWidget |
---|
IJQueryWidget.JQueryWidget |
Field Summary | |
---|---|
static String |
LBL_CANCEL
|
static String |
LBL_CLOSE
|
static String |
LBL_NO
|
static String |
LBL_OK
|
static String |
LBL_SUBMIT
|
static String |
LBL_YES
|
Fields inherited from class com.googlecode.wicket.jquery.core.JQueryPanel |
---|
options |
Fields inherited from class org.apache.wicket.markup.html.panel.Panel |
---|
PANEL |
Fields inherited from class org.apache.wicket.Component |
---|
ENABLE, FLAG_INITIALIZED, FLAG_REMOVING_FROM_HIERARCHY, FLAG_RESERVED1, FLAG_RESERVED2, FLAG_RESERVED3, FLAG_RESERVED4, FLAG_RESERVED5, FLAG_RESERVED8, PARENT_PATH, PATH_SEPARATOR, RENDER |
Constructor Summary | |
---|---|
AbstractDialog(String id,
org.apache.wicket.model.IModel<String> title)
Constructor |
|
AbstractDialog(String id,
org.apache.wicket.model.IModel<String> title,
boolean modal)
Constructor |
|
AbstractDialog(String id,
org.apache.wicket.model.IModel<String> title,
org.apache.wicket.model.IModel<T> model)
Constructor |
|
AbstractDialog(String id,
org.apache.wicket.model.IModel<String> title,
org.apache.wicket.model.IModel<T> model,
boolean modal)
Constructor |
|
AbstractDialog(String id,
String title)
Constructor |
|
AbstractDialog(String id,
String title,
boolean modal)
Constructor |
|
AbstractDialog(String id,
String title,
org.apache.wicket.model.IModel<T> model)
Constructor |
|
AbstractDialog(String id,
String title,
org.apache.wicket.model.IModel<T> model,
boolean modal)
Constructor |
Method Summary | |
---|---|
void |
close(org.apache.wicket.ajax.AjaxRequestTarget target,
DialogButton button)
Closes the dialogs in ajax. |
DialogButton |
findButton(String text)
Finds a DialogButton - identified by its text - within the list of buttons returned by getButtons() |
protected List<DialogButton> |
getButtons()
Gets the dialog's buttons. It is allowed to return a predefined list (ie: DialogButtons#OK_CANCEL#toList()) as long as the buttons state (enable and/or visible) are not modified Warning: It is not legal to create the buttons to be returned in this method. |
org.apache.wicket.model.IModel<T> |
getModel()
Gets the model |
T |
getModelObject()
Gets the model object |
org.apache.wicket.model.IModel<String> |
getTitle()
Gets the dialog's title |
int |
getWidth()
Gets the dialog's with |
boolean |
isDefaultCloseEventEnabled()
Indicates whether the default close event (the click on the X-icon) is enabled If true, the onClose(AjaxRequestTarget, DialogButton) event will be triggered, with a null DialogButton |
boolean |
isModal()
Gets the modal flag |
boolean |
isResizable()
Gets the resizable flag |
protected DialogBehavior.ButtonAjaxBehavior |
newButtonAjaxBehavior(IJQueryAjaxAware source,
DialogButton button)
Gets a new DialogBehavior.ButtonAjaxBehavior that will be called by the corresponding DialogButton .This method mays be overridden internally to provide another behavior |
DialogBehavior |
newWidgetBehavior(String selector)
|
void |
onClick(org.apache.wicket.ajax.AjaxRequestTarget target,
DialogButton button)
Triggered when a button is clicked. |
void |
onClose(org.apache.wicket.ajax.AjaxRequestTarget target,
DialogButton button)
Triggered when the dialog closes. |
protected void |
onConfigure(JQueryBehavior behavior)
Called immediately after the onConfigure method in a behavior. |
protected void |
onInitialize()
|
protected void |
onOpen(org.apache.wicket.ajax.AjaxRequestTarget target)
Triggered when the dialog opens |
void |
open(org.apache.wicket.ajax.AjaxRequestTarget target)
Opens the dialogs in ajax. |
void |
setModelObject(T object)
Sets the model object |
void |
setTitle(org.apache.wicket.model.IModel<String> title)
Sets the dialog's title |
Methods inherited from class org.apache.wicket.markup.html.panel.Panel |
---|
newMarkupSourcingStrategy |
Methods inherited from class org.apache.wicket.markup.html.WebMarkupContainer |
---|
getWebPage, getWebRequest, getWebResponse, getWebSession |
Methods inherited from class org.apache.wicket.MarkupContainer |
---|
add, addOrReplace, autoAdd, contains, get, get, getAssociatedMarkup, getAssociatedMarkupStream, getMarkup, getMarkupType, internalAdd, internalInitialize, iterator, iterator, onAfterRenderChildren, onComponentTagBody, onRender, remove, remove, removeAll, renderAll, renderAssociatedMarkup, renderNext, replace, setDefaultModel, size, swap, toString, toString, visitChildren, visitChildren, visitChildren, visitChildren |
Methods inherited from class org.apache.wicket.Component |
---|
add, addStateChange, afterRender, beforeRender, canCallListenerInterface, checkComponentTag, checkComponentTagAttribute, checkHierarchyChange, clearOriginalDestination, configure, continueToOriginalDestination, debug, detach, detachModel, detachModels, determineVisibility, error, exceptionMessage, fatal, findMarkupStream, findPage, findParent, findParentWithAssociatedMarkup, getAjaxRegionMarkupId, getApplication, getBehaviorById, getBehaviorId, getBehaviors, getBehaviors, getClassRelativePath, getConverter, getDefaultModel, getDefaultModelObject, getDefaultModelObjectAsString, getDefaultModelObjectAsString, getEscapeModelStrings, getFeedbackMessages, getFlag, getId, getInnermostModel, getInnermostModel, getLocale, getLocalizer, getMarkup, getMarkupAttributes, getMarkupId, getMarkupId, getMarkupIdFromMarkup, getMarkupIdImpl, getMarkupSourcingStrategy, getMetaData, getModelComparator, getOutputMarkupId, getOutputMarkupPlaceholderTag, getPage, getPageRelativePath, getParent, getPath, getRenderBodyOnly, getRequest, getRequestCycle, getRequestFlag, getResponse, getSession, getSizeInBytes, getStatelessHint, getString, getString, getString, getStyle, getVariation, hasBeenRendered, hasErrorMessage, hasFeedbackMessage, info, initModel, internalOnModelChanged, internalPrepareForRender, internalRenderComponent, isActionAuthorized, isAuto, isBehaviorAccepted, isEnableAllowed, isEnabled, isEnabledInHierarchy, isIgnoreAttributeModifier, isRenderAllowed, isStateless, isVersioned, isVisibilityAllowed, isVisible, isVisibleInHierarchy, markRendering, modelChanged, modelChanging, onAfterRender, onBeforeRender, onComponentTag, onConfigure, onDetach, onEvent, onModelChanged, onModelChanging, onRemove, prepareForRender, redirectToInterceptPage, remove, remove, render, renderComponentTag, rendered, renderHead, renderHead, renderHead, renderPlaceholderTag, replaceComponentTagBody, replaceWith, sameInnermostModel, sameInnermostModel, send, setAuto, setDefaultModelObject, setEnabled, setEscapeModelStrings, setFlag, setIgnoreAttributeModifier, setMarkup, setMarkupId, setMarkupIdImpl, setMetaData, setOutputMarkupId, setOutputMarkupPlaceholderTag, setParent, setRenderBodyOnly, setRequestFlag, setResponsePage, setResponsePage, setResponsePage, setVersioned, setVisibilityAllowed, setVisible, success, urlFor, urlFor, urlFor, urlFor, urlFor, visitParents, visitParents, warn, wrap |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final String LBL_OK
public static final String LBL_NO
public static final String LBL_YES
public static final String LBL_CLOSE
public static final String LBL_CANCEL
public static final String LBL_SUBMIT
Constructor Detail |
---|
public AbstractDialog(String id, String title)
id
- the markupId, an html div suffice to host a dialog.title
- the title of the dialogpublic AbstractDialog(String id, org.apache.wicket.model.IModel<String> title)
id
- the markupId, an html div suffice to host a dialog.title
- the title of the dialogpublic AbstractDialog(String id, String title, org.apache.wicket.model.IModel<T> model)
id
- the markupId, an html div suffice to host a dialog.title
- the title of the dialogmodel
- the model to be used in the dialog.public AbstractDialog(String id, org.apache.wicket.model.IModel<String> title, org.apache.wicket.model.IModel<T> model)
id
- the markupId, an html div suffice to host a dialog.title
- the title of the dialogmodel
- the model to be used in the dialog.public AbstractDialog(String id, String title, boolean modal)
id
- the markupId, an html div suffice to host a dialog.title
- the title of the dialogmodal
- indicates whether the dialog is modalpublic AbstractDialog(String id, org.apache.wicket.model.IModel<String> title, boolean modal)
id
- the markupId, an html div suffice to host a dialog.title
- the title of the dialogmodal
- indicates whether the dialog is modalpublic AbstractDialog(String id, String title, org.apache.wicket.model.IModel<T> model, boolean modal)
id
- markupId, an html div suffice to host a dialog.title
- the title of the dialogmodal
- indicates whether the dialog is modalmodel
- the model to be used in the dialogpublic AbstractDialog(String id, org.apache.wicket.model.IModel<String> title, org.apache.wicket.model.IModel<T> model, boolean modal)
id
- markupId, an html div suffice to host a dialog.title
- the title of the dialogmodal
- indicates whether the dialog is modalmodel
- the model to be used in the dialogMethod Detail |
---|
protected void onInitialize()
onInitialize
in class org.apache.wicket.Component
protected void onConfigure(JQueryBehavior behavior)
Options
)
behavior
- the JQueryBehavior
protected void onOpen(org.apache.wicket.ajax.AjaxRequestTarget target)
target
- the AjaxRequestTarget
public void onClick(org.apache.wicket.ajax.AjaxRequestTarget target, DialogButton button)
super.onClick(event)
or close(AjaxRequestTarget, DialogButton)
is called.
target
- the AjaxRequestTarget
button
- the button that closed the dialogprotected List<DialogButton> getButtons()
btnOk
by defaultpublic int getWidth()
WIDTH
by defaultpublic org.apache.wicket.model.IModel<String> getTitle()
public void setTitle(org.apache.wicket.model.IModel<String> title)
title
- the dialog's titlepublic boolean isModal()
public boolean isResizable()
public boolean isDefaultCloseEventEnabled()
onClose(AjaxRequestTarget, DialogButton)
event will be triggered, with a null DialogButton
public org.apache.wicket.model.IModel<T> getModel()
public T getModelObject()
public void setModelObject(T object)
object
- the typed model objectpublic DialogButton findButton(String text)
DialogButton
- identified by its text - within the list of buttons returned by getButtons()
text
- the button's text
DialogButton
if found, null otherwisepublic final void open(org.apache.wicket.ajax.AjaxRequestTarget target)
target
- the AjaxRequestTarget
public final void close(org.apache.wicket.ajax.AjaxRequestTarget target, DialogButton button)
target
- the AjaxRequestTarget
button
- the button that closes the dialogpublic DialogBehavior newWidgetBehavior(String selector)
newWidgetBehavior
in interface IJQueryWidget
IJQueryWidget.newWidgetBehavior(String)
protected DialogBehavior.ButtonAjaxBehavior newButtonAjaxBehavior(IJQueryAjaxAware source, DialogButton button)
DialogBehavior.ButtonAjaxBehavior
that will be called by the corresponding DialogButton
.
button
- the button that is passed to the behavior so it can be retrieved via the DialogBehavior#ClickEvent
public void onClose(org.apache.wicket.ajax.AjaxRequestTarget target, DialogButton button)
target
- the AjaxRequestTarget
button
- the button that closed the dialog
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |