|
Eclipse Platform Release 3.6 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.eclipse.ui.part.EditorActionBarContributor
org.eclipse.ui.texteditor.BasicTextEditorActionContributor
public class BasicTextEditorActionContributor
Manages the installation and removal of global actions for the same type of editors.
If instantiated and used as-is, this contributor connects to all of the workbench defined global editor actions the corresponding actions of the current editor. It also adds addition actions for searching and navigation (go to line) as well as a set of status fields.
Subclasses may override the following methods:
contributeToMenu - extend to contribute to menucontributeToToolBar - reimplement to contribute to tool barcontributeToStatusLine - reimplement to contribute to status linesetActiveEditor - extend to react to editor changes
ITextEditorActionConstants| Constructor Summary | |
|---|---|
BasicTextEditorActionContributor()
Creates an empty editor action bar contributor. |
|
| Method Summary | |
|---|---|
void |
contributeToMenu(IMenuManager menu)
Contributes to the given menu. |
void |
contributeToStatusLine(IStatusLineManager statusLineManager)
Contributes to the given status line. |
void |
dispose()
The EditorActionBarContributor implementation of this
IEditorActionBarContributor method does nothing,
subclasses may override. |
protected IAction |
getAction(ITextEditor editor,
java.lang.String actionId)
Returns the action registered with the given text editor. |
protected IEditorPart |
getActiveEditorPart()
Returns the active editor part. |
void |
setActiveEditor(IEditorPart part)
The BasicTextEditorActionContributor implementation of this
IEditorActionBarContributor method installs the global
action handler for the given text editor by calling a private helper
method. |
| Methods inherited from class org.eclipse.ui.part.EditorActionBarContributor |
|---|
contributeToCoolBar, contributeToToolBar, getActionBars, getPage, init, init |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public BasicTextEditorActionContributor()
init method.
IEditorActionBarContributor.init(org.eclipse.ui.IActionBars, org.eclipse.ui.IWorkbenchPage)| Method Detail |
|---|
protected final IEditorPart getActiveEditorPart()
protected final IAction getAction(ITextEditor editor,
java.lang.String actionId)
editor - the editor, or nullactionId - the action id
null if nonepublic void setActiveEditor(IEditorPart part)
BasicTextEditorActionContributor implementation of this
IEditorActionBarContributor method installs the global
action handler for the given text editor by calling a private helper
method.
Subclasses may extend.
setActiveEditor in interface IEditorActionBarContributorsetActiveEditor in class EditorActionBarContributorpart - the new target editorpublic void contributeToMenu(IMenuManager menu)
EditorActionBarContributor
The EditorActionBarContributor implementation of this method
does nothing. Subclasses may reimplement to add to the menu portion of this
contribution.
contributeToMenu in class EditorActionBarContributormenu - the manager that controls the menupublic void contributeToStatusLine(IStatusLineManager statusLineManager)
EditorActionBarContributor
The EditorActionBarContributor implementation of this method
does nothing. Subclasses may reimplement to add to the status line portion of
this contribution.
contributeToStatusLine in class EditorActionBarContributorstatusLineManager - the manager of the status linepublic void dispose()
EditorActionBarContributorEditorActionBarContributor implementation of this
IEditorActionBarContributor method does nothing,
subclasses may override.
dispose in interface IEditorActionBarContributordispose in class EditorActionBarContributor
|
Eclipse Platform Release 3.6 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
Guidelines for using Eclipse APIs.
Copyright (c) Eclipse contributors and others 2000, 2010. All rights reserved.