diff options
author | Adolfo OchagavĂa <[email protected]> | 2018-10-08 19:18:55 +0100 |
---|---|---|
committer | Adolfo OchagavĂa <[email protected]> | 2018-10-08 19:18:55 +0100 |
commit | 62b1b05a0d9dd021f98352b6229e48e0d8b94f78 (patch) | |
tree | 92627c1590c7f38b29a6d0d86f1db3d5b7332ad0 /editors/code/src/events | |
parent | 4d62cfccbb8281f33b6f894df07e7316a9d45bfb (diff) |
Fix remaining tslint suggestions
Diffstat (limited to 'editors/code/src/events')
-rw-r--r-- | editors/code/src/events/change_active_text_editor.ts | 2 | ||||
-rw-r--r-- | editors/code/src/events/change_text_document.ts | 2 | ||||
-rw-r--r-- | editors/code/src/events/index.ts | 7 |
3 files changed, 9 insertions, 2 deletions
diff --git a/editors/code/src/events/change_active_text_editor.ts b/editors/code/src/events/change_active_text_editor.ts index 96d61126c..3440aa0c3 100644 --- a/editors/code/src/events/change_active_text_editor.ts +++ b/editors/code/src/events/change_active_text_editor.ts | |||
@@ -5,7 +5,7 @@ import { Decoration } from '../highlighting'; | |||
5 | import { Server } from '../server'; | 5 | import { Server } from '../server'; |
6 | 6 | ||
7 | export async function handle(editor: TextEditor | undefined) { | 7 | export async function handle(editor: TextEditor | undefined) { |
8 | if (!Server.config.highlightingOn || !editor || editor.document.languageId != 'rust') { return; } | 8 | if (!Server.config.highlightingOn || !editor || editor.document.languageId !== 'rust') { return; } |
9 | const params: TextDocumentIdentifier = { | 9 | const params: TextDocumentIdentifier = { |
10 | uri: editor.document.uri.toString(), | 10 | uri: editor.document.uri.toString(), |
11 | }; | 11 | }; |
diff --git a/editors/code/src/events/change_text_document.ts b/editors/code/src/events/change_text_document.ts index 192fb1e8a..b3000e026 100644 --- a/editors/code/src/events/change_text_document.ts +++ b/editors/code/src/events/change_text_document.ts | |||
@@ -5,7 +5,7 @@ import { syntaxTreeUri, TextDocumentContentProvider } from '../commands/syntaxTr | |||
5 | export function createHandler(textDocumentContentProvider: TextDocumentContentProvider) { | 5 | export function createHandler(textDocumentContentProvider: TextDocumentContentProvider) { |
6 | return (event: vscode.TextDocumentChangeEvent) => { | 6 | return (event: vscode.TextDocumentChangeEvent) => { |
7 | const doc = event.document; | 7 | const doc = event.document; |
8 | if (doc.languageId != 'rust') { return; } | 8 | if (doc.languageId !== 'rust') { return; } |
9 | afterLs(() => { | 9 | afterLs(() => { |
10 | textDocumentContentProvider.eventEmitter.fire(syntaxTreeUri); | 10 | textDocumentContentProvider.eventEmitter.fire(syntaxTreeUri); |
11 | }); | 11 | }); |
diff --git a/editors/code/src/events/index.ts b/editors/code/src/events/index.ts new file mode 100644 index 000000000..b570a7a92 --- /dev/null +++ b/editors/code/src/events/index.ts | |||
@@ -0,0 +1,7 @@ | |||
1 | import * as changeActiveTextEditor from './change_active_text_editor'; | ||
2 | import * as changeTextDocument from './change_text_document'; | ||
3 | |||
4 | export { | ||
5 | changeActiveTextEditor, | ||
6 | changeTextDocument, | ||
7 | }; | ||