VALUE
- is the generic type of the changed value.public abstract class UiWidgetAdapterGwtRadioButtons<VALUE> extends UiWidgetAdapterGwtField<com.google.gwt.user.client.ui.ComplexPanel,VALUE,String> implements UiWidgetAdapterRadioButtonsField<VALUE>, com.google.gwt.event.dom.client.ClickHandler, com.google.gwt.user.client.TakesValue<String>
UiWidgetAdapterRadioButtonsField
using GWT based on a
ComplexPanel
and RadioButton
s.Modifier and Type | Field and Description |
---|---|
private char |
accessKey |
private String |
groupId
The unique group ID for the
RadioButton s. |
private List<String> |
options |
private List<com.google.gwt.user.client.ui.RadioButton> |
radioButtons |
TAB_INDEX_NONE
HTML_ATTRIBUTE_ID, ID_SEPARATOR, PROPERTY_ID
PROPERTY_STYLES, STYLE_PATTERN_MULTIPLE, STYLE_PATTERN_SINGLE
WAI_ARIA
ACCESS_KEY_NONE, HTML_ATTRIBUTE_ACCESS_KEY
PROPERTY_LABEL
ATTRIBUTE_COLSPAN
Constructor and Description |
---|
UiWidgetAdapterGwtRadioButtons()
The constructor.
|
Modifier and Type | Method and Description |
---|---|
protected void |
applyEventAdapterForChange(EventAdapterGwt adapter)
Applies for
EventType.VALUE_CHANGE events. |
protected void |
applyEventAdapterForClick(EventAdapterGwt adapter)
Applies for
EventType.CLICK events. |
protected void |
applyEventAdapterForFocus(EventAdapterGwt adapter)
Applies for
EventType.FOCUS_GAIN and
EventType.FOCUS_LOSS events. |
protected com.google.gwt.user.client.ui.ComplexPanel |
createActiveWidget() |
protected EventAdapterGwt |
createEventAdapter(UiFeatureEvent source,
UiHandlerEvent sender)
This method creates the
AbstractUiWidgetAdapterWithEvents.getEventAdapter() instance. |
protected abstract com.google.gwt.user.client.ui.ComplexPanel |
doCreateActiveWidget() |
List<String> |
getOptions()
This method gets the options of this object.
|
String |
getValue()
This method gets the value of this object.
|
protected com.google.gwt.user.client.ui.Focusable |
getWidgetAsFocusable() |
protected com.google.gwt.event.dom.client.HasAllFocusHandlers |
getWidgetAsHasAllFocusHandlers() |
protected com.google.gwt.event.dom.client.HasChangeHandlers |
getWidgetAsHasChangeHandlers() |
protected com.google.gwt.event.dom.client.HasKeyPressHandlers |
getWidgetAsKeyPressHandlers() |
protected com.google.gwt.user.client.TakesValue<String> |
getWidgetAsTakesValue() |
protected com.google.gwt.user.client.TakesValue<String> |
getWidgetAsTakesValueString() |
void |
onClick(com.google.gwt.event.dom.client.ClickEvent event) |
void |
setAccessKey(char accessKey)
This method sets the
accessKey attribute of this object. |
void |
setEnabled(boolean enabled)
This method sets the
enabled status of this object. |
void |
setOptions(List<String> options)
This method sets the
options of this object. |
void |
setValue(String value)
This method sets the
value . |
attachActiveWidget, convertValueToString, createToplevelWidget, createViewWidget, getActiveWidget, getInputElement, getMaximumValue, getMinimumValue, getValueAsString, getWidgetViewMode, setAdapterValueInViewMode, setMode, setValidationFailure, setValueAsString, setValueInViewMode, updateWidgetViewMode
getKeyboardFilter, getWidgetAsHasBlurHandlers, getWidgetAsHasFocusHandlers, setClickEventSender, setFocused, setKeyboardFilter
dispose, removeFromParent
addHandlerRegistration, addStyle, createAbsoluteImageUrl, getHeightInPixel, getImage, getImageParentElement, getLength, getSizeElement, getToplevelWidget, getToplevelWidget, getWidthInPixel, isStyleDeltaSupported, removeStyle, setAttribute, setId, setImage, setLength, setPrimaryStyle, setStyles, setTooltip, setVisible
applyEventAdapter, applyEventAdapterForSelection, getEventAdapter, setEventSender
createLabel, getAccessKey, getAltText, getAttribute, getBundle, getColumnSpan, getContext, getHeightInRows, getId, getLabel, getMaximumTextLength, getPrimaryStyle, getSelectionMode, getStyles, getTitle, getTooltip, getToplevelWidget, getUiWidget, getUiWidgetTyped, getUrl, getValidationFailure, hasStyle, isDisposed, isEnabled, isFocused, isResizable, setParent, setUiWidget
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
createAbsoluteImageUrl, createLabel, getToplevelWidget, isStyleDeltaSupported, removeFromParent, setEventSender, setMode, setParent, setVisible
setId
getId
setTooltip
getTooltip
isEnabled
addStyle, removeStyle
hasStyle
setStyles
getStyles
setPrimaryStyle
getPrimaryStyle
dispose
isDisposed
setLength
getLength
getHeightInPixel, getWidthInPixel
getAttribute
setAttribute
isFocused
setFocused
getAccessKey
setValueAsString
getValueAsString
setValidationFailure
getValidationFailure
private final List<com.google.gwt.user.client.ui.RadioButton> radioButtons
setOptions(List)
private final String groupId
RadioButton
s.private List<String> options
setOptions(List)
private char accessKey
setOptions(List)
public UiWidgetAdapterGwtRadioButtons()
protected com.google.gwt.event.dom.client.HasChangeHandlers getWidgetAsHasChangeHandlers()
getWidgetAsHasChangeHandlers
in class UiWidgetAdapterGwtField<com.google.gwt.user.client.ui.ComplexPanel,VALUE,String>
widget
as HasChangeHandlers
or null
if NOT
supported.protected com.google.gwt.event.dom.client.HasKeyPressHandlers getWidgetAsKeyPressHandlers()
getWidgetAsKeyPressHandlers
in class UiWidgetAdapterGwtWidgetActive<com.google.gwt.user.client.ui.Widget>
widget
as HasKeyPressHandlers
or null
if
NOT supported.protected com.google.gwt.user.client.ui.Focusable getWidgetAsFocusable()
getWidgetAsFocusable
in class UiWidgetAdapterGwtWidgetActive<com.google.gwt.user.client.ui.Widget>
widget
as Focusable
or null
if NOT
supported.protected com.google.gwt.event.dom.client.HasAllFocusHandlers getWidgetAsHasAllFocusHandlers()
getWidgetAsHasAllFocusHandlers
in class UiWidgetAdapterGwtWidgetActive<com.google.gwt.user.client.ui.Widget>
widget
as HasAllFocusHandlers
or null
if
NOT supported.protected com.google.gwt.user.client.TakesValue<String> getWidgetAsTakesValue()
getWidgetAsTakesValue
in class UiWidgetAdapterGwtField<com.google.gwt.user.client.ui.ComplexPanel,VALUE,String>
widget
as TakesValue
.protected com.google.gwt.user.client.TakesValue<String> getWidgetAsTakesValueString()
getWidgetAsTakesValueString
in class UiWidgetAdapterGwtField<com.google.gwt.user.client.ui.ComplexPanel,VALUE,String>
widget
as TakesValue
for the value type String
.public List<String> getOptions()
List
shall not contain duplicate entries. It may contain the value
null
.getOptions
in interface AttributeReadOptions<String>
List
with all available options.protected final com.google.gwt.user.client.ui.ComplexPanel createActiveWidget()
createActiveWidget
in class UiWidgetAdapterGwtField<com.google.gwt.user.client.ui.ComplexPanel,VALUE,String>
Widget
that is used to display and modify the field value in
edit-mode
.protected abstract com.google.gwt.user.client.ui.ComplexPanel doCreateActiveWidget()
active widget
.createActiveWidget()
public void setOptions(List<String> options)
options
of this object. The options will be presented in their
order specified by the given List
.setOptions
in interface AttributeWriteOptions<String>
options
- is the new List
of available options
.public String getValue()
getValue
in interface com.google.gwt.user.client.TakesValue<String>
getValue
in interface AttributeReadValue<String>
getValue
in class UiWidgetAdapterGwtField<com.google.gwt.user.client.ui.ComplexPanel,VALUE,String>
null
unless otherwise stated.public void setValue(String value)
value
.setValue
in interface com.google.gwt.user.client.TakesValue<String>
setValue
in interface AttributeWriteValue<String>
setValue
in class UiWidgetAdapterGwtField<com.google.gwt.user.client.ui.ComplexPanel,VALUE,String>
value
- is the new value
. May be null
unless otherwise stated.protected EventAdapterGwt createEventAdapter(UiFeatureEvent source, UiHandlerEvent sender)
AbstractUiWidgetAdapterWithEvents.getEventAdapter()
instance. It should to be implemented by the top-level
widget-adapter class specific for a native UI toolkit. It may further be overridden to use a sub-class
instead when more specific behavior is needed.createEventAdapter
in class UiWidgetAdapterGwt<com.google.gwt.user.client.ui.Widget>
source
- is the source of the events (typically UiWidget
).sender
- is the sender of events (an adapter that delegates to the individual handlers/listeners).event adapter
.protected void applyEventAdapterForFocus(EventAdapterGwt adapter)
EventType.FOCUS_GAIN
and
EventType.FOCUS_LOSS
events.applyEventAdapterForFocus
in class UiWidgetAdapterGwtWidgetActive<com.google.gwt.user.client.ui.Widget>
adapter
- is the event adapter
.protected void applyEventAdapterForChange(EventAdapterGwt adapter)
EventType.VALUE_CHANGE
events.applyEventAdapterForChange
in class UiWidgetAdapterGwtField<com.google.gwt.user.client.ui.ComplexPanel,VALUE,String>
adapter
- is the event adapter
.protected void applyEventAdapterForClick(EventAdapterGwt adapter)
EventType.CLICK
events.applyEventAdapterForClick
in class UiWidgetAdapterGwtWidgetActive<com.google.gwt.user.client.ui.Widget>
adapter
- is the event adapter
.public void setEnabled(boolean enabled)
enabled
status of this object. If it is disabled, the user can
not interact with the object.setEnabled
in interface AttributeWriteEnabled
enabled
- - if true
the object will be enabled, else the object will be disabled.public void setAccessKey(char accessKey)
accessKey
attribute of this object.setAccessKey
in interface AttributeWriteAccessKey
setAccessKey
in class UiWidgetAdapterGwtWidgetActive<com.google.gwt.user.client.ui.Widget>
accessKey
- is the new value of AttributeReadAccessKey.getAccessKey()
. Use AttributeReadAccessKey.ACCESS_KEY_NONE
to unset.public void onClick(com.google.gwt.event.dom.client.ClickEvent event)
onClick
in interface com.google.gwt.event.dom.client.ClickHandler
Copyright © 2001–2016 mmm-Team. All rights reserved.