Class CloseProjectActionProvider
java.lang.Object
org.eclipse.ui.actions.ActionGroup
org.eclipse.ui.navigator.CommonActionProvider
com.iizigo.navigator.CloseProjectActionProvider
- All Implemented Interfaces:
IMementoAware
Puts iiziGo's Close Project and Close Unrelated Projects (
CloseResourceActionEx, CloseUnrelatedProjectsActionEx) in the place of Eclipse's two actions, in every navigator that shows the IIZI content - the IIZI Explorer and the Project Explorer: in the context menu of a project, and as the handlers of Project > Close Project and Close Unrelated Projects while the navigator is the active part.The provider depends on Eclipse's provider of those actions (org.eclipse.ui.navigator.resources.ResourceMgmtActions, see plugin.xml), so it is asked right after it: Eclipse's provider has added its two actions, and they are replaced here by item identity (iiziGo's actions carry the identities of Eclipse's). Build, Refresh and Open Project stay Eclipse's.
- Author:
- Christopher Mindus
Constructor Summary
ConstructorsMethod Summary
Modifier and TypeMethodDescriptionvoidfillActionBars(IActionBars actionBars) Sets the two actions as the handlers of the Project menu's Close Project and Close Unrelated Projects.voidfillContextMenu(IMenuManager menu) Replaces Eclipse's two actions in the context menu, where Eclipse's provider added them.Gets Close Project.Gets Close Unrelated Projects.voidInitializes the provider: makes the two actions.voidTells the two actions the selection.Methods inherited from class CommonActionProvider
filterAction, getActionSite, restoreState, saveStateMethods inherited from class ActionGroup
dispose, getContext, setContext
Constructor Details
CloseProjectActionProvider
public CloseProjectActionProvider()
Method Details
getCloseProjectAction
fillActionBars
Sets the two actions as the handlers of the Project menu's Close Project and Close Unrelated Projects.- Overrides:
fillActionBarsin classActionGroup- Parameters:
actionBars- The action bars of the navigator.
fillContextMenu
Replaces Eclipse's two actions in the context menu, where Eclipse's provider added them.- Overrides:
fillContextMenuin classActionGroup- Parameters:
menu- The context menu.
updateActionBars
public void updateActionBars()Tells the two actions the selection.- Overrides:
updateActionBarsin classActionGroup