2718: Allow disabling inlay hints r=matklad a=matklad



Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
This commit is contained in:
bors[bot] 2020-01-01 16:06:21 +00:00 committed by GitHub
commit d0a59164d5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -41,10 +41,11 @@ const typeHintDecorationType = vscode.window.createTextEditorDecorationType({
class HintsUpdater { class HintsUpdater {
private pending: Map<string, vscode.CancellationTokenSource> = new Map(); private pending: Map<string, vscode.CancellationTokenSource> = new Map();
private ctx: Ctx; private ctx: Ctx;
private enabled = true; private enabled: boolean;
constructor(ctx: Ctx) { constructor(ctx: Ctx) {
this.ctx = ctx; this.ctx = ctx;
this.enabled = ctx.config.displayInlayHints;
} }
async setEnabled(enabled: boolean) { async setEnabled(enabled: boolean) {