diff --git a/platform/lang-impl/src/com/intellij/execution/impl/ConsoleViewImpl.java b/platform/lang-impl/src/com/intellij/execution/impl/ConsoleViewImpl.java index 39e3f980d4df..e9c60bb92039 100644 --- a/platform/lang-impl/src/com/intellij/execution/impl/ConsoleViewImpl.java +++ b/platform/lang-impl/src/com/intellij/execution/impl/ConsoleViewImpl.java @@ -985,7 +985,7 @@ public class ConsoleViewImpl extends JPanel implements ConsoleView, ObservableCo public static class ClearAllAction extends DumbAwareAction { public ClearAllAction() { - super(ExecutionBundle.message("clear.all.from.console.action.name")); + super(ExecutionBundle.message("clear.all.from.console.action.name"), "Clear the contents of the console", IconLoader.findIcon("/actions/gc.png")); } @Override @@ -1356,21 +1356,20 @@ public class ConsoleViewImpl extends JPanel implements ConsoleView, ObservableCo final AnAction autoScrollToTheEndAction = new ScrollToTheEndToolbarAction(myEditor); //Initializing custom actions - final AnAction[] consoleActions = new AnAction[4 + customActions.size()]; + final AnAction[] consoleActions = new AnAction[5 + customActions.size()]; consoleActions[0] = prevAction; consoleActions[1] = nextAction; consoleActions[2] = switchSoftWrapsAction; consoleActions[3] = autoScrollToTheEndAction; + consoleActions[4] = new ClearAllAction(); //consoleActions[4] = new ShowRecentlyChanged(); for (int i = 0; i < customActions.size(); ++i) { - consoleActions[i + 4] = customActions.get(i); + consoleActions[i + 5] = customActions.get(i); } ConsoleActionsPostProcessor[] postProcessors = Extensions.getExtensions(ConsoleActionsPostProcessor.EP_NAME); AnAction[] result = consoleActions; - if (postProcessors != null) { - for (ConsoleActionsPostProcessor postProcessor : postProcessors) { - result = postProcessor.postProcess(this, result); - } + for (ConsoleActionsPostProcessor postProcessor : postProcessors) { + result = postProcessor.postProcess(this, result); } return result; }