T
- the type of data being editedpublic class ValueBoxEditorDecorator<T> extends Composite implements HasEditorErrors<T>, IsEditor<ValueBoxEditor<T>>
The decorator may have exactly one ValueBoxBase added though an
<e:valuebox>
child tag.
For example:
@UiField ValueBoxEditorDecorator<String> name;
<e:ValueBoxEditorDecorator ui:field='name'> <e:valuebox> <g:TextBox /> </e:valuebox> </e:ValueBoxEditorDecorator>
Modifier and Type | Class and Description |
---|---|
(package private) static interface |
ValueBoxEditorDecorator.Binder |
UIObject.DebugIdImpl, UIObject.DebugIdImplEnabled
Editor.Ignore, Editor.Path
Modifier and Type | Field and Description |
---|---|
(package private) SimplePanel |
contents |
(package private) DivElement |
errorLabel |
DEBUG_ID_PREFIX
Constructor and Description |
---|
ValueBoxEditorDecorator()
Constructs a ValueBoxEditorDecorator.
|
ValueBoxEditorDecorator(ValueBoxBase<T> widget,
ValueBoxEditor<T> editor)
Constructs a ValueBoxEditorDecorator using a
ValueBoxBase
widget and a ValueBoxEditor editor. |
Modifier and Type | Method and Description |
---|---|
ValueBoxEditor<T> |
asEditor()
Returns the associated
ValueBoxEditor . |
void |
setEditor(ValueBoxEditor<T> editor)
Sets the associated
ValueBoxEditor . |
void |
setValueBox(ValueBoxBase<T> widget)
Set the widget that the EditorPanel will display.
|
void |
showErrors(java.util.List<EditorError> errors)
The default implementation will display, but not consume, received errors
whose
getEditor() method returns the Editor
passed into setEditor(com.google.gwt.editor.ui.client.adapters.ValueBoxEditor<T>) . |
claimElement, getWidget, initializeClaimedElement, initWidget, isAttached, onAttach, onBrowserEvent, onDetach, render, render, resolvePotentialElement, setWidget
addAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, createHandlerManager, delegateEvent, doAttachChildren, doDetachChildren, fireEvent, getHandlerCount, getLayoutData, getParent, isOrWasAttached, onLoad, onUnload, removeFromParent, setLayoutData, sinkEvents, unsinkEvents
addStyleDependentName, addStyleName, ensureDebugId, ensureDebugId, ensureDebugId, getAbsoluteLeft, getAbsoluteTop, getElement, getOffsetHeight, getOffsetWidth, getStyleElement, getStyleName, getStyleName, getStylePrimaryName, getStylePrimaryName, getTitle, isVisible, isVisible, onEnsureDebugId, removeStyleDependentName, removeStyleName, setElement, setElement, setHeight, setPixelSize, setSize, setStyleDependentName, setStyleName, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setTitle, setVisible, setVisible, setWidth, sinkBitlessEvent, toString
@UiField SimplePanel contents
@UiField DivElement errorLabel
@UiConstructor public ValueBoxEditorDecorator()
public ValueBoxEditorDecorator(ValueBoxBase<T> widget, ValueBoxEditor<T> editor)
ValueBoxBase
widget and a ValueBoxEditor
editor.widget
- the widgeteditor
- the editorpublic ValueBoxEditor<T> asEditor()
ValueBoxEditor
.asEditor
in interface IsEditor<ValueBoxEditor<T>>
ValueBoxEditor
instancesetEditor(ValueBoxEditor)
public void setEditor(ValueBoxEditor<T> editor)
ValueBoxEditor
.editor
- a ValueBoxEditor
instanceasEditor()
@UiChild(limit=1, tagname="valuebox") public void setValueBox(ValueBoxBase<T> widget)
setEditor(com.google.gwt.editor.ui.client.adapters.ValueBoxEditor<T>)
.widget
- a ValueBoxBase
widgetpublic void showErrors(java.util.List<EditorError> errors)
getEditor()
method returns the Editor
passed into setEditor(com.google.gwt.editor.ui.client.adapters.ValueBoxEditor<T>)
.showErrors
in interface HasEditorErrors<T>
errors
- a List of EditorError
instances