internal: Use statusBarItem colors for status item in VSCode

This commit is contained in:
Lukas Wirth 2022-05-26 12:31:07 +02:00
parent 5410ace1fe
commit 02c2377229

View File

@ -86,13 +86,19 @@ export class Ctx {
case "warning":
this.statusBar.tooltip += "\nClick to reload.";
this.statusBar.command = "rust-analyzer.reloadWorkspace";
this.statusBar.color = new vscode.ThemeColor("notificationsWarningIcon.foreground");
this.statusBar.color = new vscode.ThemeColor("statusBarItem.warningForeground");
this.statusBar.backgroundColor = new vscode.ThemeColor(
"statusBarItem.warningBackground"
);
icon = "$(warning) ";
break;
case "error":
this.statusBar.tooltip += "\nClick to reload.";
this.statusBar.command = "rust-analyzer.reloadWorkspace";
this.statusBar.color = new vscode.ThemeColor("notificationsErrorIcon.foreground");
this.statusBar.color = new vscode.ThemeColor("statusBarItem.errorForeground");
this.statusBar.backgroundColor = new vscode.ThemeColor(
"statusBarItem.errorBackground"
);
icon = "$(error) ";
break;
}