use of com.intellij.ide.actions.CloseActiveTabAction in project intellij-plugins by JetBrains.
the class DartPubActionBase method createToolWindowActionsBar.
@NotNull
private static ActionToolbar createToolWindowActionsBar(@NotNull final PubToolWindowContentInfo info) {
final DefaultActionGroup actionGroup = new DefaultActionGroup();
final RerunPubCommandAction rerunPubCommandAction = new RerunPubCommandAction(info);
info.rerunPubCommandAction = rerunPubCommandAction;
actionGroup.addAction(rerunPubCommandAction);
final StopProcessAction stopProcessAction = new StopProcessAction(DartBundle.message("stop.pub.process.action"), DartBundle.message("stop.pub.process.action"), null);
info.stopProcessAction = stopProcessAction;
actionGroup.addAction(stopProcessAction);
actionGroup.add(ActionManager.getInstance().getAction(IdeActions.ACTION_PIN_ACTIVE_TAB));
final AnAction closeContentAction = new CloseActiveTabAction();
closeContentAction.getTemplatePresentation().setIcon(AllIcons.Actions.Cancel);
closeContentAction.getTemplatePresentation().setText(UIBundle.message("tabbed.pane.close.tab.action.name"));
actionGroup.add(closeContentAction);
final ActionToolbar toolbar = ActionManager.getInstance().createActionToolbar("DartPubAction", actionGroup, false);
toolbar.setTargetComponent(info.console.getComponent());
return toolbar;
}
Aggregations