public abstract class BaseMenu extends Object implements com.google.gwt.user.client.ui.IsWidget, BaseMenuView.BaseMenuPresenter
| Modifier and Type | Field and Description |
|---|---|
protected ExecutableMenuItemPresenter |
executableMenuItemPresenter |
protected MenuItemPresenter |
menuItemPresenter |
protected BaseMenuView |
view |
| Constructor and Description |
|---|
BaseMenu() |
| Modifier and Type | Method and Description |
|---|---|
com.google.gwt.dom.client.LIElement |
addExecutableMenuItem(String id,
String label,
String i18n)
Add an executable menu voice in form of
LIElement to the underlying view
It is an overload of BaseMenuView.BaseMenuPresenter.addExecutableMenuItem(String, String, String, Event) to dynamically provide
an event at runtime |
com.google.gwt.dom.client.LIElement |
addExecutableMenuItem(String id,
String label,
String i18n,
com.google.web.bindery.event.shared.Event event)
Add an executable menu voice in form of
LIElement to the underlying view |
com.google.gwt.dom.client.LIElement |
addMenuItem(String id,
String label,
String i18n)
Add a label menu voice in form of
LIElement to the underlying view |
com.google.gwt.user.client.ui.Widget |
asWidget() |
void |
enableElement(com.google.gwt.dom.client.Element element,
boolean enabled) |
protected com.google.gwt.user.client.ui.RootPanel |
getRootPanel() |
BaseMenuView |
getView() |
void |
hide() |
void |
initialise() |
boolean |
isDisabled(com.google.gwt.dom.client.Element element) |
boolean |
isShown()
Method to retrieve the visibility state of the view
|
void |
mapEvent(com.google.gwt.dom.client.LIElement executableMenuItem,
com.google.web.bindery.event.shared.Event toBeMapped)
Method to map an
Event to a given EXECUTABLE LIElement. |
void |
onContextMenuEvent(com.google.gwt.event.dom.client.ContextMenuEvent event) |
void |
removeMenuItem(com.google.gwt.dom.client.LIElement toRemove)
Remove a menu voice from the given menu
|
void |
show(int mx,
int my) |
protected void |
updateMenuItemAttributes(com.google.gwt.dom.client.LIElement toUpdate,
String id,
String label,
String i18n) |
@Inject protected MenuItemPresenter menuItemPresenter
@Inject protected ExecutableMenuItemPresenter executableMenuItemPresenter
@Inject protected BaseMenuView view
@PostConstruct public void initialise()
initialise in interface BaseMenuView.BaseMenuPresenterpublic com.google.gwt.dom.client.LIElement addMenuItem(String id, String label, String i18n)
BaseMenuView.BaseMenuPresenterLIElement to the underlying viewaddMenuItem in interface BaseMenuView.BaseMenuPresenterpublic com.google.gwt.dom.client.LIElement addExecutableMenuItem(String id, String label, String i18n, com.google.web.bindery.event.shared.Event event)
BaseMenuView.BaseMenuPresenterLIElement to the underlying viewaddExecutableMenuItem in interface BaseMenuView.BaseMenuPresenterevent - the Event to fire on clickpublic com.google.gwt.dom.client.LIElement addExecutableMenuItem(String id, String label, String i18n)
BaseMenuView.BaseMenuPresenterLIElement to the underlying view
It is an overload of BaseMenuView.BaseMenuPresenter.addExecutableMenuItem(String, String, String, Event) to dynamically provide
an event at runtimeaddExecutableMenuItem in interface BaseMenuView.BaseMenuPresenterpublic void removeMenuItem(com.google.gwt.dom.client.LIElement toRemove)
BaseMenuView.BaseMenuPresenterremoveMenuItem in interface BaseMenuView.BaseMenuPresenterpublic void mapEvent(com.google.gwt.dom.client.LIElement executableMenuItem,
com.google.web.bindery.event.shared.Event toBeMapped)
BaseMenuView.BaseMenuPresenterEvent to a given EXECUTABLE LIElement.
To be used when LIElement has been retrieved with BaseMenuView.BaseMenuPresenter.addExecutableMenuItem(String, String, String)mapEvent in interface BaseMenuView.BaseMenuPresenterpublic com.google.gwt.user.client.ui.Widget asWidget()
asWidget in interface com.google.gwt.user.client.ui.IsWidgetpublic void show(int mx,
int my)
show in interface BaseMenuView.BaseMenuPresenterpublic void hide()
hide in interface BaseMenuView.BaseMenuPresenterpublic boolean isShown()
BaseMenuView.BaseMenuPresenterisShown in interface BaseMenuView.BaseMenuPresenterpublic BaseMenuView getView()
getView in interface BaseMenuView.BaseMenuPresenterpublic void enableElement(com.google.gwt.dom.client.Element element,
boolean enabled)
enableElement in interface BaseMenuView.BaseMenuPresenterpublic boolean isDisabled(com.google.gwt.dom.client.Element element)
isDisabled in interface BaseMenuView.BaseMenuPresenterpublic void onContextMenuEvent(com.google.gwt.event.dom.client.ContextMenuEvent event)
onContextMenuEvent in interface BaseMenuView.BaseMenuPresenterprotected com.google.gwt.user.client.ui.RootPanel getRootPanel()
Copyright © 2001–2019 JBoss by Red Hat. All rights reserved.