public abstract class OutlineActionContribution extends OutlineContribution
Constructor and Description |
---|
OutlineActionContribution() |
Modifier and Type | Method and Description |
---|---|
protected void |
contribute(org.eclipse.jface.action.ActionContributionItem item,
org.eclipse.jface.action.IContributionManager manager)
Contributes the given action contribution item to the given manager.
|
protected abstract org.eclipse.jface.action.IAction |
createAction()
Returns a new action that is to be contributed to the outline page.
|
void |
dispose()
Disposes of this contribution.
|
protected void |
disposeAction(org.eclipse.jface.action.IAction action)
Disposes of the contributed action.
|
protected org.eclipse.jface.action.IContributionManager |
getContributionManager()
Returns the manager that is to be used for contributing the action
to the outline page.
|
void |
init(ICommonOutlinePage outlinePage)
Initializes this contribution.
|
getOutlinePage
public void init(ICommonOutlinePage outlinePage)
OutlineContribution
This method may be extended by subclasses. Subclasses must call the superclass implementation.
init
in interface IOutlineContribution
init
in class OutlineContribution
outlinePage
- the contribution's outline page
(never null
)public void dispose()
OutlineContribution
init()
has been called.
This method has no effect if this contribution has already
been disposed.
This method may be extended by subclasses. Subclasses must call the superclass implementation.
dispose
in interface IOutlineContribution
dispose
in class OutlineContribution
protected abstract org.eclipse.jface.action.IAction createAction()
null
protected void disposeAction(org.eclipse.jface.action.IAction action)
Default implementation does nothing. Subclasses may override.
action
- the action to dispose (never null
)protected org.eclipse.jface.action.IContributionManager getContributionManager()
Default implementation returns the outline page's toolbar manager. Subclasses may override.
null
)protected void contribute(org.eclipse.jface.action.ActionContributionItem item, org.eclipse.jface.action.IContributionManager manager)
Default implementation calls manager.add(item)
.
Subclasses may override.
item
- never null
manager
- never null
Copyright (c) 2014, 2020 1C-Soft LLC and others. Made available under the Eclipse Public License 2.0