|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectwicket.Component
wicket.MarkupContainer
wicket.markup.html.WebMarkupContainer
wicket.markup.html.WebMarkupContainerWithAssociatedMarkup
wicket.markup.html.panel.Panel
wicket.extensions.markup.html.form.palette.Palette
Palette is a component that allows the user to easily select and order
multiple items by moving them from one select box into another.
Ajaxifying the palette: The palette itself cannot be
ajaxified because it is a panel and therefore does not receive any javascript
events. Instead ajax behaviors can be attached to the recorder component
which supports the javascript onchange event. The recorder
component can be retrieved via a call to getRecorderComponent().
Example:
Form form=new Form(...);
Palette palette=new Palette(...);
palette.getRecorderComponent().add(new AjaxFormComponentUpdatingBehavior("onchange") {...});
| Nested Class Summary |
| Nested classes inherited from class wicket.markup.html.WebMarkupContainerWithAssociatedMarkup |
wicket.markup.html.WebMarkupContainerWithAssociatedMarkup.HeaderPartContainer |
| Nested classes inherited from class wicket.Component |
wicket.Component.ComponentModelChange, wicket.Component.EnabledChange, wicket.Component.IVisitor, wicket.Component.VisibilityChange |
| Field Summary |
| Fields inherited from class wicket.Component |
ENABLE, FLAG_RESERVED1, FLAG_RESERVED2, FLAG_RESERVED3, FLAG_RESERVED4, FLAG_RESERVED5, FLAG_RESERVED6, FLAG_RESERVED7, FLAG_RESERVED8, PATH_SEPARATOR, RENDER |
| Constructor Summary | |
Palette(java.lang.String id,
wicket.model.IModel choicesModel,
wicket.markup.html.form.IChoiceRenderer choiceRenderer,
int rows,
boolean allowOrder)
|
|
Palette(java.lang.String id,
wicket.model.IModel model,
wicket.model.IModel choicesModel,
wicket.markup.html.form.IChoiceRenderer choiceRenderer,
int rows,
boolean allowOrder)
|
|
| Method Summary | |
protected java.lang.String |
buildJSCall(java.lang.String funcName)
builds javascript handler call |
java.lang.String |
getAddOnClickJS()
|
wicket.markup.html.form.IChoiceRenderer |
getChoiceRenderer()
|
java.util.Collection |
getChoices()
|
java.lang.String |
getChoicesOnFocusJS()
|
java.lang.String |
getDownOnClickJS()
|
java.util.Collection |
getModelCollection()
|
Recorder |
getRecorderComponent()
Returns recorder component. |
java.lang.String |
getRemoveOnClickJS()
|
int |
getRows()
|
java.util.Iterator |
getSelectedChoices()
|
java.lang.String |
getSelectionOnFocusJS()
|
java.util.Iterator |
getUnselectedChoices()
|
java.lang.String |
getUpOnClickJS()
|
protected void |
internalOnDetach()
|
boolean |
isPaletteEnabled()
Return true if the palette is enabled, false otherwise |
protected wicket.Component |
newAddComponent()
factory method for the addcomponent |
protected wicket.Component |
newAvailableHeader(java.lang.String componentId)
factory method for the available items header |
protected wicket.Component |
newChoicesComponent()
factory method for the available items component |
protected wicket.Component |
newDownComponent()
factory method for the move down component |
protected wicket.Component |
newRemoveComponent()
factory method for the remove component |
protected wicket.Component |
newSelectedHeader(java.lang.String componentId)
factory method for the selected items header |
protected wicket.Component |
newSelectionComponent()
factory method for the selected items component |
protected wicket.Component |
newUpComponent()
factory method for the move up component |
protected void |
updateModel()
update the model upon form processing |
| Methods inherited from class wicket.markup.html.panel.Panel |
onComponentTag, onComponentTagBody, renderHead |
| Methods inherited from class wicket.markup.html.WebMarkupContainerWithAssociatedMarkup |
newHeaderPartContainer, renderHeadFromAssociatedMarkupFile |
| Methods inherited from class wicket.markup.html.WebMarkupContainer |
getMarkupType, getWebPage |
| Methods inherited from class wicket.MarkupContainer |
add, autoAdd, contains, findMarkupStream, get, getAssociatedMarkupStream, getMarkupStream, internalAdd, internalAttach, internalDetach, isTransparentResolver, iterator, iterator, newMarkupResourceStream, onRender, remove, remove, removeAll, renderAll, renderAssociatedMarkup, renderComponentTagBody, replace, setMarkupStream, setModel, size, toString, toString, visitChildren, visitChildren |
| Methods inherited from class wicket.Component |
add, addStateChange, checkComponentTag, checkComponentTagAttribute, continueToOriginalDestination, debug, detachBehaviors, detachModel, detachModels, error, exceptionMessage, fatal, findPage, findParent, findParentWithAssociatedMarkup, getApplication, getApplicationPages, getApplicationSettings, getBehaviors, getBehaviors, getClassRelativePath, getConverter, getEscapeModelStrings, getFeedbackMessage, getFlag, getFlag, getId, getLocale, getLocalizer, getMarkupAttributes, getMarkupId, getMetaData, getModel, getModelComparator, getModelObject, getModelObjectAsString, getOutputMarkupId, getPage, getPageFactory, getPageRelativePath, getParent, getPath, getRenderBodyOnly, getRequest, getRequestCycle, getResponse, getSession, getSizeInBytes, getString, getString, getString, getStyle, getVariation, hasErrorMessage, hasFeedbackMessage, info, initModel, internalOnAttach, internalOnModelChanged, isActionAuthorized, isAncestorOf, isBehaviorAccepted, isEnableAllowed, isEnabled, isHeadRendered, isIgnoreAttributeModifier, isRenderAllowed, isVersioned, isVisible, isVisibleInHierarchy, modelChanged, modelChanging, newPage, newPage, onAfterRender, onAttach, onBeforeRender, onBeginRequest, onDetach, onEndRequest, onModelChanged, onModelChanging, onRender, redirectToInterceptPage, remove, render, render, renderComponent, renderComponent, renderComponentTag, rendered, renderedBehaviors, replaceComponentTagBody, replaceWith, resetHeadRendered, sameRootModel, sameRootModel, setAuto, setEnabled, setEscapeModelStrings, setFlag, setFlag, setIgnoreAttributeModifier, setMetaData, setModelObject, setOutputMarkupId, setRedirect, setRenderBodyOnly, setResponsePage, setResponsePage, setResponsePage, setVersioned, setVisible, urlFor, urlFor, urlFor, urlFor, urlFor, visitParents, warn |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public Palette(java.lang.String id,
wicket.model.IModel choicesModel,
wicket.markup.html.form.IChoiceRenderer choiceRenderer,
int rows,
boolean allowOrder)
id - component idchoicesModel - model representing collection of all available choiceschoiceRenderer - render used to render choicesrows - number of choices to be visible on the screen with out
scrollingallowOrder - allow user to move selections up and down
public Palette(java.lang.String id,
wicket.model.IModel model,
wicket.model.IModel choicesModel,
wicket.markup.html.form.IChoiceRenderer choiceRenderer,
int rows,
boolean allowOrder)
id - component idmodel - model representing collection of user's selectionschoicesModel - model representing collection of all available choiceschoiceRenderer - render used to render choicesrows - number of choices to be visible on the screen with out
scrollingallowOrder - allow user to move selections up and down| Method Detail |
public final boolean isPaletteEnabled()
public java.util.Iterator getSelectedChoices()
public java.util.Iterator getUnselectedChoices()
protected wicket.Component newAvailableHeader(java.lang.String componentId)
componentId - component id of the returned header component
protected wicket.Component newSelectedHeader(java.lang.String componentId)
componentId - component id of the returned header component
protected wicket.Component newDownComponent()
protected wicket.Component newUpComponent()
protected wicket.Component newRemoveComponent()
protected wicket.Component newAddComponent()
protected wicket.Component newSelectionComponent()
protected wicket.Component newChoicesComponent()
public final Recorder getRecorderComponent()
onchange
javascript event whenever a change in selection occurs.
public java.util.Collection getChoices()
public java.util.Collection getModelCollection()
public wicket.markup.html.form.IChoiceRenderer getChoiceRenderer()
public int getRows()
protected final void updateModel()
protected java.lang.String buildJSCall(java.lang.String funcName)
funcName - name of javascript function to call
public java.lang.String getChoicesOnFocusJS()
public java.lang.String getSelectionOnFocusJS()
public java.lang.String getAddOnClickJS()
public java.lang.String getRemoveOnClickJS()
public java.lang.String getUpOnClickJS()
public java.lang.String getDownOnClickJS()
protected void internalOnDetach()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||