Example usage for Java com.google.gwt.user.client.ui ListBox fields, constructors, methods, implement or subclass
The text is from its open source code.
ListBox() Creates an empty list box in single selection mode. | |
ListBox(boolean isMultipleSelect) Creates an empty list box. | |
ListBox(Element element) This constructor may be used by subclasses to explicitly use an existing element. |
HandlerRegistration | addBlurHandler(BlurHandler handler) |
HandlerRegistration | addChangeHandler(ChangeHandler handler) |
void | addChangeListener(ChangeListener listener) |
HandlerRegistration | addClickHandler(ClickHandler handler) |
void | addClickListener(ClickListener listener) |
HandlerRegistration | addFocusHandler(FocusHandler handler) |
void | addItem(String item) Adds an item to the list box. |
void | addItem(String item, Direction dir) Adds an item to the list box, specifying its direction. |
void | addItem(String item, String value) Adds an item to the list box, specifying an initial value for the item. |
HandlerRegistration | addKeyDownHandler(KeyDownHandler handler) |
void | clear() Removes all items from the list box. |
int | getItemCount() Gets the number of items present in the list box. |
String | getItemText(int index) Gets the text associated with the item at the specified index. |
String | getName() |
int | getSelectedIndex() Gets the currently-selected item. |
String | getValue(int index) Gets the value associated with the item at a given index. |
void | insertItem(String item, Direction dir, int index) Inserts an item into the list box, specifying its direction. |
void | insertItem(String item, String value, int index) Inserts an item into the list box, specifying an initial value for the item. |
void | insertItem(String item, int index) Inserts an item into the list box. |
boolean | isItemSelected(int index) Determines whether an individual list item is selected. |
boolean | isMultipleSelect() Gets whether this list allows multiple selection. |
void | removeItem(int index) Removes the item at the specified index. |
void | setEnabled(boolean enabled) Sets whether this widget is enabled. |
void | setFocus(boolean focused) |
void | setItemSelected(int index, boolean selected) Sets whether an individual list item is selected. |
void | setItemText(int index, String text) Sets the text associated with the item at a given index. |
void | setMultipleSelect(boolean multiple) Sets whether this list allows multiple selections. |
void | setName(String name) |
void | setSelectedIndex(int index) Sets the currently selected index. |
void | setTabIndex(int index) |
void | setValue(int index, String value) Sets the value associated with the item at a given index. |
void | setVisibleItemCount(int visibleItems) Sets the number of items that are visible. |
ListBox | wrap(Element element) Creates a ListBox widget that wraps an existing <select> element. |