提交 317ee159 编写于 作者: A Alex Ross

Fix description of task in task quick open

Fixes https://github.com/microsoft/vscode/issues/89441
上级 1b00acf1
......@@ -2480,7 +2480,7 @@ export abstract class AbstractTaskService extends Disposable implements ITaskSer
}
}
private getTaskDescription(task: Task): string | undefined {
public getTaskDescription(task: Task): string | undefined {
let description: string | undefined;
if (task._source.kind === TaskSourceKind.User) {
description = nls.localize('taskQuickPick.userSettings', 'User Settings');
......
......@@ -29,14 +29,7 @@ export class TaskEntry extends Model.QuickOpenEntry {
}
public getDescription(): string | undefined {
if (!this.taskService.needsFolderQualification()) {
return undefined;
}
let workspaceFolder = this.task.getWorkspaceFolder();
if (!workspaceFolder) {
return undefined;
}
return `${workspaceFolder.name}`;
return this.taskService.getTaskDescription(this.task);
}
public getAriaLabel(): string {
......
......@@ -76,7 +76,7 @@ export interface ITaskService {
getRecentlyUsedTasks(): LinkedMap<string, string>;
createSorter(): TaskSorter;
needsFolderQualification(): boolean;
getTaskDescription(task: Task): string | undefined;
canCustomize(task: ContributedTask | CustomTask): boolean;
customize(task: ContributedTask | CustomTask, properties?: {}, openConfig?: boolean): Promise<void>;
openConfig(task: CustomTask | undefined): Promise<void>;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册