1 11 package org.eclipse.jdt.ui.actions; 12 13 import org.eclipse.jface.action.IAction; 14 import org.eclipse.jface.action.IMenuManager; 15 16 import org.eclipse.ui.IActionBars; 17 import org.eclipse.ui.IViewPart; 18 import org.eclipse.ui.actions.ActionContext; 19 import org.eclipse.ui.actions.ActionGroup; 20 21 32 public class NavigateActionGroup extends ActionGroup { 33 34 private OpenEditorActionGroup fOpenEditorActionGroup; 35 private OpenViewActionGroup fOpenViewActionGroup; 36 37 44 public NavigateActionGroup(IViewPart part) { 45 fOpenEditorActionGroup= new OpenEditorActionGroup(part); 46 fOpenViewActionGroup= new OpenViewActionGroup(part); 47 } 48 49 55 public IAction getOpenAction() { 56 return fOpenEditorActionGroup.getOpenAction(); 57 } 58 59 62 public void dispose() { 63 super.dispose(); 64 fOpenEditorActionGroup.dispose(); 65 fOpenViewActionGroup.dispose(); 66 } 67 68 71 public void fillActionBars(IActionBars actionBars) { 72 super.fillActionBars(actionBars); 73 fOpenEditorActionGroup.fillActionBars(actionBars); 74 fOpenViewActionGroup.fillActionBars(actionBars); 75 } 76 77 80 public void fillContextMenu(IMenuManager menu) { 81 super.fillContextMenu(menu); 82 83 fOpenEditorActionGroup.fillContextMenu(menu); 84 fOpenViewActionGroup.fillContextMenu(menu); 85 } 86 87 90 public void setContext(ActionContext context) { 91 super.setContext(context); 92 fOpenEditorActionGroup.setContext(context); 93 fOpenViewActionGroup.setContext(context); 94 } 95 96 99 public void updateActionBars() { 100 super.updateActionBars(); 101 fOpenEditorActionGroup.updateActionBars(); 102 fOpenViewActionGroup.updateActionBars(); 103 } 104 } 105 | Popular Tags |