Example usage for com.intellij.openapi.actionSystem ActionPlaces SCOPE_VIEW_POPUP

List of usage examples for com.intellij.openapi.actionSystem ActionPlaces SCOPE_VIEW_POPUP

Introduction

In this page you can find the example usage for com.intellij.openapi.actionSystem ActionPlaces SCOPE_VIEW_POPUP.

Prototype

String SCOPE_VIEW_POPUP

To view the source code for com.intellij.openapi.actionSystem ActionPlaces SCOPE_VIEW_POPUP.

Click Source Link

Usage

From source file:com.intellij.ide.scopeView.ScopeViewPane.java

License:Apache License

@Override
public JComponent createComponent() {
    myViewPanel = new ScopeTreeViewPanel(myProject);
    Disposer.register(this, myViewPanel);
    myViewPanel.initListeners();//w w w  .  j  ava  2 s . c o m
    myViewPanel.selectScope(NamedScopesHolder.getScope(myProject, getSubId()));
    myTree = myViewPanel.getTree();
    PopupHandler.installPopupHandler(myTree, IdeActions.GROUP_SCOPE_VIEW_POPUP, ActionPlaces.SCOPE_VIEW_POPUP);
    enableDnD();

    return myViewPanel.getPanel();
}

From source file:com.intellij.tools.BaseExternalToolsGroup.java

License:Apache License

private boolean isToolVisible(T tool, String context) {
    if (!tool.isEnabled())
        return false;
    if (ActionPlaces.EDITOR_POPUP.equals(context) || ActionPlaces.EDITOR_TAB_POPUP.equals(context)) {
        return tool.isShownInEditor();
    } else if (ActionPlaces.PROJECT_VIEW_POPUP.equals(context) || ActionPlaces.COMMANDER_POPUP.equals(context)
            || ActionPlaces.J2EE_VIEW_POPUP.equals(context)
            || ActionPlaces.TYPE_HIERARCHY_VIEW_POPUP.equals(context)
            || ActionPlaces.CALL_HIERARCHY_VIEW_POPUP.equals(context)
            || ActionPlaces.METHOD_HIERARCHY_VIEW_POPUP.equals(context)
            || ActionPlaces.FAVORITES_VIEW_POPUP.equals(context)
            || ActionPlaces.SCOPE_VIEW_POPUP.equals(context) || ActionPlaces.NAVIGATION_BAR.equals(context)) {
        return tool.isShownInProjectViews();
    } else if (ActionPlaces.MAIN_MENU.equals(context)) {
        return tool.isShownInMainMenu();
    } else if (ActionPlaces.USAGE_VIEW_POPUP.equals(context)) {
        return tool.isShownInSearchResultsPopup();
    }/*from ww  w  .j a va2s  .c o  m*/
    return false;
}