Package com.intellij.openapi.actionSystem

Examples of com.intellij.openapi.actionSystem.ActionPopupMenu


        new ModalTask(getDataset().getProject(), "Loading column information", true) {
            public void run(@NotNull ProgressIndicator progressIndicator) {
                progressIndicator.setIndeterminate(true);
                ActionGroup actionGroup = new DatasetEditorTableActionGroup(datasetEditor, cell, columnInfo);
                if (!progressIndicator.isCanceled()) {
                    ActionPopupMenu actionPopupMenu = ActionManager.getInstance().createActionPopupMenu("", actionGroup);
                    final JPopupMenu popupMenu = actionPopupMenu.getComponent();
                    new SimpleLaterInvocator() {
                        public void execute() {
                            popupMenu.show((Component) event.getSource(), event.getX(), event.getY());
                        }
                    }.start();
View Full Code Here


    actionpopupmenu.getComponent().show(jcomponent, jcomponent.getWidth(), 0);*/

    final InputEvent inputEvent = e.getInputEvent();
    final Component component = inputEvent.getComponent();
    final DefaultActionGroup defaultactiongroup = filterApplierGroup();
    final ActionPopupMenu actionpopupmenu = ActionManager.getInstance().createActionPopupMenu("FindBugs.GroupByFilter.PopupGroup", defaultactiongroup);
    //defaultactiongroup.add(ActionManager.getInstance().getAction("FindBugs.GroupByFilter"));
    //ActionManager.getInstance().getAction("FindBugs.GroupByFilter").getTemplatePresentation().
    //actionpopupmenu.getComponent().setVisible(true);
    actionpopupmenu.getComponent().show(component, component.getWidth(), 0);

  }
View Full Code Here

                    public void mouseReleased(MouseEvent e) {
                        if (e.isPopupTrigger()) {
                            // Single right click unless configured differently
                            ActionManager actionManager = ActionManager.getInstance();
                            DefaultActionGroup defaultActionGroup = (DefaultActionGroup) actionManager.getAction("org.intellij.plugins.junitgen.action.JUnitGeneratorEditorMenu");
                            ActionPopupMenu menu = actionManager.createActionPopupMenu("junitgenerator.editor.popup", defaultActionGroup);
                            menu.getComponent().show(e.getComponent(), e.getX(), e.getY());
                        }
                    }
                });
                this.velocityEditorMap.put(entry.getKey(), editor);
                this.tabbedPane1.addTab(entry.getKey(), editor.getComponent());
View Full Code Here

  public static MouseListener installPopupHandler(JComponent component, final ActionGroup group, final String place, final ActionManager actionManager) {
    if (ApplicationManager.getApplication() == null) return new MouseAdapter(){};
    PopupHandler popupHandler = new PopupHandler() {
      public void invokePopup(Component comp, int x, int y) {
        final ActionPopupMenu popupMenu = actionManager.createActionPopupMenu(place, group);
        popupMenu.getComponent().show(comp, x, y);
      }
    };
    component.addMouseListener(popupHandler);
    return popupHandler;
  }
View Full Code Here

  public static MouseListener installFollowingSelectionTreePopup(final JTree tree, final ActionGroup group, final String place, final ActionManager actionManager){
    if (ApplicationManager.getApplication() == null) return new MouseAdapter(){};
    PopupHandler handler = new PopupHandler() {
      public void invokePopup(Component comp, int x, int y) {
        if (tree.getPathForLocation(x, y) != null && Arrays.binarySearch(tree.getSelectionRows(), tree.getRowForLocation(x, y)) > -1) { //do not show popup menu on rows other than selection
          final ActionPopupMenu popupMenu = actionManager.createActionPopupMenu(place, group);
          popupMenu.getComponent().show(comp, x, y);
        }
      }
    };
    tree.addMouseListener(handler);
    return handler;
View Full Code Here

  }

  protected void invokeContextMenu(final MouseEvent e) {
    SwingUtilities.invokeLater(new Runnable() {
      public void run() {
        final ActionPopupMenu menu = ActionManager.getInstance().createActionPopupMenu(myPlace, myPopupGroup);
        menu.getComponent().show(e.getComponent(), e.getPoint().x, e.getPoint().y);
      }
    });
  }
View Full Code Here

TOP

Related Classes of com.intellij.openapi.actionSystem.ActionPopupMenu

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.