|
||||||||||
| 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.sap.ui.core.client.ControlWidget
com.sap.ui.commons.client.MenuBarWidget
public class MenuBarWidget
The class MenuBar is the GWT wrapper
for the Phoenix control: sap.ui.commons.MenuBar.
Used to present actions in a structure. It represents a UI area which is the container for the menus and menu items. The menu bar contains the menu titles from where users navigate to the single items. The control supports for example long menu item texts, automated scrolling for menu items when the browser space is not large enough to display all items, defining images for single or all items in a menu, automated layouting of items with or w/o image, and active/non-active out-greyed items.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class com.google.gwt.user.client.ui.UIObject |
|---|
com.google.gwt.user.client.ui.UIObject.DebugIdImpl, com.google.gwt.user.client.ui.UIObject.DebugIdImplEnabled |
| Field Summary |
|---|
| Fields inherited from class com.google.gwt.user.client.ui.UIObject |
|---|
DEBUG_ID_PREFIX |
| Constructor Summary | |
|---|---|
|
MenuBarWidget()
constructs the class MenuBarWidget |
protected |
MenuBarWidget(MenuBar control)
constructs the class MenuBarWidget |
|
MenuBarWidget(String id)
constructs the class MenuBarWidget |
| Method Summary | |
|---|---|
void |
addItem(MenuItem item)
Appends some item to the items-aggregation. |
void |
destroyItems()
Destroys all the items in the Items-aggregation. |
MenuBar |
getControl()
returns the reference to the Phoenix Control |
MenuBarDesign |
getDesign()
Getter for property design
Design settings are theme-dependent. |
com.sap.ui.core.client.js.JsArray<MenuItem> |
getItems()
Getter for aggregation items Aggregation of menu items. |
String |
getWidth()
Getter for property width
Sets the width of the control |
int |
indexOfItem(MenuItem item)
Checks for the provided com.sap.ui.commons.client.MenuItem in the items-aggregation and
returns its index if found or -1 otherwise. |
void |
insertItem(MenuItem item,
int index)
Inserts some item into the aggregation named items. |
boolean |
isEnabled()
Getter for property enabled
When the MenuBar is not enabled all menu items are displayed disabled. |
boolean |
isVisible()
Getter for property visible
Invisible controls are not rendered. |
void |
removeAllItems()
Removes all the items in the items-aggregation. |
void |
removeItem(int index)
Removes the item at position index in the items-aggregation named. |
void |
setDesign(MenuBarDesign value)
Setter for property designDefault value is: Standard |
void |
setEnabled(boolean value)
Setter for property enabledDefault value is: true |
void |
setVisible(boolean value)
Setter for property visibleDefault value is: true |
void |
setWidth(String value)
Setter for property widthDefault value is: 100% |
| Methods inherited from class com.sap.ui.core.client.ControlWidget |
|---|
destroy, doAttachChildren, doDetachChildren, isDesignTime, wrap |
| Methods inherited from class com.google.gwt.user.client.ui.Widget |
|---|
addAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, createHandlerManager, delegateEvent, fireEvent, getHandlerCount, getLayoutData, getParent, isAttached, isOrWasAttached, onAttach, onBrowserEvent, onDetach, onLoad, onUnload, removeFromParent, setLayoutData, sinkEvents |
| 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, onEnsureDebugId, removeStyleDependentName, removeStyleName, setElement, setElement, setHeight, setPixelSize, setSize, setStyleDependentName, setStyleName, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setTitle, setVisible, sinkBitlessEvent, toString, unsinkEvents |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public MenuBarWidget()
MenuBarWidget
public MenuBarWidget(String id)
MenuBarWidget
id - id of the MenuBarWidgetprotected MenuBarWidget(MenuBar control)
MenuBarWidget
control - reference to an existing MenuBar| Method Detail |
|---|
public MenuBar getControl()
Control
getControl in class com.sap.ui.core.client.ControlWidgetControlpublic boolean isEnabled()
enabled
When the MenuBar is not enabled all menu items are displayed disabled.
public void setEnabled(boolean value)
enabledtrue
value - booleanpublic boolean isVisible()
visible
Invisible controls are not rendered.
isVisible in class com.google.gwt.user.client.ui.UIObjectpublic void setVisible(boolean value)
visibletrue
setVisible in class com.google.gwt.user.client.ui.UIObjectvalue - booleanpublic String getWidth()
width
Sets the width of the control
public void setWidth(String value)
width100%
setWidth in class com.google.gwt.user.client.ui.UIObjectvalue - Stringpublic MenuBarDesign getDesign()
design
Design settings are theme-dependent.
public void setDesign(MenuBarDesign value)
designStandard
value - com.sap.ui.commons.client.MenuBarDesignpublic com.sap.ui.core.client.js.JsArray<MenuItem> getItems()
public void insertItem(MenuItem item,
int index)
item - the item to insertindex - int the 0-based index the item should be inserted at.public void addItem(MenuItem item)
item - com.sap.ui.commons.client.MenuItem the item to addpublic void removeItem(int index)
index in the items-aggregation named.
index - int the position of the item to remove.public void removeAllItems()
public int indexOfItem(MenuItem item)
com.sap.ui.commons.client.MenuItem in the items-aggregation and
returns its index if found or -1 otherwise.
item - the item whose index is looked for.
public void destroyItems()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||