remove priority all togther, maybe add something like severity in the future, https://github.com/microsoft/vscode/issues/54938
This commit is contained in:
parent
8932f62afa
commit
0a914e0e61
5 changed files with 6 additions and 11 deletions
|
@ -13,7 +13,7 @@ import { GitErrorCodes, Status } from './api/git';
|
|||
|
||||
class GitIgnoreDecorationProvider implements FileDecorationProvider {
|
||||
|
||||
private static Decoration: FileDecoration = { priority: 3, color: new ThemeColor('gitDecoration.ignoredResourceForeground') };
|
||||
private static Decoration: FileDecoration = { color: new ThemeColor('gitDecoration.ignoredResourceForeground') };
|
||||
|
||||
readonly onDidChange: Event<Uri[]>;
|
||||
private queue = new Map<string, { repository: Repository; queue: Map<string, PromiseSource<FileDecoration | undefined>>; }>();
|
||||
|
|
7
src/vs/vscode.proposed.d.ts
vendored
7
src/vs/vscode.proposed.d.ts
vendored
|
@ -717,7 +717,7 @@ declare module 'vscode' {
|
|||
|
||||
//#region file-decorations: https://github.com/microsoft/vscode/issues/54938
|
||||
|
||||
// TODO@jrieken priority -> DecorationSeverity.INFO,WARN,ERROR
|
||||
|
||||
export class FileDecoration {
|
||||
|
||||
/**
|
||||
|
@ -735,11 +735,6 @@ declare module 'vscode' {
|
|||
*/
|
||||
color?: ThemeColor;
|
||||
|
||||
/**
|
||||
* The priority of this decoration.
|
||||
*/
|
||||
priority?: number;
|
||||
|
||||
/**
|
||||
* A flag expressing that this decoration should be
|
||||
* propagated to its parents.
|
||||
|
|
|
@ -92,9 +92,9 @@ export class MainThreadDecorations implements MainThreadDecorationsShape {
|
|||
if (!data) {
|
||||
return undefined;
|
||||
}
|
||||
const [weight, bubble, tooltip, letter, themeColor] = data;
|
||||
const [bubble, tooltip, letter, themeColor] = data;
|
||||
return <IDecorationData>{
|
||||
weight: weight ?? 0,
|
||||
weight: 10,
|
||||
bubble: bubble ?? false,
|
||||
color: themeColor?.id,
|
||||
tooltip,
|
||||
|
|
|
@ -1605,7 +1605,7 @@ export interface DecorationRequest {
|
|||
readonly uri: UriComponents;
|
||||
}
|
||||
|
||||
export type DecorationData = [number, boolean, string, string, ThemeColor];
|
||||
export type DecorationData = [boolean, string, string, ThemeColor];
|
||||
export type DecorationReply = { [id: number]: DecorationData; };
|
||||
|
||||
export interface ExtHostDecorationsShape {
|
||||
|
|
|
@ -71,7 +71,7 @@ export class ExtHostDecorations implements ExtHostDecorationsShape {
|
|||
}
|
||||
try {
|
||||
FileDecoration.validate(data);
|
||||
result[id] = <DecorationData>[data.priority, data.propagte, data.tooltip, data.badge, data.color];
|
||||
result[id] = <DecorationData>[data.propagte, data.tooltip, data.badge, data.color];
|
||||
} catch (e) {
|
||||
this._logService.warn(`INVALID decoration from extension '${extensionId.value}': ${e}`);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue