|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.google.gwt.user.client.ui.UIObject
com.google.gwt.user.client.ui.Widget
com.google.gwt.user.client.ui.FocusWidget
com.google.gwt.user.client.ui.ButtonBase
com.google.gwt.user.client.ui.CheckBox
com.google.gwt.user.client.ui.RadioButton
public class RadioButton
A mutually-exclusive selection radio button widget.
public class RadioButtonExample implements EntryPoint {
public void onModuleLoad() {
// Make some radio buttons, all in one group.
RadioButton rb0 = new RadioButton("myRadioGroup", "foo");
RadioButton rb1 = new RadioButton("myRadioGroup", "bar");
RadioButton rb2 = new RadioButton("myRadioGroup", "baz");
// Check 'baz' by default.
rb2.setChecked(true);
// Add them to the root panel.
FlowPanel panel = new FlowPanel();
panel.add(rb0);
panel.add(rb1);
panel.add(rb2);
RootPanel.get().add(panel);
}
}
| Constructor Summary | |
|---|---|
RadioButton(java.lang.String name)
Creates a new radio associated with a particular group name. |
|
RadioButton(java.lang.String name,
java.lang.String label)
Creates a new radio associated with a particular group, and initialized with the given HTML label. |
|
RadioButton(java.lang.String name,
java.lang.String label,
boolean asHTML)
Creates a new radio button associated with a particular group, and initialized with the given label (optionally treated as HTML). |
|
| Method Summary | |
|---|---|
void |
setName(java.lang.String name)
Change the group name of this radio button. |
| Methods inherited from class com.google.gwt.user.client.ui.CheckBox |
|---|
getHTML, getName, getTabIndex, getText, isChecked, isEnabled, onLoad, onUnload, replaceInputElement, setAccessKey, setChecked, setEnabled, setFocus, setHTML, setTabIndex, setText |
| Methods inherited from class com.google.gwt.user.client.ui.FocusWidget |
|---|
addClickListener, addFocusListener, addKeyboardListener, getFocusImpl, onBrowserEvent, removeClickListener, removeFocusListener, removeKeyboardListener, setElement |
| Methods inherited from class com.google.gwt.user.client.ui.Widget |
|---|
doAttachChildren, doDetachChildren, getParent, isAttached, onAttach, onDetach, removeFromParent |
| Methods inherited from class com.google.gwt.user.client.ui.UIObject |
|---|
addStyleDependentName, addStyleName, getAbsoluteLeft, getAbsoluteTop, getElement, getOffsetHeight, getOffsetWidth, getStyleElement, getStyleName, getStyleName, getStylePrimaryName, getStylePrimaryName, getTitle, isVisible, isVisible, removeStyleDependentName, removeStyleName, setHeight, setPixelSize, setSize, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setTitle, setVisible, setVisible, setWidth, sinkEvents, toString, unsinkEvents |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public RadioButton(java.lang.String name)
name - the group name with which to associate the radio button
public RadioButton(java.lang.String name,
java.lang.String label)
name - the group name with which to associate the radio buttonlabel - this radio button's label
public RadioButton(java.lang.String name,
java.lang.String label,
boolean asHTML)
name - name the group with which to associate the radio buttonlabel - this radio button's labelasHTML - true to treat the specified label as HTML| Method Detail |
|---|
public void setName(java.lang.String name)
setName in interface HasNamesetName in class CheckBoxname - name the group with which to associate the radio button
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||