List of usage examples for com.intellij.openapi.actionSystem IdeActions GROUP_MAIN_MENU
String GROUP_MAIN_MENU
To view the source code for com.intellij.openapi.actionSystem IdeActions GROUP_MAIN_MENU.
Click Source Link
From source file:com.intellij.ide.ui.customization.CustomActionsSchema.java
License:Apache License
public CustomActionsSchema() { myIdToNameList.add(new Pair(IdeActions.GROUP_MAIN_MENU, ActionsTreeUtil.MAIN_MENU_TITLE)); myIdToNameList.add(new Pair(IdeActions.GROUP_MAIN_TOOLBAR, ActionsTreeUtil.MAIN_TOOLBAR)); myIdToNameList.add(new Pair(IdeActions.GROUP_EDITOR_POPUP, ActionsTreeUtil.EDITOR_POPUP)); myIdToNameList.add(new Pair(IdeActions.GROUP_EDITOR_GUTTER, "Editor Gutter Popup Menu")); myIdToNameList.add(new Pair(IdeActions.GROUP_EDITOR_TAB_POPUP, ActionsTreeUtil.EDITOR_TAB_POPUP)); myIdToNameList.add(new Pair(IdeActions.GROUP_PROJECT_VIEW_POPUP, ActionsTreeUtil.PROJECT_VIEW_POPUP)); myIdToNameList.add(new Pair(IdeActions.GROUP_SCOPE_VIEW_POPUP, "Scope View Popup Menu")); myIdToNameList.add(new Pair(IdeActions.GROUP_FAVORITES_VIEW_POPUP, ActionsTreeUtil.FAVORITES_POPUP)); myIdToNameList.add(new Pair(IdeActions.GROUP_COMMANDER_POPUP, ActionsTreeUtil.COMMANDER_POPUP)); myIdToNameList.add(new Pair(IdeActions.GROUP_J2EE_VIEW_POPUP, ActionsTreeUtil.J2EE_POPUP)); myIdToNameList.add(new Pair(IdeActions.GROUP_NAVBAR_POPUP, "Navigation Bar")); myIdToNameList.add(new Pair("NavBarToolBar", "Navigation Bar Toolbar")); CustomizableActionGroupProvider.CustomizableActionGroupRegistrar registrar = new CustomizableActionGroupProvider.CustomizableActionGroupRegistrar() { @Override/*w w w. ja va2 s. co m*/ public void addCustomizableActionGroup(@NotNull String groupId, @NotNull String groupTitle) { myIdToNameList.add(new Pair(groupId, groupTitle)); } }; for (CustomizableActionGroupProvider provider : CustomizableActionGroupProvider.EP_NAME.getExtensions()) { provider.registerGroups(registrar); } }
From source file:com.intellij.ide.util.gotoByName.GotoActionModel.java
License:Apache License
public GotoActionModel(@Nullable Project project, final Component component, @Nullable Editor editor, @Nullable PsiFile file) {//w w w . j a v a 2s . c o m myProject = project; myContextComponent = component; final ActionGroup mainMenu = (ActionGroup) myActionManager.getActionOrStub(IdeActions.GROUP_MAIN_MENU); collectActions(myActionGroups, mainMenu, mainMenu.getTemplatePresentation().getText()); if (project != null && editor != null && file != null) { final ApplyIntentionAction[] children = ApplyIntentionAction.getAvailableIntentions(editor, file); if (children != null) { for (ApplyIntentionAction action : children) { myIntentions.put(action.getName(), action); } } } myIndex = SearchableOptionsRegistrar.getInstance(); }
From source file:com.mediaworx.intellij.opencmsplugin.OpenCmsPlugin.java
License:Open Source License
/** * Creates and registers the OpenCms menu for the main menu as an action group *//*from w w w. j ava 2 s . c o m*/ private void registerMainMenu() { OpenCmsMainMenu openCmsMainMenu = (OpenCmsMainMenu) actionManager.getAction(OPENCMS_MENU_ID); if (openCmsMainMenu == null) { DefaultActionGroup mainMenu = (DefaultActionGroup) actionManager.getAction(IdeActions.GROUP_MAIN_MENU); openCmsMainMenu = OpenCmsMainMenu.getInstance(this); addAction(mainMenu, OPENCMS_MENU_ID, openCmsMainMenu, "_OpenCms", null, new Constraints(Anchor.BEFORE, "HelpMenu")); } }
From source file:com.smardec.ideaplugin.ideamousegestures.ActionHelper.java
License:Open Source License
private ActionHelper() { actionNodes = new LinkedList<Node>(); rootNode = new Node(NodeType.GROUP, null, ROOT_NODE_TEXT, GROUP_ICON, null); AnAction anAction = ActionManager.getInstance().getAction(IdeActions.GROUP_MAIN_MENU); if (anAction instanceof DefaultActionGroup) { AnAction[] mainMenus = ((DefaultActionGroup) anAction).getChildren(null); List<Node> childrenNodes = new LinkedList<Node>(); for (AnAction mainMenu : mainMenus) { childrenNodes.addAll(Arrays.asList(convert(rootNode, mainMenu, actionNodes))); }/*from ww w . jav a 2 s. com*/ rootNode.children = childrenNodes.toArray(new Node[childrenNodes.size()]); } }
From source file:org.metaborg.intellij.idea.languages.DefaultIdeaLanguageManager.java
License:Apache License
/** * Activates the specified language./* w w w. ja v a2 s.c o m*/ * * @param languageImplBindings * The bindings of the language implementation to activate. */ private void activateLanguageImpl(final LanguageImplBindings languageImplBindings) { this.actionUtils.addAndRegisterActionGroup(languageImplBindings.getBuildActionGroup(), IdeActions.GROUP_MAIN_MENU, "ToolsMenu", Anchor.AFTER); }
From source file:org.metaborg.intellij.idea.languages.DefaultIdeaLanguageManager.java
License:Apache License
/** * Deactivates the specified language.//from ww w . j a v a2 s.com * * @param languageImplBindings * The bindings of the language implementation to deactivate. */ private void deactivateLanguageImpl(final LanguageImplBindings languageImplBindings) { this.actionUtils.removeAndUnregisterActionGroup(languageImplBindings.getBuildActionGroup(), IdeActions.GROUP_MAIN_MENU); }