diff --git a/platform/execution-impl/src/com/intellij/execution/ui/RunContentManagerImpl.kt b/platform/execution-impl/src/com/intellij/execution/ui/RunContentManagerImpl.kt index 70947618ab51..f3d7dbfaff0c 100644 --- a/platform/execution-impl/src/com/intellij/execution/ui/RunContentManagerImpl.kt +++ b/platform/execution-impl/src/com/intellij/execution/ui/RunContentManagerImpl.kt @@ -1,4 +1,4 @@ -// Copyright 2000-2022 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license. +// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license. @file:Suppress("ReplacePutWithAssignment", "ReplaceGetOrSet") package com.intellij.execution.ui @@ -436,7 +436,7 @@ class RunContentManagerImpl(private val project: Project) : RunContentManager { } getToolWindowManager().getToolWindow(id)?.apply { - stripeTitle = executor.actionName + stripeTitle = executor.toolWindowTitle setIcon(executor.toolWindowIcon) toolWindowIdToBaseIcon[id] = executor.toolWindowIcon } diff --git a/platform/execution/api-dump-unreviewed.txt b/platform/execution/api-dump-unreviewed.txt index b4a099dfd5e6..336f536e110f 100644 --- a/platform/execution/api-dump-unreviewed.txt +++ b/platform/execution/api-dump-unreviewed.txt @@ -252,6 +252,7 @@ a:com.intellij.execution.Executor - getStartActionText(java.lang.String):java.lang.String - a:getToolWindowIcon():javax.swing.Icon - a:getToolWindowId():java.lang.String +- getToolWindowTitle():java.lang.String - isApplicable(com.intellij.openapi.project.Project):Z - s:shortenNameIfNeeded(java.lang.String):java.lang.String a:com.intellij.execution.ExecutorRegistry diff --git a/platform/execution/src/com/intellij/execution/Executor.java b/platform/execution/src/com/intellij/execution/Executor.java index 5a838400d312..9d2005634fa0 100644 --- a/platform/execution/src/com/intellij/execution/Executor.java +++ b/platform/execution/src/com/intellij/execution/Executor.java @@ -1,10 +1,11 @@ -// Copyright 2000-2023 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license. +// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license. package com.intellij.execution; import com.intellij.execution.executors.DefaultRunExecutor; import com.intellij.openapi.extensions.ExtensionPointName; import com.intellij.openapi.project.Project; import com.intellij.openapi.util.NlsActions; +import com.intellij.openapi.util.NlsContexts; import com.intellij.openapi.util.NlsSafe; import com.intellij.openapi.util.registry.Registry; import com.intellij.openapi.util.text.StringUtil; @@ -54,6 +55,13 @@ public abstract class Executor { public abstract @NotNull @NlsActions.ActionText String getActionName(); + /** + * @return tool window title text that will be applied to a tool window when it's customized. + */ + public @NotNull @NlsContexts.TabTitle String getToolWindowTitle() { + return getActionName(); + } + /** * @return the unique ID of the executor */