本文整理汇总了Java中com.intellij.ide.actions.ContextHelpAction类的典型用法代码示例。如果您正苦于以下问题:Java ContextHelpAction类的具体用法?Java ContextHelpAction怎么用?Java ContextHelpAction使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ContextHelpAction类属于com.intellij.ide.actions包,在下文中一共展示了ContextHelpAction类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: createToolbar
import com.intellij.ide.actions.ContextHelpAction; //导入依赖的package包/类
private JComponent createToolbar() {
DefaultActionGroup group = new DefaultActionGroup();
group.add(new CloseAction());
group.add(new RerunAction(this));
group.add(new FlattenPackagesAction());
group.add(new ShowFilesAction());
if (ModuleManager.getInstance(myProject).getModules().length > 1) {
group.add(new ShowModulesAction());
group.add(new ShowModuleGroupsAction());
}
group.add(new GroupByScopeTypeAction());
//group.add(new GroupByFilesAction());
group.add(new FilterLegalsAction());
group.add(new MarkAsIllegalAction());
group.add(new ChooseScopeTypeAction());
group.add(new EditDependencyRulesAction());
group.add(CommonActionsManager.getInstance().createExportToTextFileAction(new DependenciesExporterToTextFile()));
group.add(new ContextHelpAction("dependency.viewer.tool.window"));
ActionToolbar toolbar = ActionManager.getInstance().createActionToolbar(ActionPlaces.UNKNOWN, group, true);
return toolbar.getComponent();
}
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:23,代码来源:DependenciesPanel.java
示例2: appendActions
import com.intellij.ide.actions.ContextHelpAction; //导入依赖的package包/类
protected void appendActions(@NotNull DefaultActionGroup actionGroup, @Nullable String helpID) {
actionGroup.add(myAutoScrollToSourceHandler.createToggleAction());
final ActionManager actionManager = ActionManager.getInstance();
actionGroup.add(actionManager.getAction(IdeActions.ACTION_EXPAND_ALL));
actionGroup.add(new PinToolwindowTabAction(){
@Override
public void update(AnActionEvent event) {
super.update(event);
// sometimes there is no content to close, e.g. in usage view preview
event.getPresentation().setVisible(myContent != null);
}
});
actionGroup.add(CommonActionsManager.getInstance().createExportToTextFileAction(new ExporterToTextFileHierarchy(this)));
actionGroup.add(new CloseAction());
if (helpID != null) {
actionGroup.add(new ContextHelpAction(helpID));
}
}
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:19,代码来源:HierarchyBrowserBase.java
示例3: patchLeftToolbar
import com.intellij.ide.actions.ContextHelpAction; //导入依赖的package包/类
private static void patchLeftToolbar(@NotNull XDebugSession session, @NotNull RunnerLayoutUi ui) {
DefaultActionGroup newLeftToolbar = new DefaultActionGroup();
DefaultActionGroup firstGroup = new DefaultActionGroup();
addActionToGroup(firstGroup, XDebuggerActions.RESUME);
addActionToGroup(firstGroup, IdeActions.ACTION_STOP_PROGRAM);
newLeftToolbar.addAll(firstGroup);
newLeftToolbar.addSeparator();
Executor executor = PyEduDebugExecutor.getInstance();
newLeftToolbar.add(new CloseAction(executor, session.getRunContentDescriptor(), session.getProject()));
//TODO: return proper helpID
newLeftToolbar.add(new ContextHelpAction(executor.getHelpId()));
ui.getOptions().setLeftToolbar(newLeftToolbar, ActionPlaces.DEBUGGER_TOOLBAR);
}
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:18,代码来源:PyEduDebugRunner.java
示例4: createToolbarPanel
import com.intellij.ide.actions.ContextHelpAction; //导入依赖的package包/类
private JPanel createToolbarPanel() {
final DefaultActionGroup group = new DefaultActionGroup();
group.add(new AddAction());
group.add(new RemoveAction());
group.add(new RunAction());
group.add(new ShowAllTargetsAction());
AnAction action = CommonActionsManager.getInstance().createExpandAllAction(myTreeExpander, this);
action.getTemplatePresentation().setDescription(AntBundle.message("ant.explorer.expand.all.nodes.action.description"));
group.add(action);
action = CommonActionsManager.getInstance().createCollapseAllAction(myTreeExpander, this);
action.getTemplatePresentation().setDescription(AntBundle.message("ant.explorer.collapse.all.nodes.action.description"));
group.add(action);
group.add(myAntBuildFilePropertiesAction);
group.add(new ContextHelpAction(HelpID.ANT));
final ActionToolbar actionToolBar = ActionManager.getInstance().createActionToolbar(ActionPlaces.ANT_EXPLORER_TOOLBAR, group, true);
return JBUI.Panels.simplePanel(actionToolBar.getComponent());
}
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:19,代码来源:AntExplorer.java
示例5: CvsTabbedWindowComponent
import com.intellij.ide.actions.ContextHelpAction; //导入依赖的package包/类
public CvsTabbedWindowComponent(JComponent component, boolean addDefaultToolbar,
@Nullable ActionGroup toolbarActions,
ContentManager contentManager, String helpId) {
super(new BorderLayout());
myAddToolbar = addDefaultToolbar;
myComponent = component;
myContentManager = contentManager;
myHelpId = helpId;
add(myComponent, BorderLayout.CENTER);
if (myAddToolbar) {
DefaultActionGroup actionGroup = new DefaultActionGroup(null, false);
actionGroup.add(new CloseAction());
if (toolbarActions != null) {
actionGroup.add(toolbarActions);
}
actionGroup.add(new ContextHelpAction(helpId));
add(ActionManager.getInstance().
createActionToolbar("DefaultCvsComponentToolbar", actionGroup, false).getComponent(),
BorderLayout.WEST);
}
}
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:24,代码来源:CvsTabbedWindowComponent.java
示例6: createToolbarActions
import com.intellij.ide.actions.ContextHelpAction; //导入依赖的package包/类
private ActionGroup createToolbarActions(final CoverageViewTreeStructure treeStructure) {
final DefaultActionGroup actionGroup = new DefaultActionGroup();
actionGroup.add(new GoUpAction(treeStructure));
if (treeStructure.supportFlattenPackages()) {
actionGroup.add(new FlattenPackagesAction());
}
installAutoScrollToSource(actionGroup);
installAutoScrollFromSource(actionGroup);
actionGroup.add(ActionManager.getInstance().getAction("GenerateCoverageReport"));
actionGroup.add(new CloseTabToolbarAction() {
@Override
public void actionPerformed(AnActionEvent e) {
CoverageDataManager.getInstance(myProject).chooseSuitesBundle(null);
}
});
actionGroup.add(new ContextHelpAction(HELP_ID));
return actionGroup;
}
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:21,代码来源:CoverageView.java
示例7: appendActions
import com.intellij.ide.actions.ContextHelpAction; //导入依赖的package包/类
protected void appendActions(@NotNull DefaultActionGroup actionGroup, @Nullable String helpID) {
actionGroup.add(myAutoScrollToSourceHandler.createToggleAction());
actionGroup.add(ActionManager.getInstance().getAction(IdeActions.ACTION_EXPAND_ALL));
actionGroup.add(new PinToolwindowTabAction(){
@Override
public void update(AnActionEvent event) {
super.update(event);
// sometimes there is no content to close, e.g. in usage view preview
event.getPresentation().setVisible(myContent != null);
}
});
actionGroup.add(new CloseAction());
if (helpID != null) {
actionGroup.add(new ContextHelpAction(helpID));
}
}
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:17,代码来源:HierarchyBrowserBase.java
示例8: setToolbarActions
import com.intellij.ide.actions.ContextHelpAction; //导入依赖的package包/类
public final void setToolbarActions(final AnAction... actions) {
final DefaultActionGroup actionGroup = new DefaultActionGroup();
for (final AnAction action : actions) {
actionGroup.add(action);
}
if (getHelpId() != null) {
actionGroup.add(Separator.getInstance());
actionGroup.add(new ContextHelpAction(getHelpId()));
}
final ActionManager actionManager = ActionManager.getInstance();
final ToolbarPosition position = getToolbarPosition();
final ActionToolbar myActionToolbar = actionManager.createActionToolbar(ActionPlaces.PROJECT_VIEW_TOOLBAR, actionGroup, position == ToolbarPosition.TOP || position == ToolbarPosition.BOTTOM);
myActionToolbar.setTargetComponent(myInnerPanel);
final JComponent toolbarComponent = myActionToolbar.getComponent();
final MatteBorder matteBorder = BorderFactory.createMatteBorder(0, 0, position == ToolbarPosition.TOP ? 1 : 0, 0, JBColor.DARK_GRAY);
toolbarComponent.setBorder(BorderFactory.createCompoundBorder(matteBorder, toolbarComponent.getBorder()));
getTable().getSelectionModel().addListSelectionListener(new ListSelectionListener() {
public void valueChanged(ListSelectionEvent e) {
myActionToolbar.updateActionsImmediately();
}
});
add(toolbarComponent, position.getPosition());
}
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:27,代码来源:AbstractTableView.java
示例9: createToolbarPanel
import com.intellij.ide.actions.ContextHelpAction; //导入依赖的package包/类
private JPanel createToolbarPanel() {
final DefaultActionGroup group = new DefaultActionGroup();
group.add(new AddAction());
group.add(new RemoveAction());
group.add(new RunAction());
group.add(new ShowAllTargetsAction());
AnAction action = CommonActionsManager.getInstance().createExpandAllAction(myTreeExpander, this);
action.getTemplatePresentation().setDescription(AntBundle.message("ant.explorer.expand.all.nodes.action.description"));
group.add(action);
action = CommonActionsManager.getInstance().createCollapseAllAction(myTreeExpander, this);
action.getTemplatePresentation().setDescription(AntBundle.message("ant.explorer.collapse.all.nodes.action.description"));
group.add(action);
group.add(myAntBuildFilePropertiesAction);
group.add(new ContextHelpAction(HelpID.ANT));
final ActionToolbar actionToolBar = ActionManager.getInstance().createActionToolbar(ActionPlaces.ANT_EXPLORER_TOOLBAR, group, true);
final JPanel buttonsPanel = new JPanel(new BorderLayout());
buttonsPanel.add(actionToolBar.getComponent(), BorderLayout.CENTER);
return buttonsPanel;
}
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:21,代码来源:AntExplorer.java
示例10: createToolbarPanel
import com.intellij.ide.actions.ContextHelpAction; //导入依赖的package包/类
private JPanel createToolbarPanel() {
final DefaultActionGroup group = new DefaultActionGroup();
group.add(new AddAction());
group.add(new RemoveAction());
group.add(new RunAction());
group.add(myAntBuildFilePropertiesAction);
group.addSeparator();
group.add(new ShowAllTargetsAction());
group.add(new ShowModuleGrouping());
AnAction action = CommonActionsManager.getInstance().createExpandAllAction(myTreeExpander, this);
action.getTemplatePresentation().setDescription(AntBundle.message("ant.explorer.expand.all.nodes.action.description"));
group.add(action);
action = CommonActionsManager.getInstance().createCollapseAllAction(myTreeExpander, this);
action.getTemplatePresentation().setDescription(AntBundle.message("ant.explorer.collapse.all.nodes.action.description"));
group.add(action);
group.addSeparator();
group.add(new ContextHelpAction(HelpID.ANT));
final ActionToolbar actionToolBar = ActionManager.getInstance().createActionToolbar(ActionPlaces.ANT_EXPLORER_TOOLBAR, group, true);
final JPanel buttonsPanel = new JPanel(new BorderLayout());
buttonsPanel.add(actionToolBar.getComponent(), BorderLayout.CENTER);
return buttonsPanel;
}
开发者ID:consulo,项目名称:consulo-apache-ant,代码行数:24,代码来源:AntExplorer.java
示例11: appendActions
import com.intellij.ide.actions.ContextHelpAction; //导入依赖的package包/类
protected void appendActions(@Nonnull DefaultActionGroup actionGroup, @Nullable String helpID) {
actionGroup.add(myAutoScrollToSourceHandler.createToggleAction());
actionGroup.add(ActionManager.getInstance().getAction(IdeActions.ACTION_EXPAND_ALL));
actionGroup.add(new PinToolwindowTabAction() {
@Override
public void update(AnActionEvent event) {
super.update(event);
// sometimes there is no content to close, e.g. in usage view preview
event.getPresentation().setVisible(myContent != null);
}
});
actionGroup.add(new CloseAction());
if (helpID != null) {
actionGroup.add(new ContextHelpAction(helpID));
}
}
开发者ID:consulo,项目名称:consulo,代码行数:17,代码来源:HierarchyBrowserBase.java
示例12: setToolbarActions
import com.intellij.ide.actions.ContextHelpAction; //导入依赖的package包/类
public final void setToolbarActions(final AnAction... actions) {
final DefaultActionGroup actionGroup = new DefaultActionGroup();
for (final AnAction action : actions) {
actionGroup.add(action);
}
if (getHelpId() != null) {
actionGroup.add(AnSeparator.getInstance());
actionGroup.add(new ContextHelpAction(getHelpId()));
}
final ActionManager actionManager = ActionManager.getInstance();
final ToolbarPosition position = getToolbarPosition();
final ActionToolbar myActionToolbar = actionManager.createActionToolbar(ActionPlaces.PROJECT_VIEW_TOOLBAR, actionGroup, position == ToolbarPosition.TOP || position == ToolbarPosition.BOTTOM);
myActionToolbar.setTargetComponent(myInnerPanel);
final JComponent toolbarComponent = myActionToolbar.getComponent();
final MatteBorder matteBorder = BorderFactory.createMatteBorder(0, 0, position == ToolbarPosition.TOP ? 1 : 0, 0, JBColor.DARK_GRAY);
toolbarComponent.setBorder(BorderFactory.createCompoundBorder(matteBorder, toolbarComponent.getBorder()));
getTable().getSelectionModel().addListSelectionListener(new ListSelectionListener() {
public void valueChanged(ListSelectionEvent e) {
myActionToolbar.updateActionsImmediately();
}
});
add(toolbarComponent, position.getPosition());
}
开发者ID:consulo,项目名称:consulo-xml,代码行数:27,代码来源:AbstractTableView.java
示例13: initActions
import com.intellij.ide.actions.ContextHelpAction; //导入依赖的package包/类
@Override
public void initActions(RunContentDescriptor content, DefaultActionGroup actionGroup) {
Executor executor = myExecutionEnvironment.getExecutor();
actionGroup.add(ActionManager.getInstance().getAction(IdeActions.ACTION_RERUN), Constraints.FIRST);
actionGroup.add(new CloseAction(executor, content, myExecutionEnvironment.getProject()));
actionGroup.add(new ContextHelpAction(executor.getHelpId()));
}
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:9,代码来源:DefaultDebugUIEnvironment.java
示例14: createToolbar
import com.intellij.ide.actions.ContextHelpAction; //导入依赖的package包/类
private JComponent createToolbar() {
DefaultActionGroup group = new DefaultActionGroup();
group.add(new CloseAction());
group.add(new RerunAction(this));
group.add(new ShowFilesAction());
group.add(new HideOutOfCyclePackagesAction());
group.add(new GroupByScopeTypeAction());
group.add(new ContextHelpAction("dependency.viewer.tool.window"));
ActionToolbar toolbar = ActionManager.getInstance().createActionToolbar(ActionPlaces.UNKNOWN, group, true);
return toolbar.getComponent();
}
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:13,代码来源:CyclicDependenciesPanel.java
示例15: createToolbar
import com.intellij.ide.actions.ContextHelpAction; //导入依赖的package包/类
private JComponent createToolbar() {
DefaultActionGroup group = new DefaultActionGroup();
group.add(ActionManager.getInstance().getAction(SERVERS_TOOL_WINDOW_TOOLBAR));
group.add(new Separator());
group.add(new ContextHelpAction(HELP_ID));
ActionToolbar actionToolBar = ActionManager.getInstance().createActionToolbar(PLACE_TOOLBAR, group, false);
myTree.putClientProperty(DataManager.CLIENT_PROPERTY_DATA_PROVIDER, new DataProvider() {
@Override
public Object getData(@NonNls String dataId) {
if (KEY.getName().equals(dataId)) {
return ServersToolWindowContent.this;
}
for (RemoteServersViewContributor contributor : RemoteServersViewContributor.EP_NAME.getExtensions()) {
Object data = contributor.getData(dataId, ServersToolWindowContent.this);
if (data != null) {
return data;
}
}
return null;
}
});
actionToolBar.setTargetComponent(myTree);
return actionToolBar.getComponent();
}
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:29,代码来源:ServersToolWindowContent.java
示例16: createRevisionsActions
import com.intellij.ide.actions.ContextHelpAction; //导入依赖的package包/类
private ActionGroup createRevisionsActions() {
DefaultActionGroup result = new DefaultActionGroup();
result.add(new RevertAction());
result.add(new CreatePatchAction());
result.add(Separator.getInstance());
result.add(new ContextHelpAction(getHelpId()));
return result;
}
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:9,代码来源:HistoryDialog.java
示例17: createToolbar
import com.intellij.ide.actions.ContextHelpAction; //导入依赖的package包/类
private static ActionToolbar createToolbar(Project project, Editor editor, EventLogConsole console) {
DefaultActionGroup group = new DefaultActionGroup();
group.add(new EditNotificationSettings(project));
group.add(new DisplayBalloons());
group.add(new ToggleSoftWraps(editor));
group.add(new ScrollToTheEndToolbarAction(editor));
group.add(ActionManager.getInstance().getAction(IdeActions.ACTION_MARK_ALL_NOTIFICATIONS_AS_READ));
group.add(new EventLogConsole.ClearLogAction(console));
group.add(new ContextHelpAction(EventLog.HELP_ID));
return ActionManager.getInstance().createActionToolbar(ActionPlaces.UNKNOWN, group, false);
}
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:13,代码来源:EventLogToolWindowFactory.java
示例18: createGroupFilterToolbar
import com.intellij.ide.actions.ContextHelpAction; //导入依赖的package包/类
public ActionToolbar createGroupFilterToolbar(final Project project, final ActionGroup leadGroup, @Nullable final ActionGroup tailGroup,
final List<AnAction> extra) {
DefaultActionGroup toolbarGroup = new DefaultActionGroup();
toolbarGroup.add(leadGroup);
toolbarGroup.addSeparator();
toolbarGroup.add(new SelectFilteringAction(project, this));
toolbarGroup.add(new SelectGroupingAction(project, this));
final ExpandAllAction expandAllAction = new ExpandAllAction(myChangesTree);
final CollapseAllAction collapseAllAction = new CollapseAllAction(myChangesTree);
expandAllAction.registerCustomShortcutSet(
new CustomShortcutSet(KeymapManager.getInstance().getActiveKeymap().getShortcuts(IdeActions.ACTION_EXPAND_ALL)),
myChangesTree);
collapseAllAction.registerCustomShortcutSet(
new CustomShortcutSet(KeymapManager.getInstance().getActiveKeymap().getShortcuts(IdeActions.ACTION_COLLAPSE_ALL)),
myChangesTree);
toolbarGroup.add(expandAllAction);
toolbarGroup.add(collapseAllAction);
toolbarGroup.add(ActionManager.getInstance().getAction(VcsActions.ACTION_COPY_REVISION_NUMBER));
toolbarGroup.add(new ContextHelpAction(myHelpId));
if (tailGroup != null) {
toolbarGroup.add(tailGroup);
}
for (AnAction anAction : extra) {
toolbarGroup.add(anAction);
}
return ActionManager.getInstance().createActionToolbar(ActionPlaces.UNKNOWN, toolbarGroup, true);
}
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:28,代码来源:CommittedChangesTreeBrowser.java
示例19: createLeftActionsToolbar
import com.intellij.ide.actions.ContextHelpAction; //导入依赖的package包/类
private JComponent createLeftActionsToolbar() {
final CommonActionsManager actionsManager = CommonActionsManager.getInstance();
DefaultActionGroup group = new DefaultActionGroup();
group.add(new RerunAction(this));
group.add(new CloseAction());
final TreeExpander treeExpander = new TreeExpander() {
@Override
public void expandAll() {
TreeUtil.expandAll(myTree);
}
@Override
public boolean canExpand() {
return true;
}
@Override
public void collapseAll() {
TreeUtil.collapseAll(myTree, 0);
}
@Override
public boolean canCollapse() {
return true;
}
};
group.add(actionsManager.createExpandAllAction(treeExpander, myTree));
group.add(actionsManager.createCollapseAllAction(treeExpander, myTree));
group.add(actionsManager.createPrevOccurenceAction(getOccurenceNavigator()));
group.add(actionsManager.createNextOccurenceAction(getOccurenceNavigator()));
group.add(myGlobalInspectionContext.createToggleAutoscrollAction());
group.add(new ExportHTMLAction(this));
group.add(new ContextHelpAction(HELP_ID));
return createToolbar(group);
}
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:37,代码来源:InspectionResultsView.java
示例20: createActionToolbar
import com.intellij.ide.actions.ContextHelpAction; //导入依赖的package包/类
@NotNull
private ActionGroup createActionToolbar(@NotNull final RunContentDescriptor contentDescriptor) {
final DefaultActionGroup actionGroup = new DefaultActionGroup();
actionGroup.add(ActionManager.getInstance().getAction(IdeActions.ACTION_RERUN));
final AnAction[] actions = contentDescriptor.getRestartActions();
actionGroup.addAll(actions);
if (actions.length > 0) {
actionGroup.addSeparator();
}
actionGroup.add(ActionManager.getInstance().getAction(IdeActions.ACTION_STOP_PROGRAM));
if (myExecutionResult instanceof DefaultExecutionResult) {
actionGroup.addAll(((DefaultExecutionResult)myExecutionResult).getAdditionalStopActions());
}
actionGroup.addAll(myExecutionResult.getActions());
for (AnAction anAction : myRunnerActions) {
if (anAction != null) {
actionGroup.add(anAction);
}
else {
actionGroup.addSeparator();
}
}
actionGroup.addSeparator();
actionGroup.add(myUi.getOptions().getLayoutActions());
actionGroup.addSeparator();
actionGroup.add(PinToolwindowTabAction.getPinAction());
actionGroup.add(new CloseAction(myEnvironment.getExecutor(), contentDescriptor, myProject));
final String helpId = contentDescriptor.getHelpId();
actionGroup.add(new ContextHelpAction(helpId != null ? helpId : myEnvironment.getExecutor().getHelpId()));
return actionGroup;
}
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:37,代码来源:RunContentBuilder.java
注:本文中的com.intellij.ide.actions.ContextHelpAction类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论