From 6e56202803caa38b500477466d2cf2bd0804bcbd Mon Sep 17 00:00:00 2001 From: rebornix Date: Wed, 20 Jan 2021 17:49:33 -0800 Subject: [PATCH] pin notebook editor when execution triggered. --- .../workbench/contrib/notebook/browser/contrib/coreActions.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/contrib/notebook/browser/contrib/coreActions.ts b/src/vs/workbench/contrib/notebook/browser/contrib/coreActions.ts index a67958bbbf0..eb4fbb7260f 100644 --- a/src/vs/workbench/contrib/notebook/browser/contrib/coreActions.ts +++ b/src/vs/workbench/contrib/notebook/browser/contrib/coreActions.ts @@ -553,7 +553,7 @@ registerAction2(class extends NotebookAction { const editorService = accessor.get(IEditorService); const editor = editorService.getEditors(EditorsOrder.MOST_RECENTLY_ACTIVE).find( - editor => editor instanceof NotebookEditorInput && editor.viewType === context.notebookEditor.viewModel.viewType && editor.resource.toString() === context.notebookEditor.viewModel.uri.toString()); + editor => editor.editor instanceof NotebookEditorInput && editor.editor.viewType === context.notebookEditor.viewModel.viewType && editor.editor.resource.toString() === context.notebookEditor.viewModel.uri.toString()); const editorGroupService = accessor.get(IEditorGroupsService); if (editor) {