From f00d8903af842c19b09f88db05e76c2ac424078b Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 30 Apr 2020 13:33:38 +0200 Subject: [PATCH] fix #96673 --- .../contrib/notebook/browser/notebookEditorInput.ts | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/vs/workbench/contrib/notebook/browser/notebookEditorInput.ts b/src/vs/workbench/contrib/notebook/browser/notebookEditorInput.ts index 2b3c2c638dd..50747e94bde 100644 --- a/src/vs/workbench/contrib/notebook/browser/notebookEditorInput.ts +++ b/src/vs/workbench/contrib/notebook/browser/notebookEditorInput.ts @@ -157,7 +157,15 @@ export class NotebookEditorInput extends EditorInput { return this.textModel?.isDirty() || false; } + isReadonly() { + return false; + } + public isSaving(): boolean { + if (this.isUntitled()) { + return false; // untitled is never saving automatically + } + if (!this.isDirty()) { return false; // the editor needs to be dirty for being saved }