aboutsummaryrefslogtreecommitdiff
path: root/editors/code/src/events
diff options
context:
space:
mode:
authorAdolfo OchagavĂ­a <[email protected]>2018-10-08 19:18:55 +0100
committerAdolfo OchagavĂ­a <[email protected]>2018-10-08 19:18:55 +0100
commit62b1b05a0d9dd021f98352b6229e48e0d8b94f78 (patch)
tree92627c1590c7f38b29a6d0d86f1db3d5b7332ad0 /editors/code/src/events
parent4d62cfccbb8281f33b6f894df07e7316a9d45bfb (diff)
Fix remaining tslint suggestions
Diffstat (limited to 'editors/code/src/events')
-rw-r--r--editors/code/src/events/change_active_text_editor.ts2
-rw-r--r--editors/code/src/events/change_text_document.ts2
-rw-r--r--editors/code/src/events/index.ts7
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';
5import { Server } from '../server'; 5import { Server } from '../server';
6 6
7export async function handle(editor: TextEditor | undefined) { 7export 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
5export function createHandler(textDocumentContentProvider: TextDocumentContentProvider) { 5export 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 @@
1import * as changeActiveTextEditor from './change_active_text_editor';
2import * as changeTextDocument from './change_text_document';
3
4export {
5 changeActiveTextEditor,
6 changeTextDocument,
7};