diff options
author | Veetaha <[email protected]> | 2020-02-14 21:04:50 +0000 |
---|---|---|
committer | Veetaha <[email protected]> | 2020-02-14 21:04:50 +0000 |
commit | 4fb427743c27c63a4aa3ccd54c488b22d4308bc2 (patch) | |
tree | 45dfb0fca0912d45e83fd33b1eb065898febec2a /editors/code/src/highlighting.ts | |
parent | fd37151ade9948398e863c38418fb4f0d0acdfa7 (diff) |
vscode: moved to getters as per matklad
Diffstat (limited to 'editors/code/src/highlighting.ts')
-rw-r--r-- | editors/code/src/highlighting.ts | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/editors/code/src/highlighting.ts b/editors/code/src/highlighting.ts index e2ae31d29..4fbbe3ddc 100644 --- a/editors/code/src/highlighting.ts +++ b/editors/code/src/highlighting.ts | |||
@@ -11,7 +11,7 @@ export function activateHighlighting(ctx: Ctx) { | |||
11 | client.onNotification( | 11 | client.onNotification( |
12 | 'rust-analyzer/publishDecorations', | 12 | 'rust-analyzer/publishDecorations', |
13 | (params: PublishDecorationsParams) => { | 13 | (params: PublishDecorationsParams) => { |
14 | if (!ctx.config.highlightingOn()) return; | 14 | if (!ctx.config.highlightingOn) return; |
15 | 15 | ||
16 | const targetEditor = vscode.window.visibleTextEditors.find( | 16 | const targetEditor = vscode.window.visibleTextEditors.find( |
17 | editor => { | 17 | editor => { |
@@ -39,7 +39,7 @@ export function activateHighlighting(ctx: Ctx) { | |||
39 | vscode.window.onDidChangeActiveTextEditor( | 39 | vscode.window.onDidChangeActiveTextEditor( |
40 | async (editor: vscode.TextEditor | undefined) => { | 40 | async (editor: vscode.TextEditor | undefined) => { |
41 | if (!editor || editor.document.languageId !== 'rust') return; | 41 | if (!editor || editor.document.languageId !== 'rust') return; |
42 | if (!ctx.config.highlightingOn()) return; | 42 | if (!ctx.config.highlightingOn) return; |
43 | const client = ctx.client; | 43 | const client = ctx.client; |
44 | if (!client) return; | 44 | if (!client) return; |
45 | 45 | ||
@@ -122,7 +122,7 @@ class Highlighter { | |||
122 | string, | 122 | string, |
123 | [vscode.Range[], boolean] | 123 | [vscode.Range[], boolean] |
124 | > = new Map(); | 124 | > = new Map(); |
125 | const rainbowTime = this.ctx.config.rainbowHighlightingOn(); | 125 | const rainbowTime = this.ctx.config.rainbowHighlightingOn; |
126 | 126 | ||
127 | for (const tag of this.decorations.keys()) { | 127 | for (const tag of this.decorations.keys()) { |
128 | byTag.set(tag, []); | 128 | byTag.set(tag, []); |