|
Elexis API documentationVersion 2.1.6 as of January 22 2012 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectch.elexis.util.ViewMenus
public class ViewMenus
This class simplifies the handling of menus and toolbars.
| Nested Class Summary | |
|---|---|
static interface |
ViewMenus.IMenuPopulator
|
| Constructor Summary | |
|---|---|
ViewMenus(IViewSite s)
|
|
| Method Summary | |
|---|---|
void |
createControlContextMenu(Control control,
IAction... actions)
Creates a menu for the given control containing the given actions |
void |
createControlContextMenu(Control control,
ViewMenus.IMenuPopulator populator)
Creates a menu for the given Control that will be populated by the provided populator This can be used to construct dynamic menus that change contents depending of state. |
void |
createMenu(IAction... actions)
Create a menu containing the specified actions. |
void |
createToolbar(IAction... actions)
Create a toolbar containing the specified actions |
void |
createViewerContextMenu(StructuredViewer viewer,
IAction... actions)
Attach a context menu to a org.eclipse.jface.StructuredViewer |
MenuManager |
getContextMenu()
Return the context menu for registration with the selectionProvider |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ViewMenus(IViewSite s)
| Method Detail |
|---|
public void createMenu(IAction... actions)
actions - a collection of actions and null-values (that represent separators)public void createToolbar(IAction... actions)
actions - a collection of actions and null-values (that represent separators)
public void createViewerContextMenu(StructuredViewer viewer,
IAction... actions)
viewer - the vieweractions - the actions to use
public void createControlContextMenu(Control control,
IAction... actions)
control - the Control to add the menu toactions - the actions to be shown in the menupublic MenuManager getContextMenu()
public void createControlContextMenu(Control control,
ViewMenus.IMenuPopulator populator)
|
Elexis API documentationVersion 2.1.6 as of January 22 2012 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||