import org.eclipse.jface.viewers.ISelectionProvider;
import org.eclipse.jface.viewers.IStructuredSelection;
import org.eclipse.ui.IActionBars;
-import org.eclipse.ui.IViewPart;
+//import org.eclipse.ui.IViewPart;
import org.eclipse.ui.IWorkbenchSite;
import org.eclipse.ui.actions.ActionGroup;
import org.eclipse.ui.actions.AddBookmarkAction;
fEditor = editor;
fGroupName = groupName;
- ISelectionProvider provider = fSite.getSelectionProvider();
- ISelection selection = provider.getSelection();
+ //ISelectionProvider provider = fSite.getSelectionProvider();
+ //ISelection selection = provider.getSelection();
// fAddImport= new AddImportOnSelectionAction(editor);
// fAddImport.setActionDefinitionId(IJavaEditorActionDefinitionIds.ADD_IMPORT);
* @param part
* the view part that owns this action group
*/
- public GenerateActionGroup(IViewPart part) {
- this(part.getSite());
- }
+// public GenerateActionGroup(IViewPart part) {
+// this(part.getSite());
+// }
private GenerateActionGroup(IWorkbenchSite site) {
fSite = site;
}
}
- private int appendToGroup(IMenuManager menu, IAction action) {
- if (action != null && action.isEnabled()) {
- menu.appendToGroup(fGroupName, action);
- return 1;
- }
- return 0;
- }
-
- private int addAction(IMenuManager menu, IAction action) {
- if (action != null && action.isEnabled()) {
- menu.add(action);
- return 1;
- }
- return 0;
- }
+// private int appendToGroup(IMenuManager menu, IAction action) {
+// if (action != null && action.isEnabled()) {
+// menu.appendToGroup(fGroupName, action);
+// return 1;
+// }
+// return 0;
+// }
+
+// private int addAction(IMenuManager menu, IAction action) {
+// if (action != null && action.isEnabled()) {
+// menu.add(action);
+// return 1;
+// }
+// return 0;
+// }
private int addEditorAction(IMenuManager menu, String actionID) {
if (fEditor == null)