diff options
author | Aleksey Kladov <[email protected]> | 2019-12-31 16:28:01 +0000 |
---|---|---|
committer | Aleksey Kladov <[email protected]> | 2019-12-31 16:28:01 +0000 |
commit | 433000be34eafd052addd91afd605a81e137a433 (patch) | |
tree | 95d30e894b6583f2d743fc94e3e866bc29750362 /editors/code/src/ctx.ts | |
parent | e4b588868f822b9c200a8ce77d24bfab5aeca4b8 (diff) |
Move config to Ctx
Diffstat (limited to 'editors/code/src/ctx.ts')
-rw-r--r-- | editors/code/src/ctx.ts | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/editors/code/src/ctx.ts b/editors/code/src/ctx.ts index 0e62a3a85..d86fe5a87 100644 --- a/editors/code/src/ctx.ts +++ b/editors/code/src/ctx.ts | |||
@@ -4,6 +4,7 @@ import { Server } from './server'; | |||
4 | import { Config } from './config'; | 4 | import { Config } from './config'; |
5 | 5 | ||
6 | export class Ctx { | 6 | export class Ctx { |
7 | readonly config = new Config(); | ||
7 | private extCtx: vscode.ExtensionContext; | 8 | private extCtx: vscode.ExtensionContext; |
8 | 9 | ||
9 | constructor(extCtx: vscode.ExtensionContext) { | 10 | constructor(extCtx: vscode.ExtensionContext) { |
@@ -14,10 +15,6 @@ export class Ctx { | |||
14 | return Server.client; | 15 | return Server.client; |
15 | } | 16 | } |
16 | 17 | ||
17 | get config(): Config { | ||
18 | return Server.config; | ||
19 | } | ||
20 | |||
21 | get activeRustEditor(): vscode.TextEditor | undefined { | 18 | get activeRustEditor(): vscode.TextEditor | undefined { |
22 | const editor = vscode.window.activeTextEditor; | 19 | const editor = vscode.window.activeTextEditor; |
23 | return editor && editor.document.languageId === 'rust' | 20 | return editor && editor.document.languageId === 'rust' |