void (final VcsErrorViewPanel errorTreeView, @NotNull @NlsContexts.TabTitle String tabDisplayName) { CommandProcessor commandProcessor = CommandProcessor.getInstance(); commandProcessor.executeCommand(myProject, () -> { final MessageView messageView = MessageView.getInstance(myProject); messageView.runWhenInitialized(() -> { final Content content = ContentFactory.getInstance().createContent(errorTreeView, tabDisplayName, true); messageView.getContentManager().addContent(content); Disposer.register(content, errorTreeView); messageView.getContentManager().setSelectedContent(content); ContentManagerUtil.cleanupContents(content, myProject, tabDisplayName); ToolWindowManager.getInstance(myProject).getToolWindow(ToolWindowId.MESSAGES_WINDOW).activate(null); }); }, VcsBundle.message("command.name.open.error.message.view"), null); }