|
GWT 2.6.1-rc1 | |||||||||
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.cellview.client.CellWidget<C>
com.google.gwt.widget.client.ButtonBase<C>
C
- the data type of the button's contentspublic class ButtonBase<C>
Base class for buttons that supports content decoration.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class com.google.gwt.user.client.ui.UIObject |
---|
UIObject.DebugIdImpl, UIObject.DebugIdImplEnabled |
Field Summary |
---|
Fields inherited from class com.google.gwt.user.client.ui.UIObject |
---|
DEBUG_ID_PREFIX |
Constructor Summary | |
---|---|
protected |
ButtonBase(ButtonCellBase<C> cell)
Construct a new ButtonBase with the specified cell and an initial
value of null . |
protected |
ButtonBase(ButtonCellBase<C> cell,
C initialValue)
Construct a new ButtonBase with the specified cell and initial
value. |
Method Summary | ||
---|---|---|
HandlerRegistration |
addBlurHandler(BlurHandler handler)
Adds a BlurEvent handler. |
|
HandlerRegistration |
addClickHandler(ClickHandler handler)
Adds a ClickEvent handler. |
|
HandlerRegistration |
addFocusHandler(FocusHandler handler)
Adds a FocusEvent handler. |
|
HandlerRegistration |
addKeyDownHandler(KeyDownHandler handler)
Adds a KeyDownEvent handler. |
|
HandlerRegistration |
addKeyPressHandler(KeyPressHandler handler)
Adds a KeyPressEvent handler. |
|
HandlerRegistration |
addKeyUpHandler(KeyUpHandler handler)
Adds a KeyUpEvent handler. |
|
HandlerRegistration |
addMouseDownHandler(MouseDownHandler handler)
Adds a MouseDownEvent handler. |
|
HandlerRegistration |
addMouseOutHandler(MouseOutHandler handler)
Adds a MouseOutEvent handler. |
|
HandlerRegistration |
addMouseOverHandler(MouseOverHandler handler)
Adds a MouseOverEvent handler. |
|
HandlerRegistration |
addMouseUpHandler(MouseUpHandler handler)
Adds a MouseUpEvent handler. |
|
ButtonCellBase.Decoration |
getDecoration()
Get the decoration style of the button. |
|
int |
getTabIndex()
Gets the widget's position in the tab index. |
|
(package private) static
|
initializeCell(C cell)
Initialize the tab index of the cell and return it. |
|
boolean |
isCollapseLeft()
Check whether or not the left-side of the UI component is collapsed (sharing border with the component to its left). |
|
boolean |
isCollapseRight()
right Check whether or not the left-side of the UI component is collapsed (sharing border with the component to its left). |
|
boolean |
isEnabled()
Returns true if the widget is enabled, false if not. |
|
void |
setAccessKey(char key)
Sets the widget's 'access key'. |
|
void |
setCollapseLeft(boolean isCollapsed)
Sets whether the left-side of the UI component is collapsed (sharing border with the component to its left). |
|
void |
setCollapseRight(boolean isCollapsed)
Sets whether the right-side of the UI component is collapsed (sharing border with the component to its right). |
|
void |
setDecoration(ButtonCellBase.Decoration decoration)
Set the ButtonCellBase.Decoration of the button. |
|
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.cellview.client.CellWidget |
---|
addValueChangeHandler, asEditor, getCell, getKeyProvider, getValue, onBrowserEvent, redraw, setValue, setValue, setValue |
Methods inherited from class com.google.gwt.user.client.ui.Widget |
---|
addAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, createHandlerManager, delegateEvent, doAttachChildren, doDetachChildren, fireEvent, getHandlerCount, getLayoutData, getParent, isAttached, isOrWasAttached, onAttach, onDetach, onLoad, onUnload, removeFromParent, setLayoutData, sinkEvents, unsinkEvents |
Methods inherited from class com.google.gwt.user.client.ui.UIObject |
---|
addStyleDependentName, addStyleName, ensureDebugId, ensureDebugId, ensureDebugId, getAbsoluteLeft, getAbsoluteTop, getElement, getOffsetHeight, getOffsetWidth, getStyleElement, getStyleName, getStyleName, getStylePrimaryName, getStylePrimaryName, getTitle, isVisible, isVisible, onEnsureDebugId, removeStyleDependentName, removeStyleName, resolvePotentialElement, setElement, setElement, setHeight, setPixelSize, setSize, setStyleDependentName, setStyleName, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setTitle, setVisible, setVisible, setWidth, sinkBitlessEvent, toString |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface com.google.gwt.event.shared.HasHandlers |
---|
fireEvent |
Constructor Detail |
---|
protected ButtonBase(ButtonCellBase<C> cell)
ButtonBase
with the specified cell and an initial
value of null
.
cell
- the cell to wrapprotected ButtonBase(ButtonCellBase<C> cell, C initialValue)
ButtonBase
with the specified cell and initial
value.
cell
- the cell to wrapinitialValue
- the initial value of the CellMethod Detail |
---|
static <C extends ButtonCellBase<?>> C initializeCell(C cell)
C
- the cell typecell
- the cellpublic HandlerRegistration addBlurHandler(BlurHandler handler)
HasBlurHandlers
BlurEvent
handler.
addBlurHandler
in interface HasBlurHandlers
handler
- the blur handler
HandlerRegistration
used to remove this handlerpublic HandlerRegistration addClickHandler(ClickHandler handler)
HasClickHandlers
ClickEvent
handler.
addClickHandler
in interface HasClickHandlers
handler
- the click handler
HandlerRegistration
used to remove this handlerpublic HandlerRegistration addFocusHandler(FocusHandler handler)
HasFocusHandlers
FocusEvent
handler.
addFocusHandler
in interface HasFocusHandlers
handler
- the focus handler
HandlerRegistration
used to remove this handlerpublic HandlerRegistration addKeyDownHandler(KeyDownHandler handler)
HasKeyDownHandlers
KeyDownEvent
handler.
addKeyDownHandler
in interface HasKeyDownHandlers
handler
- the key down handler
HandlerRegistration
used to remove this handlerpublic HandlerRegistration addKeyPressHandler(KeyPressHandler handler)
HasKeyPressHandlers
KeyPressEvent
handler.
addKeyPressHandler
in interface HasKeyPressHandlers
handler
- the key press handler
HandlerRegistration
used to remove this handlerpublic HandlerRegistration addKeyUpHandler(KeyUpHandler handler)
HasKeyUpHandlers
KeyUpEvent
handler.
addKeyUpHandler
in interface HasKeyUpHandlers
handler
- the key up handler
HandlerRegistration
used to remove this handlerpublic HandlerRegistration addMouseDownHandler(MouseDownHandler handler)
HasMouseDownHandlers
MouseDownEvent
handler.
addMouseDownHandler
in interface HasMouseDownHandlers
handler
- the mouse down handler
HandlerRegistration
used to remove this handlerpublic HandlerRegistration addMouseOutHandler(MouseOutHandler handler)
HasMouseOutHandlers
MouseOutEvent
handler.
addMouseOutHandler
in interface HasMouseOutHandlers
handler
- the mouse out handler
HandlerRegistration
used to remove this handlerpublic HandlerRegistration addMouseOverHandler(MouseOverHandler handler)
HasMouseOverHandlers
MouseOverEvent
handler.
addMouseOverHandler
in interface HasMouseOverHandlers
handler
- the mouse over handler
HandlerRegistration
used to remove this handlerpublic HandlerRegistration addMouseUpHandler(MouseUpHandler handler)
HasMouseUpHandlers
MouseUpEvent
handler.
addMouseUpHandler
in interface HasMouseUpHandlers
handler
- the mouse up handler
HandlerRegistration
used to remove this handlerpublic ButtonCellBase.Decoration getDecoration()
public int getTabIndex()
Focusable
getTabIndex
in interface Focusable
public boolean isCollapseLeft()
IsCollapsible
isCollapseLeft
in interface IsCollapsible
public boolean isCollapseRight()
IsCollapsible
isCollapseRight
in interface IsCollapsible
public boolean isEnabled()
HasEnabled
isEnabled
in interface HasEnabled
public void setAccessKey(char key)
Focusable
setAccessKey
in interface Focusable
key
- the widget's access keypublic void setCollapseLeft(boolean isCollapsed)
IsCollapsible
setCollapseLeft
in interface IsCollapsible
isCollapsed
- true if collapsed, false if notpublic void setCollapseRight(boolean isCollapsed)
IsCollapsible
setCollapseRight
in interface IsCollapsible
isCollapsed
- true if collapsed, false if notpublic void setDecoration(ButtonCellBase.Decoration decoration)
ButtonCellBase.Decoration
of the button.
decoration
- the button decorationpublic void setEnabled(boolean enabled)
HasEnabled
setEnabled
in interface HasEnabled
enabled
- true
to enable the widget, false
to disable itpublic void setFocus(boolean focused)
Focusable
setFocus
in interface Focusable
focused
- whether this widget should take focus or release itpublic void setTabIndex(int index)
Focusable
-1
will cause this widget to
be removed from the tab order.
setTabIndex
in interface Focusable
index
- the widget's tab index
|
GWT 2.6.1-rc1 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |