public abstract class Item extends Component implements HasSelectionHandlers<Item>, ActivateEvent.HasActivateHandlers<Item>, DeactivateEvent.HasDeactivateHandlers<Item>, HasBeforeSelectionHandlers<Item>
| Modifier and Type | Class and Description |
|---|---|
static interface |
Item.ItemAppearance |
UIObject.DebugIdImpl, UIObject.DebugIdImplEnabledDEBUG_ID_PREFIX| Constructor and Description |
|---|
Item() |
Item(Item.ItemAppearance appearance) |
| Modifier and Type | Method and Description |
|---|---|
HandlerRegistration |
addActivateHandler(ActivateEvent.ActivateHandler<Item> handler)
Adds a
ActivateEvent handler. |
HandlerRegistration |
addBeforeSelectionHandler(BeforeSelectionHandler<Item> handler) |
HandlerRegistration |
addDeactivateHandler(DeactivateEvent.DeactivateHandler<Item> handler)
Adds a
DeactivateEvent handler. |
HandlerRegistration |
addSelectionHandler(SelectionHandler<Item> handler) |
boolean |
getHideOnClick()
Returns the hide on click state.
|
boolean |
isCanActivate()
Returns true if the widget can be activated.
|
void |
setCanActivate(boolean canActivate)
Sets whether the item can be activated (defaults to false).
|
void |
setHideOnClick(boolean hideOnClick)
True to hide the containing menu after this item is clicked (defaults to
true).
|
addBeforeHideHandler, addBeforeShowContextMenuHandler, addBeforeShowHandler, addBlurHandler, addDisableHandler, addEnableHandler, addFocusHandler, addHideHandler, addMoveHandler, addResizeHandler, addShowContextMenuHandler, addShowHandler, addStyleOnOver, clearSizeCache, disable, disableEvents, enable, enableEvents, fireEvent, focus, getData, getElement, getFocusSupport, getHideMode, getId, getItemId, getOffsetHeight, getOffsetWidth, getShadow, getStateId, getToolTip, hide, hideToolTip, isAllowTextSelection, isAutoHeight, isAutoWidth, isDeferHeight, isEnabled, isRendered, isStateful, isVisible, isVisible, mask, mask, onBrowserEvent, removeHandler, removeToolTip, setAllowTextSelection, setBorders, setBounds, setBounds, setContextMenu, setData, setDeferHeight, setEnabled, setHeight, setHeight, setHideMode, setId, setItemId, setPagePosition, setPixelSize, setPosition, setShadow, setSize, setStateful, setStateId, setTabIndex, setToolTip, setToolTipConfig, setVisible, setWidth, setWidth, show, sync, syncSize, unmaskaddAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, getLayoutData, getParent, isAttached, removeFromParent, setLayoutData, sinkEventsaddStyleDependentName, addStyleName, ensureDebugId, ensureDebugId, getAbsoluteLeft, getAbsoluteTop, getOffsetHeight, getOffsetWidth, getStyleName, getStylePrimaryName, getTitle, isVisible, removeStyleDependentName, removeStyleName, setStyleDependentName, setStyleName, setStyleName, setStylePrimaryName, setTitle, setVisible, sinkBitlessEvent, toString, unsinkEventsequals, getClass, hashCode, notify, notifyAll, wait, wait, waitfireEventpublic Item()
public Item(Item.ItemAppearance appearance)
public HandlerRegistration addActivateHandler(ActivateEvent.ActivateHandler<Item> handler)
ActivateEvent.HasActivateHandlersActivateEvent handler.addActivateHandler in interface ActivateEvent.HasActivateHandlers<Item>handler - the handlerpublic HandlerRegistration addDeactivateHandler(DeactivateEvent.DeactivateHandler<Item> handler)
DeactivateEvent.HasDeactivateHandlersDeactivateEvent handler.addDeactivateHandler in interface DeactivateEvent.HasDeactivateHandlers<Item>handler - the handlerpublic HandlerRegistration addSelectionHandler(SelectionHandler<Item> handler)
addSelectionHandler in interface HasSelectionHandlers<Item>public HandlerRegistration addBeforeSelectionHandler(BeforeSelectionHandler<Item> handler)
addBeforeSelectionHandler in interface HasBeforeSelectionHandlers<Item>public boolean getHideOnClick()
public boolean isCanActivate()
public void setCanActivate(boolean canActivate)
canActivate - true to activatepublic void setHideOnClick(boolean hideOnClick)
hideOnClick - true to hide, otherwise falseCopyright © 2012. All Rights Reserved.