|
Eclipse Platform 2.0 |
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object
|
+--org.eclipse.jface.action.Action
|
+--org.eclipse.ui.texteditor.ResourceAction
|
+--org.eclipse.ui.texteditor.TextEditorAction
Sekelleton of a standard text editor action. The action is
initially associated with a text editor via the constructor,
but can subsequently be changed using setEditor.
Subclasses must implement the run method and if
required override the update method.
| Field Summary |
| Fields inherited from interface org.eclipse.jface.action.IAction |
AS_CHECK_BOX, AS_DROP_DOWN_MENU, AS_PUSH_BUTTON, CHECKED, DESCRIPTION, ENABLED, IMAGE, TEXT, TOOL_TIP_TEXT |
| Constructor Summary | |
protected |
TextEditorAction(ResourceBundle bundle,
String prefix,
ITextEditor editor)
Creates and initializes the action for the given text editor. |
| Method Summary | |
protected ITextEditor |
getTextEditor()
Returns the action's text editor. |
void |
setEditor(ITextEditor editor)
Retargets this action to the given editor. |
void |
update()
Always enables this action if it is connected to a text editor. |
| Methods inherited from class org.eclipse.ui.texteditor.ResourceAction |
getString, setHelpContextId |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
protected TextEditorAction(ResourceBundle bundle,
String prefix,
ITextEditor editor)
bundle - the resource bundleprefix - a prefix to be prepended to the various resource keys
(described in ResourceAction constructor), or
null if noneeditor - the text editorResourceAction.ResourceAction(java.util.ResourceBundle, java.lang.String)| Method Detail |
protected ITextEditor getTextEditor()
public void setEditor(ITextEditor editor)
editor - the new editor, or null if nonepublic void update()
null, the action is disabled.
Subclasses may override.
update in interface IUpdate
|
Eclipse Platform 2.0 |
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||