|
||||||||||
| 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
Abstract base class for most widgets that can receive keyboard focus.
| Constructor Summary | |
protected |
FocusWidget(Element elem)
Creates a new focus component that wraps the specified browser element. |
| Method Summary | |
void |
addClickListener(ClickListener listener)
Adds a listener interface to receive click events. |
void |
addFocusListener(FocusListener listener)
Adds a listener interface to receive mouse events. |
void |
addKeyboardListener(KeyboardListener listener)
Adds a listener interface to receive keyboard events. |
int |
getTabIndex()
Gets the widget's position in the tab index. |
boolean |
isEnabled()
Gets whether this widget is enabled. |
void |
onBrowserEvent(Event event)
Fired whenever a browser event is received. |
void |
removeClickListener(ClickListener listener)
Removes a previously added listener interface. |
void |
removeFocusListener(FocusListener listener)
Removes a previously added listener interface. |
void |
removeKeyboardListener(KeyboardListener listener)
Removes a previously added listener interface. |
void |
setAccessKey(char key)
Sets the widget's 'access key'. |
void |
setEnabled(boolean enabled)
Sets whether this widget is enabled. |
void |
setFocus(boolean focused)
Explicitly focus/unfocus this widget. |
void |
setTabIndex(int index)
Sets the widget's position in the tab index. |
| Methods inherited from class com.google.gwt.user.client.ui.Widget |
getParent, isAttached, onAttach, onDetach, onLoad, removeFromParent |
| Methods inherited from class com.google.gwt.user.client.ui.UIObject |
addStyleName, getAbsoluteLeft, getAbsoluteTop, getElement, getOffsetHeight, getOffsetWidth, getStyleName, getTitle, isVisible, isVisible, removeStyleName, setElement, setHeight, setPixelSize, setSize, setStyleName, setStyleName, 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 |
protected FocusWidget(Element elem)
elem - the element to be wrapped| Method Detail |
public void addClickListener(ClickListener listener)
SourcesClickEvents
addClickListener in interface SourcesClickEventslistener - the listener interface to addpublic void addFocusListener(FocusListener listener)
SourcesFocusEvents
addFocusListener in interface SourcesFocusEventslistener - the listener interface to addpublic void addKeyboardListener(KeyboardListener listener)
SourcesKeyboardEvents
addKeyboardListener in interface SourcesKeyboardEventslistener - the listener interface to addpublic int getTabIndex()
HasFocus
getTabIndex in interface HasFocuspublic boolean isEnabled()
true if the widget is enabledpublic void onBrowserEvent(Event event)
EventListener
onBrowserEvent in interface EventListeneronBrowserEvent in class Widgetpublic void removeClickListener(ClickListener listener)
SourcesClickEvents
removeClickListener in interface SourcesClickEventslistener - the listener interface to removepublic void removeFocusListener(FocusListener listener)
SourcesFocusEvents
removeFocusListener in interface SourcesFocusEventslistener - the listener interface to removepublic void removeKeyboardListener(KeyboardListener listener)
SourcesKeyboardEvents
removeKeyboardListener in interface SourcesKeyboardEventslistener - the listener interface to removepublic void setAccessKey(char key)
HasFocus
setAccessKey in interface HasFocuskey - the widget's access keypublic void setEnabled(boolean enabled)
enabled - true to enable the widget, false
to disable itpublic void setFocus(boolean focused)
HasFocus
setFocus in interface HasFocusfocused - whether this widget should take focus or release itpublic void setTabIndex(int index)
HasFocus-1 will cause this
widget to be removed from the tab order.
setTabIndex in interface HasFocusindex - the widget's tab index
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||