diff options
author | Veetaha <[email protected]> | 2020-02-13 20:48:20 +0000 |
---|---|---|
committer | Veetaha <[email protected]> | 2020-02-13 20:48:20 +0000 |
commit | 7ad15c396286376c4a439b2dec4ec452b5f28dda (patch) | |
tree | d840788902ed29a561851c6e2ce02b26a14dc559 /editors/code/src/inlay_hints.ts | |
parent | 9b47124e6e5d32a676961c05661934215e98012c (diff) |
vscode: redesigned config with simplicity and Dart extension config implementation in mind
Diffstat (limited to 'editors/code/src/inlay_hints.ts')
-rw-r--r-- | editors/code/src/inlay_hints.ts | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/editors/code/src/inlay_hints.ts b/editors/code/src/inlay_hints.ts index 1c019a51b..3ff45a625 100644 --- a/editors/code/src/inlay_hints.ts +++ b/editors/code/src/inlay_hints.ts | |||
@@ -22,12 +22,12 @@ export function activateInlayHints(ctx: Ctx) { | |||
22 | ); | 22 | ); |
23 | 23 | ||
24 | vscode.workspace.onDidChangeConfiguration( | 24 | vscode.workspace.onDidChangeConfiguration( |
25 | async _ => hintsUpdater.setEnabled(ctx.config.displayInlayHints), | 25 | async _ => hintsUpdater.setEnabled(ctx.config.displayInlayHints()), |
26 | null, | 26 | null, |
27 | ctx.subscriptions | 27 | ctx.subscriptions |
28 | ); | 28 | ); |
29 | 29 | ||
30 | ctx.onDidRestart(_ => hintsUpdater.setEnabled(ctx.config.displayInlayHints)); | 30 | ctx.onDidRestart(_ => hintsUpdater.setEnabled(ctx.config.displayInlayHints())); |
31 | } | 31 | } |
32 | 32 | ||
33 | interface InlayHintsParams { | 33 | interface InlayHintsParams { |
@@ -59,7 +59,7 @@ class HintsUpdater { | |||
59 | 59 | ||
60 | constructor(ctx: Ctx) { | 60 | constructor(ctx: Ctx) { |
61 | this.ctx = ctx; | 61 | this.ctx = ctx; |
62 | this.enabled = ctx.config.displayInlayHints; | 62 | this.enabled = ctx.config.displayInlayHints(); |
63 | } | 63 | } |
64 | 64 | ||
65 | async setEnabled(enabled: boolean) { | 65 | async setEnabled(enabled: boolean) { |