about summary refs log tree commit diff
path: root/editors/code
diff options
context:
space:
mode:
authorAleksey Kladov <aleksey.kladov@gmail.com>2021-05-26 13:04:01 +0300
committerAleksey Kladov <aleksey.kladov@gmail.com>2021-05-26 13:04:01 +0300
commit249e22b3250a6e35d53064decb60b67b42a75f42 (patch)
treeefe72acda0021ae816bb0a25e319d755dfcba6e3 /editors/code
parentb7414fa14a85f4acd37b5bdfdc2a4ab97a072bd2 (diff)
downloadrust-249e22b3250a6e35d53064decb60b67b42a75f42.tar.gz
rust-249e22b3250a6e35d53064decb60b67b42a75f42.zip
minor: explicitly set the focus to false
Diffstat (limited to 'editors/code')
-rw-r--r--editors/code/src/run.ts4
1 files changed, 4 insertions, 0 deletions
diff --git a/editors/code/src/run.ts b/editors/code/src/run.ts
index 138e3f6863a..d0be8406869 100644
--- a/editors/code/src/run.ts
+++ b/editors/code/src/run.ts
@@ -142,7 +142,11 @@ export async function createTask(runnable: ra.Runnable, config: Config): Promise
     // eslint-disable-next-line @typescript-eslint/no-unnecessary-type-assertion
     const target = vscode.workspace.workspaceFolders![0]; // safe, see main activate()
     const cargoTask = await tasks.buildCargoTask(target, definition, runnable.label, args, config.cargoRunner, true);
+
     cargoTask.presentationOptions.clear = true;
+    // Sadly, this doesn't prevent focus stealing if the terminal is currently
+    // hidden, and will become revealed due to task exucution.
+    cargoTask.presentationOptions.focus = false;
 
     return cargoTask;
 }