Skip to content

Commit 29cb7ec

Browse files
committed
setSavePending
1 parent bcb62ec commit 29cb7ec

File tree

1 file changed

+3
-0
lines changed
  • services/static-webserver/client/source/class/osparc/desktop

1 file changed

+3
-0
lines changed

services/static-webserver/client/source/class/osparc/desktop/StudyEditor.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -917,6 +917,7 @@ qx.Class.define("osparc.desktop.StudyEditor", {
917917
console.log("projectDocumentChanged", data);
918918
}
919919

920+
this.getStudy().setSavePending(true);
920921
// throttling: do not update study document right after a change, wait for THROTTLE_PATCH_TIME
921922
const throttlePatchTime = this.self().THROTTLE_PATCH_TIME;
922923
const now = Date.now();
@@ -942,6 +943,7 @@ qx.Class.define("osparc.desktop.StudyEditor", {
942943
});
943944
}
944945

946+
this.getStudy().setSavePending(true);
945947
this.__updatingStudy++;
946948
const studyDiffs = this.__getStudyDiffs();
947949
return this.getStudy().patchStudyDelayed(studyDiffs.delta, studyDiffs.sourceStudy)
@@ -957,6 +959,7 @@ qx.Class.define("osparc.desktop.StudyEditor", {
957959
throw error;
958960
})
959961
.finally(() => {
962+
this.getStudy().setSavePending(false);
960963
this.__updatingStudy--;
961964
if (this.__updateThrottled && this.__updatingStudy === 0) {
962965
this.__updateThrottled = false;

0 commit comments

Comments
 (0)