Class CloseResourceActionEx
- All Implemented Interfaces:
EventListener, IResourceChangeListener, IAction, ISelectionChangedListener
Close Project of the IIZI Explorer and the Project Explorer: Eclipse's action, with the question for the changed files of the Module projects in front of it (
UnsavedFiles.askBeforeClose).Eclipse's Close Project asks only for the changed files that an editor shows. A file of a Module project can be changed without an editor - a rename made its references follow, or its editor was closed without saving - and its changes were lost at the close without a word. Here every changed file of the projects is offered first, at the moment Eclipse's action asks for the projects it closes; Cancel leaves the projects open; then Eclipse's action goes on as it always did.
- Author:
- Christopher Mindus
Field Summary
Fields inherited from class CloseResourceAction
IDFields inherited from interface 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_TEXTFields inherited from interface IResourceChangeListener
PROPERTY_EVENT_MASKConstructor Summary
ConstructorsMethod Summary
Modifier and TypeMethodDescriptionGets the projects the action closes: in a run, after the question was answered, the projects that may be closed (CloseQuestion.closable(List)).voidrun()Closes the selected projects as Eclipse's action does, the changed files of the projects asked for first.Methods inherited from class CloseResourceAction
getModelProviderIds, getOperationMessage, getProblemsMessage, getProblemsTitle, getSelectedNonResources, invokeOperation, resourceChanged, setModelProviderIds, shouldPerformResourcePruning, updateSelectionMethods inherited from class WorkspaceAction
createOperation, getActionResources, runInBackground, runInBackground, runInBackgroundMethods inherited from class SelectionListenerAction
clearCache, resourceIsType, selectionIsOfTypeMethods inherited from class BaseSelectionListenerAction
getStructuredSelection, runWithEvent, selectionChanged, selectionChangedMethods inherited from class 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, setAccelerator, setActionDefinitionId, setChecked, setDescription, setDisabledImageDescriptor, setEnabled, setHelpListener, setHoverImageDescriptor, setId, setImageDescriptor, setMenuCreator, setText, setToolTipTextMethods inherited from class AbstractAction
addPropertyChangeListener, firePropertyChange, firePropertyChange, removePropertyChangeListenerMethods inherited from class EventManager
addListenerObject, clearListeners, getListeners, isListenerAttached, removeListenerObject
Constructor Details
CloseResourceActionEx
Creates the action.- Parameters:
provider- The provider of the shell for a dialog.
Method Details
run
public void run()Closes the selected projects as Eclipse's action does, the changed files of the projects asked for first.- Specified by:
runin interfaceIAction- Overrides:
runin classCloseResourceAction
getSelectedResources
Gets the projects the action closes: in a run, after the question was answered, the projects that may be closed (CloseQuestion.closable(List)).- Overrides:
getSelectedResourcesin classCloseResourceAction- Returns:
- The projects.