M
- the model typeT
- the type displayed in the list viewpublic class DualListField<M,T> extends AdapterField<List<M>>
Modifier and Type | Class and Description |
---|---|
static interface |
DualListField.DualListFieldAppearance |
protected class |
DualListField.DualListFieldDefaultMessages |
static interface |
DualListField.DualListFieldMessages
The locale-sensitive messages used by this class.
|
static class |
DualListField.Mode
The DND mode enumeration.
|
Modifier and Type | Field and Description |
---|---|
protected IconButton |
allLeft |
protected IconButton |
allRight |
protected IconButton |
down |
protected IconButton |
left |
protected DualListField.Mode |
mode |
protected IconButton |
right |
protected ListViewDragSource<M> |
sourceFromField |
protected ListViewDragSource<M> |
sourceToField |
protected ListViewDropTarget<M> |
targetFromField |
protected ListViewDropTarget<M> |
targetToField |
protected IconButton |
up |
forceInvalidText, preventMark
resize, widget
forceLayoutCommand, forceLayoutOnResize, hadLayoutRunning, layoutCommand, layoutRequiredThisEventLoop, layoutRunning
adjustSize, allowTextSelection, cacheSizes, disableContextMenu, disabled, disabledStyle, ensureVisibilityOnSizing, height, hidden, lastSize, layer, mask, maskMessage, monitorWindowResize, pageX, pageY, resizeHandler, shim, tabIndex, toolTip, toolTipConfig, top, width, windowResizeDelay, windowResizeTask
Constructor and Description |
---|
DualListField(ListStore<M> fromStore,
ListStore<M> toStore,
ValueProvider<? super M,T> valueProvider,
<any> cell)
Creates a dual list field that allows selections to be moved between two
list views using buttons or by dragging and dropping selections.
|
DualListField(ListStore<M> fromStore,
ListStore<M> toStore,
ValueProvider<? super M,T> valueProvider,
<any> cell,
DualListField.DualListFieldAppearance appearance)
Creates a dual list field that allows selections to be moved between two
list views using buttons or by dragging and dropping selections.
|
DualListField(ModelKeyProvider<? super M> keyProvider,
ValueProvider<? super M,T> valueProvider,
<any> cell)
Creates a dual list field that allows selections to be moved between two
list views using buttons or by dragging and dropping selections
|
Modifier and Type | Method and Description |
---|---|
IconButton |
getAllLeftButton()
Returns the all left button.
|
IconButton |
getAllRightButton()
Returns the all right button.
|
DualListField.DualListFieldAppearance |
getAppearance() |
String |
getDndGroup()
Returns the DND group name.
|
IconButton |
getDownButton()
Returns the down button.
|
ListViewDragSource<M> |
getDragSourceFromField()
Returns the from field's drag source instance.
|
ListViewDragSource<M> |
getDragSourceToField()
Returns the to field's drag source instance.
|
ListViewDropTarget<M> |
getDropTargetFromField()
Returns the from field's drop target instance.
|
ListViewDropTarget<M> |
getDropTargetToField()
Returns the to field's drop target instance.
|
ListStore<M> |
getFromStore()
Returns the ListStore that manages the source of selectable items.
|
ListView<M,T> |
getFromView()
Returns the list view that provides the source of selectable items.
|
IconButton |
getLeftButton()
Returns the left icon button.
|
DualListField.DualListFieldMessages |
getMessages()
Returns the locale-sensitive messages used by this class.
|
DualListField.Mode |
getMode()
Returns the list field's mode.
|
IconButton |
getRightButton()
Returns the right button.
|
ListStore<M> |
getToStore()
Returns the ListStore that manages the destination for selectable items.
|
ListView<M,T> |
getToView()
Returns the list view that provides the destination for selectable items.
|
IconButton |
getUpButton()
Returns the up button.
|
List<M> |
getValue() |
boolean |
isEnableDnd()
Returns true if drag and drop is enabled.
|
protected void |
onAllLeft() |
protected void |
onAllRight() |
protected void |
onDisable() |
protected void |
onDown() |
protected void |
onEnable() |
protected void |
onLeft() |
protected void |
onResize(int width,
int height)
Called after the widget is resized, this method is empty by default but can be implemented by any subclass that
needs to perform custom logic after a resize occurs.
|
protected void |
onRight() |
protected void |
onUp() |
void |
setDndGroup(String group)
Sets the drag and drop group name.
|
void |
setEnableDnd(boolean enableDnd)
True to allow selections to be dragged and dropped between lists (defaults
to true).
|
void |
setMessages(DualListField.DualListFieldMessages messages)
Sets the local-sensitive messages used by this class.
|
void |
setMode(DualListField.Mode mode)
Specifies if selections are either inserted or appended when moving between
lists.
|
void |
setValue(List<M> value) |
addInvalidHandler, addValidator, addValidHandler, addValueChangeHandler, clear, clearInvalid, disable, enable, finishEditing, flush, forceInvalid, getErrors, getErrorSupport, getValidators, isValid, isValid, markInvalid, markInvalid, onFocus, onPropertyChange, removeValidator, reset, setDelegate, setErrorSupport, showErrors, validate, validate, validateValue
add, add, doLayout, getWidget, isResize, onRemove, setElement, setResize, setWidget, setWidget
applyLayout, applyLayout, forceLayout, forceLayoutOnChildren, forceLayoutOnChildren, getLeftRightMargins, getParentLayoutWidget, getSideMargins, getTopBottomMargins, isLayoutRunning, isOrWasLayoutRunning, isWidgetVisible, onBeforeDoLayout, onLoad, onResize
addAddHandler, addBeforeAddHandler, addBeforeRemoveHandler, addContainerHandler, addRemoveHandler, adjustIndex, adopt, checkIndexBoundsForInsertion, doAttachChildren, doDetachChildren, doPhysicalAttach, doPhysicalDetach, ensureGroupingHandlerRegistration, findWidget, getChildren, getContainerTarget, getItemByItemId, getWidget, getWidgetCount, getWidgetIndex, getWidgetIndex, insert, iterator, onInsert, onWidgetHide, onWidgetShow, orphan, remove, remove, remove
addBeforeHideHandler, addBeforeShowContextMenuHandler, addBeforeShowHandler, addBlurHandler, addDisableHandler, addEnableHandler, addFocusHandler, addHideHandler, addMoveHandler, addResizeHandler, addShowContextMenuHandler, addShowHandler, addStyleDependentName, addStyleOnOver, adjustPosition, adjustSize, applyState, assertAfterRender, assertPreRender, blur, clearSizeCache, disableContextMenu, disableEvents, enableEvents, fireCancellableEvent, fireEvent, focus, getData, getElement, getFocusEl, getFocusSupport, getHideMode, getId, getItemId, getOffsetHeight, getOffsetWidth, getPositionEl, getShadow, getShadowPosition, getStateId, getTabIndex, getToolTip, hide, hideShadow, hideToolTip, isAllowTextSelection, isAutoHeight, isAutoWidth, isDeferHeight, isEnabled, isMonitorWindowResize, isRendered, isStateful, isVisible, isVisible, mask, mask, notifyHide, notifyShow, onAfterFirstAttach, onAttach, onBlur, onBrowserEvent, onDetach, onHide, onHideContextMenu, onPosition, onRightClick, onShow, onShowContextMenu, onUnload, onWindowResize, removeStyleDependentName, removeStyleOnOver, removeToolTip, setAllowTextSelection, setBorders, setBounds, setBounds, setContextMenu, setData, setDeferHeight, setEnabled, setHeight, setHeight, setHideMode, setId, setItemId, setMonitorWindowResize, setPagePosition, setPixelSize, setPosition, setShadow, setShadowPosition, setSize, setStateful, setStateId, setStyleDependentName, setTabIndex, setToolTip, setToolTipConfig, setVisible, setWidth, setWidth, show, sync, syncSize, unmask
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
addBlurHandler
protected DualListField.Mode mode
protected ListViewDragSource<M> sourceFromField
protected ListViewDragSource<M> sourceToField
protected ListViewDropTarget<M> targetFromField
protected ListViewDropTarget<M> targetToField
protected IconButton up
protected IconButton allRight
protected IconButton right
protected IconButton left
protected IconButton allLeft
protected IconButton down
public DualListField(ModelKeyProvider<? super M> keyProvider, ValueProvider<? super M,T> valueProvider, <any> cell)
keyProvider
- the key provider to use to track itemsvalueProvider
- the interface to <M>
cell
- displays the data in the list views (e.g. TextCell
)public DualListField(ListStore<M> fromStore, ListStore<M> toStore, ValueProvider<? super M,T> valueProvider, <any> cell)
fromStore
- the store containing the base set of itemstoStore
- the store containing the items selected by the uservalueProvider
- the interface to <M>
cell
- displays the data in the list view (e.g. TextCell
)public DualListField(ListStore<M> fromStore, ListStore<M> toStore, ValueProvider<? super M,T> valueProvider, <any> cell, DualListField.DualListFieldAppearance appearance)
fromStore
- the store containing the base set of itemstoStore
- the store containing the items selected by the uservalueProvider
- the interface to <M>
cell
- displays the data in the list view (e.g. TextCell
)appearance
- the appearance instance to use when rendering this widgetpublic DualListField.DualListFieldAppearance getAppearance()
public String getDndGroup()
public ListViewDragSource<M> getDragSourceFromField()
public ListViewDragSource<M> getDragSourceToField()
public ListViewDropTarget<M> getDropTargetFromField()
public ListViewDropTarget<M> getDropTargetToField()
public ListView<M,T> getFromView()
public ListStore<M> getFromStore()
public DualListField.DualListFieldMessages getMessages()
public DualListField.Mode getMode()
public ListView<M,T> getToView()
public ListStore<M> getToStore()
public IconButton getLeftButton()
public IconButton getAllLeftButton()
public IconButton getRightButton()
public IconButton getAllRightButton()
public IconButton getUpButton()
public IconButton getDownButton()
public boolean isEnableDnd()
public void setDndGroup(String group)
group
- the group namepublic void setEnableDnd(boolean enableDnd)
enableDnd
- true to enable drag and droppublic void setMessages(DualListField.DualListFieldMessages messages)
messages
- the locale sensitive messages used by this class.public void setMode(DualListField.Mode mode)
mode
- the modeprotected void onAllLeft()
protected void onAllRight()
protected void onDown()
protected void onLeft()
protected void onResize(int width, int height)
Component
onResize
in class ResizeContainer
width
- the widthheight
- the heightprotected void onRight()
protected void onUp()
Copyright © 2018. All rights reserved.