|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.eclipse.core.commands.common.EventManager
org.eclipse.jface.action.AbstractAction
org.eclipse.jface.action.Action
org.eclipse.emf.compare.ui.AbstractCompareAction
org.eclipse.emf.compare.ui.export.ExportMenu
public class ExportMenu
This implementation of AbstractCompareAction
is used to create the structure viewer's "export as"
action.
Field Summary | |
---|---|
protected org.eclipse.swt.widgets.Control |
parentControl
Control under which the menu must be created. |
protected ModelStructureMergeViewer |
parentViewer
Viewer currently displaying this menu. |
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, HANDLED, IMAGE, RESULT, TEXT, TOOL_TIP_TEXT |
Constructor Summary | |
---|---|
ExportMenu(org.eclipse.swt.widgets.Control parent,
ModelStructureMergeViewer owner)
This default constructor will instantiate an action given the bundle resources prefixed
by "action.save". |
Method Summary | |
---|---|
void |
addActionToMenu(org.eclipse.jface.action.Action action)
This will add the given action to this action's menu. |
void |
dispose()
|
void |
enableSave(boolean enabled)
This will switch the enable state of saveAction . |
java.util.Set<org.eclipse.emf.compare.ui.export.ExportActionDescriptor> |
getActions(java.lang.String fileExtension)
This will return all actions from the cached actions that apply to the given
fileExtension . |
java.lang.String |
getComparedModelsExtension()
Returns the file extension of the compared models. |
org.eclipse.swt.widgets.Menu |
getMenu(org.eclipse.swt.widgets.Control parent)
|
org.eclipse.swt.widgets.Menu |
getMenu(org.eclipse.swt.widgets.Menu parent)
|
void |
run()
If this action is triggered, it'll run the default save action. |
Methods inherited from class org.eclipse.jface.action.Action |
---|
convertAccelerator, convertAccelerator, findKeyCode, findKeyString, findModifier, findModifierString, getAccelerator, getActionDefinitionId, getDescription, getDisabledImageDescriptor, getHelpListener, getHoverImageDescriptor, getId, getImageDescriptor, getMenuCreator, getStyle, getText, getToolTipText, isChecked, isEnabled, isHandled, notifyResult, removeAcceleratorText, removeMnemonics, runWithEvent, setAccelerator, setActionDefinitionId, setChecked, setDescription, setDisabledImageDescriptor, setEnabled, setHelpListener, setHoverImageDescriptor, setId, setImageDescriptor, setMenuCreator, setText, setToolTipText |
Methods inherited from class org.eclipse.jface.action.AbstractAction |
---|
addPropertyChangeListener, firePropertyChange, firePropertyChange, removePropertyChangeListener |
Methods inherited from class org.eclipse.core.commands.common.EventManager |
---|
addListenerObject, clearListeners, getListeners, isListenerAttached, removeListenerObject |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.eclipse.jface.action.IAction |
---|
addPropertyChangeListener, removePropertyChangeListener |
Field Detail |
---|
protected final org.eclipse.swt.widgets.Control parentControl
protected final ModelStructureMergeViewer parentViewer
Constructor Detail |
---|
public ExportMenu(org.eclipse.swt.widgets.Control parent, ModelStructureMergeViewer owner)
bundle
resources prefixed
by "action.save".
parent
- Control
under which this Action
's menu must be created.owner
- The viewer currently displaying this menu.Method Detail |
---|
public void addActionToMenu(org.eclipse.jface.action.Action action)
action
- Action
to add to this action's menu.public void dispose()
dispose
in interface org.eclipse.jface.action.IMenuCreator
IMenuCreator.dispose()
public void enableSave(boolean enabled)
saveAction
.
enabled
- True
if the action must be enabled, False
otherwisepublic java.util.Set<org.eclipse.emf.compare.ui.export.ExportActionDescriptor> getActions(java.lang.String fileExtension)
cached actions
that apply to the given
fileExtension
.
fileExtension
- File extension which we seel actions for.
cached actions
that apply to the given
fileExtension
.ALL_EXTENSIONS
,
getComparedModelsExtension()
public java.lang.String getComparedModelsExtension()
public org.eclipse.swt.widgets.Menu getMenu(org.eclipse.swt.widgets.Control parent)
getMenu
in interface org.eclipse.jface.action.IMenuCreator
IMenuCreator.getMenu(org.eclipse.swt.widgets.Control)
public org.eclipse.swt.widgets.Menu getMenu(org.eclipse.swt.widgets.Menu parent)
getMenu
in interface org.eclipse.jface.action.IMenuCreator
IMenuCreator.getMenu(org.eclipse.swt.widgets.Menu)
public void run()
run
in interface org.eclipse.jface.action.IAction
run
in class AbstractCompareAction
AbstractCompareAction.run()
|
Copyright 2006 IBM Corporation and others. All Rights Reserved. |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |