|
Eclipse GEF 2.1 |
||||||||||
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.gef.ui.actions.EditorPartAction
Base class for actions used by GEF editors.
Field Summary |
Fields inherited from interface org.eclipse.jface.action.IAction |
AS_CHECK_BOX, AS_DROP_DOWN_MENU, AS_PUSH_BUTTON, AS_RADIO_BUTTON, AS_UNSPECIFIED, CHECKED, DESCRIPTION, ENABLED, IMAGE, TEXT, TOOL_TIP_TEXT |
Constructor Summary | |
EditorPartAction(IEditorPart editor)
Creates a new EditorPartAction and sets the editor. |
Method Summary | |
protected abstract boolean |
calculateEnabled()
Calculates and returns the enabled state of this action. |
void |
dispose()
Called when the action is about to be disposed. |
protected void |
execute(Command command)
Executes the given Command . |
protected CommandStack |
getCommandStack()
Returns the editor's command stack. |
protected IEditorPart |
getEditorPart()
Returns the editor associated with this action. |
protected void |
init()
Initializes this action. |
boolean |
isEnabled()
Calls calculateEnabled() to determine the enabled state of this action. |
protected void |
refresh()
Refreshes the properties of this action. |
protected void |
setEditorPart(IEditorPart part)
Sets the editor. |
void |
update()
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public EditorPartAction(IEditorPart editor)
editor
- The editor to be associated with this action.Method Detail |
protected abstract boolean calculateEnabled()
public void dispose()
dispose
in interface Disposable
protected void execute(Command command)
Command
.
protected CommandStack getCommandStack()
protected IEditorPart getEditorPart()
protected void init()
public boolean isEnabled()
calculateEnabled()
to determine the enabled state of this action.
isEnabled
in interface IAction
isEnabled
in class Action
protected void refresh()
protected void setEditorPart(IEditorPart part)
public void update()
update
in interface UpdateAction
org.eclipse.gef.UpdateAction#update()
|
Eclipse GEF 2.1 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |