From 95fa278f30673db0e464825a8a3c77865fe33f78 Mon Sep 17 00:00:00 2001 From: Lukas Wirth Date: Tue, 14 Feb 2023 14:45:48 +0100 Subject: Don't assume VSCode internal commands in the server --- editors/code/src/commands.ts | 6 ++++++ editors/code/src/main.ts | 1 + 2 files changed, 7 insertions(+) (limited to 'editors/code/src') diff --git a/editors/code/src/commands.ts b/editors/code/src/commands.ts index b5b64e33e07..49a8ca4edba 100644 --- a/editors/code/src/commands.ts +++ b/editors/code/src/commands.ts @@ -87,6 +87,12 @@ export function shuffleCrateGraph(ctx: CtxInit): Cmd { }; } +export function triggerParameterHints(_: CtxInit): Cmd { + return async () => { + await vscode.commands.executeCommand("editor.action.triggerParameterHints"); + }; +} + export function matchingBrace(ctx: CtxInit): Cmd { return async () => { const editor = ctx.activeRustEditor; diff --git a/editors/code/src/main.ts b/editors/code/src/main.ts index dd439317c70..5987368e6e0 100644 --- a/editors/code/src/main.ts +++ b/editors/code/src/main.ts @@ -186,5 +186,6 @@ function createCommands(): Record { resolveCodeAction: { enabled: commands.resolveCodeAction }, runSingle: { enabled: commands.runSingle }, showReferences: { enabled: commands.showReferences }, + triggerParameterHints: { enabled: commands.triggerParameterHints }, }; } -- cgit 1.4.1-3-g733a5