From 199903a1f717bf3790102407441a2c0d0da2f536 Mon Sep 17 00:00:00 2001 From: Maxim Kadushkin Date: Fri, 29 Apr 2022 14:49:28 +0300 Subject: [PATCH] [all] fix bug 56913, 56914 --- apps/documenteditor/main/app/controller/Main.js | 2 +- apps/presentationeditor/main/app/controller/Main.js | 2 +- apps/spreadsheeteditor/main/app/controller/Main.js | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/apps/documenteditor/main/app/controller/Main.js b/apps/documenteditor/main/app/controller/Main.js index 0d57eb143..06b9d0ad0 100644 --- a/apps/documenteditor/main/app/controller/Main.js +++ b/apps/documenteditor/main/app/controller/Main.js @@ -383,7 +383,7 @@ define([ Common.localStorage.getItem("guest-id") || ('uid-' + Date.now())); this.appOptions.user.anonymous && Common.localStorage.setItem("guest-id", this.appOptions.user.id); - this.appOptions.isDesktopApp = this.editorConfig.targetApp == 'desktop'; + this.appOptions.isDesktopApp = this.editorConfig.targetApp == 'desktop' || Common.Controllers.Desktop.isActive(); this.appOptions.canCreateNew = this.editorConfig.canRequestCreateNew || !_.isEmpty(this.editorConfig.createUrl) || this.editorConfig.templates && this.editorConfig.templates.length; this.appOptions.canOpenRecent = this.editorConfig.recent !== undefined && !this.appOptions.isDesktopApp; this.appOptions.templates = this.editorConfig.templates; diff --git a/apps/presentationeditor/main/app/controller/Main.js b/apps/presentationeditor/main/app/controller/Main.js index bd1bd3e18..6f536652a 100644 --- a/apps/presentationeditor/main/app/controller/Main.js +++ b/apps/presentationeditor/main/app/controller/Main.js @@ -343,7 +343,7 @@ define([ Common.localStorage.getItem("guest-id") || ('uid-' + Date.now())); this.appOptions.user.anonymous && Common.localStorage.setItem("guest-id", this.appOptions.user.id); - this.appOptions.isDesktopApp = this.editorConfig.targetApp == 'desktop'; + this.appOptions.isDesktopApp = this.editorConfig.targetApp == 'desktop' || Common.Controllers.Desktop.isActive(); this.appOptions.canCreateNew = this.editorConfig.canRequestCreateNew || !_.isEmpty(this.editorConfig.createUrl) || this.editorConfig.templates && this.editorConfig.templates.length; this.appOptions.canOpenRecent = this.editorConfig.recent !== undefined && !this.appOptions.isDesktopApp; this.appOptions.templates = this.editorConfig.templates; diff --git a/apps/spreadsheeteditor/main/app/controller/Main.js b/apps/spreadsheeteditor/main/app/controller/Main.js index ccecb0279..2e6d8a99b 100644 --- a/apps/spreadsheeteditor/main/app/controller/Main.js +++ b/apps/spreadsheeteditor/main/app/controller/Main.js @@ -381,7 +381,7 @@ define([ Common.localStorage.getItem("guest-id") || ('uid-' + Date.now())); this.appOptions.user.anonymous && Common.localStorage.setItem("guest-id", this.appOptions.user.id); - this.appOptions.isDesktopApp = this.editorConfig.targetApp == 'desktop'; + this.appOptions.isDesktopApp = this.editorConfig.targetApp == 'desktop' || Common.Controllers.Desktop.isActive(); this.appOptions.canCreateNew = this.editorConfig.canRequestCreateNew || !_.isEmpty(this.editorConfig.createUrl) || this.editorConfig.templates && this.editorConfig.templates.length; this.appOptions.canOpenRecent = this.editorConfig.recent !== undefined && !this.appOptions.isDesktopApp; this.appOptions.templates = this.editorConfig.templates;