From 053e19554602f046b7ea8e35cb09cb84bd5069f5 Mon Sep 17 00:00:00 2001 From: Julia Radzhabova Date: Fri, 1 Dec 2023 12:28:30 +0300 Subject: [PATCH] Refactoring --- apps/presentationeditor/main/app/controller/Main.js | 4 ++-- apps/spreadsheeteditor/main/app/controller/Main.js | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/apps/presentationeditor/main/app/controller/Main.js b/apps/presentationeditor/main/app/controller/Main.js index 70ae819f5f..b772183222 100644 --- a/apps/presentationeditor/main/app/controller/Main.js +++ b/apps/presentationeditor/main/app/controller/Main.js @@ -2203,7 +2203,7 @@ define([ }, onTryUndoInFastCollaborative: function() { - if (!window.localStorage.getBool("pe-hide-try-undoredo")) + if (!Common.localStorage.getBool("pe-hide-try-undoredo")) Common.UI.info({ width: 500, msg: this.appOptions.canChangeCoAuthoring ? this.textTryUndoRedo : this.textTryUndoRedoWarn, @@ -2212,7 +2212,7 @@ define([ primary: this.appOptions.canChangeCoAuthoring ? 'custom' : 'ok', dontshow: true, callback: _.bind(function(btn, dontshow){ - if (dontshow) window.localStorage.setItem("pe-hide-try-undoredo", 1); + if (dontshow) Common.localStorage.setItem("pe-hide-try-undoredo", 1); if (btn == 'custom') { Common.localStorage.setItem("pe-settings-coauthmode", 0); this.api.asc_SetFastCollaborative(false); diff --git a/apps/spreadsheeteditor/main/app/controller/Main.js b/apps/spreadsheeteditor/main/app/controller/Main.js index 87cf00cce6..6be10be6b7 100644 --- a/apps/spreadsheeteditor/main/app/controller/Main.js +++ b/apps/spreadsheeteditor/main/app/controller/Main.js @@ -2938,7 +2938,7 @@ define([ }, onTryUndoInFastCollaborative: function() { - var val = window.localStorage.getItem("sse-hide-try-undoredo"); + var val = Common.localStorage.getItem("sse-hide-try-undoredo"); if (!(val && parseInt(val) == 1)) Common.UI.info({ width: 500, @@ -2948,7 +2948,7 @@ define([ primary: this.appOptions.canChangeCoAuthoring ? 'custom' : 'ok', dontshow: true, callback: _.bind(function(btn, dontshow){ - if (dontshow) window.localStorage.setItem("sse-hide-try-undoredo", 1); + if (dontshow) Common.localStorage.setItem("sse-hide-try-undoredo", 1); if (btn == 'custom') { Common.localStorage.setItem("sse-settings-coauthmode", 0); this.api.asc_SetFastCollaborative(false);