public class SubCoolBarManager extends SubContributionManager implements ICoolBarManager
SubCoolBarManager monitors the additional and removal of
items from a parent manager so that visibility of the entire set can be changed as a
unit.SIZE| Constructor and Description |
|---|
SubCoolBarManager(ICoolBarManager mgr)
Constructs a new manager.
|
| Modifier and Type | Method and Description |
|---|---|
void |
add(IToolBarManager toolBarManager)
A convenience method to add a tool bar as a contribution item to this
cool bar manager.
|
IMenuManager |
getContextMenuManager()
Returns the context menu manager used by this cool bar manager.
|
boolean |
getLockLayout()
Returns whether the layout of the underlying cool bar widget is locked.
|
protected ICoolBarManager |
getParentCoolBarManager()
Returns the parent cool bar manager that this sub-manager contributes to.
|
int |
getStyle()
Returns the style of the underlying cool bar widget.
|
void |
setContextMenuManager(IMenuManager menuManager)
Sets the context menu of this cool bar manager to the given menu
manager.
|
void |
setLockLayout(boolean value)
Locks or unlocks the layout of the underlying cool bar widget.
|
void |
update(boolean force)
Updates this manager's underlying widget(s) with any changes which
have been made to it or its items.
|
add, add, appendToGroup, appendToGroup, disposeManager, find, getItems, getOverrides, getParent, insertAfter, insertAfter, insertBefore, insertBefore, isDirty, isEmpty, isVisible, itemAdded, itemRemoved, items, markDirty, prependToGroup, prependToGroup, remove, remove, removeAll, setVisible, unwrap, wrapclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitadd, add, appendToGroup, appendToGroup, find, getItems, getOverrides, insertAfter, insertAfter, insertBefore, insertBefore, isDirty, isEmpty, markDirty, prependToGroup, prependToGroup, remove, remove, removeAllpublic SubCoolBarManager(ICoolBarManager mgr)
mgr - the parent manager. All contributions made to the
SubCoolBarManager are forwarded and appear in the
parent manager.public void add(IToolBarManager toolBarManager)
ICoolBarManageradd(new ToolBarContributionManager(toolBarManager)).add in interface ICoolBarManagertoolBarManager - the tool bar manager to be addedToolBarContributionItempublic int getStyle()
ICoolBarManagergetStyle in interface ICoolBarManagerprotected final ICoolBarManager getParentCoolBarManager()
public boolean getLockLayout()
ICoolBarManagergetLockLayout in interface ICoolBarManagertrue if cool bar layout is locked, false
otherwisepublic void setLockLayout(boolean value)
ICoolBarManagerNote that items can be added or removed programmatically even while the cool bar is locked.
setLockLayout in interface ICoolBarManagervalue - true to lock the cool bar, false
to unlockpublic IMenuManager getContextMenuManager()
ICoolBarManagergetContextMenuManager in interface ICoolBarManagernull if noneICoolBarManager.setContextMenuManager(org.eclipse.jface.action.IMenuManager)public void setContextMenuManager(IMenuManager menuManager)
ICoolBarManagersetContextMenuManager in interface ICoolBarManagermenuManager - the context menu manager, or null if noneICoolBarManager.getContextMenuManager()public void update(boolean force)
IContributionManagerupdate in interface IContributionManagerforce - true means update even if not dirty,
and false for normal incremental updatingGuidelines for using Eclipse APIs. Copyright (c) IBM Corp. and others 2000, 2006. All rights reserved.