From 81847524702dd7cb1eeae25a53444b325295b129 Mon Sep 17 00:00:00 2001 From: Veetaha Date: Sun, 2 Feb 2020 21:37:22 +0200 Subject: vscode refactoring: use more laconic export snytax, split huge string to several lines --- editors/code/src/main.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'editors/code/src/main.ts') diff --git a/editors/code/src/main.ts b/editors/code/src/main.ts index 0494ccf63..de45f660b 100644 --- a/editors/code/src/main.ts +++ b/editors/code/src/main.ts @@ -11,7 +11,7 @@ let ctx!: Ctx; export async function activate(context: vscode.ExtensionContext) { ctx = new Ctx(context); - // Commands which invokes manually via command pallet, shortcut, etc. + // Commands which invokes manually via command pallete, shortcut, etc. ctx.registerCommand('analyzerStatus', commands.analyzerStatus); ctx.registerCommand('collectGarbage', commands.collectGarbage); ctx.registerCommand('matchingBrace', commands.matchingBrace); -- cgit v1.2.3 From 4bf5f595604c2c3fa0ca981a843d04a8732dabf9 Mon Sep 17 00:00:00 2001 From: Veetaha Date: Sun, 2 Feb 2020 21:38:49 +0200 Subject: vscode: fix type --- editors/code/src/main.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'editors/code/src/main.ts') diff --git a/editors/code/src/main.ts b/editors/code/src/main.ts index de45f660b..6813c3c4c 100644 --- a/editors/code/src/main.ts +++ b/editors/code/src/main.ts @@ -11,7 +11,7 @@ let ctx!: Ctx; export async function activate(context: vscode.ExtensionContext) { ctx = new Ctx(context); - // Commands which invokes manually via command pallete, shortcut, etc. + // Commands which invokes manually via command palette, shortcut, etc. ctx.registerCommand('analyzerStatus', commands.analyzerStatus); ctx.registerCommand('collectGarbage', commands.collectGarbage); ctx.registerCommand('matchingBrace', commands.matchingBrace); -- cgit v1.2.3 From 23ef22dd4880606c4c3dc908d30c2cbeabc37f58 Mon Sep 17 00:00:00 2001 From: Gregoire Geis Date: Sun, 2 Feb 2020 02:21:04 +0100 Subject: Add regular onEnter command, allowing onEnter to be called without overriding the type command. --- editors/code/src/main.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'editors/code/src/main.ts') diff --git a/editors/code/src/main.ts b/editors/code/src/main.ts index 6813c3c4c..5c061e72f 100644 --- a/editors/code/src/main.ts +++ b/editors/code/src/main.ts @@ -21,6 +21,7 @@ export async function activate(context: vscode.ExtensionContext) { ctx.registerCommand('expandMacro', commands.expandMacro); ctx.registerCommand('run', commands.run); ctx.registerCommand('reload', commands.reload); + ctx.registerCommand('onEnter', commands.onEnter); // Internal commands which are invoked by the server. ctx.registerCommand('runSingle', commands.runSingle); @@ -29,7 +30,7 @@ export async function activate(context: vscode.ExtensionContext) { ctx.registerCommand('selectAndApplySourceChange', commands.selectAndApplySourceChange); if (ctx.config.enableEnhancedTyping) { - ctx.overrideCommand('type', commands.onEnter); + ctx.overrideCommand('type', commands.onEnterOverride); } activateStatusDisplay(ctx); -- cgit v1.2.3 From b70ad7e5f3d524204fab88fe2a8c5a6fbef9e88e Mon Sep 17 00:00:00 2001 From: Gregoire Geis Date: Mon, 3 Feb 2020 20:24:50 +0100 Subject: Remove enableEnhancedTyping and type overriding infrastructure. --- editors/code/src/main.ts | 3 --- 1 file changed, 3 deletions(-) (limited to 'editors/code/src/main.ts') diff --git a/editors/code/src/main.ts b/editors/code/src/main.ts index 5c061e72f..efc31b2e2 100644 --- a/editors/code/src/main.ts +++ b/editors/code/src/main.ts @@ -29,9 +29,6 @@ export async function activate(context: vscode.ExtensionContext) { ctx.registerCommand('applySourceChange', commands.applySourceChange); ctx.registerCommand('selectAndApplySourceChange', commands.selectAndApplySourceChange); - if (ctx.config.enableEnhancedTyping) { - ctx.overrideCommand('type', commands.onEnterOverride); - } activateStatusDisplay(ctx); activateHighlighting(ctx); -- cgit v1.2.3 From b89b22e43eb7e821674e0022f4061442b9e29394 Mon Sep 17 00:00:00 2001 From: Veetaha Date: Wed, 5 Feb 2020 00:13:46 +0200 Subject: vscode: yet another refactor commit --- editors/code/src/main.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'editors/code/src/main.ts') diff --git a/editors/code/src/main.ts b/editors/code/src/main.ts index efc31b2e2..5efce41f4 100644 --- a/editors/code/src/main.ts +++ b/editors/code/src/main.ts @@ -6,7 +6,7 @@ import { activateStatusDisplay } from './status_display'; import { Ctx } from './ctx'; import { activateHighlighting } from './highlighting'; -let ctx!: Ctx; +let ctx: Ctx | undefined; export async function activate(context: vscode.ExtensionContext) { ctx = new Ctx(context); -- cgit v1.2.3