Send wopi settings to sdk

This commit is contained in:
Julia Radzhabova
2024-04-26 15:21:16 +03:00
parent 134d96688a
commit c26bb89e70
11 changed files with 12 additions and 1 deletions

View File

@ -141,6 +141,7 @@ DE.ApplicationController = new(function(){
docInfo.put_EncryptedInfo(config.encryptionKeys);
docInfo.put_Lang(config.lang);
docInfo.put_Mode(config.mode);
docInfo.put_Wopi(config.wopi);
var enable = !config.customization || (config.customization.macros!==false);
docInfo.asc_putIsEnabledMacroses(!!enable);

View File

@ -563,6 +563,7 @@ define([
docInfo.put_EncryptedInfo(this.editorConfig.encryptionKeys);
docInfo.put_Lang(this.editorConfig.lang);
docInfo.put_Mode(this.editorConfig.mode);
docInfo.put_Wopi(this.editorConfig.wopi);
var enable = !this.editorConfig.customization || (this.editorConfig.customization.macros!==false);
docInfo.asc_putIsEnabledMacroses(!!enable);

View File

@ -548,6 +548,7 @@ define([
docInfo.put_Lang(this.editorConfig.lang);
docInfo.put_Mode(this.editorConfig.mode);
docInfo.put_SupportsOnSaveDocument(this.editorConfig.canSaveDocumentToBinary);
docInfo.put_Wopi(this.editorConfig.wopi);
var enable = !this.editorConfig.customization || (this.editorConfig.customization.macros!==false);
docInfo.asc_putIsEnabledMacroses(!!enable);

View File

@ -201,6 +201,7 @@ class MainController extends Component {
docInfo.put_EncryptedInfo(this.editorConfig.encryptionKeys);
docInfo.put_Lang(this.editorConfig.lang);
docInfo.put_Mode(this.editorConfig.mode);
docInfo.put_Wopi(this.editorConfig.wopi);
let type = /^(?:(pdf|djvu|xps|oxps))$/.exec(data.doc.fileType);
let coEditMode = (type && typeof type[1] === 'string') ? 'strict' : // offline viewer for pdf|djvu|xps|oxps

View File

@ -472,6 +472,7 @@ define([
docInfo.put_Lang(this.editorConfig.lang);
docInfo.put_Mode(this.editorConfig.mode);
docInfo.put_SupportsOnSaveDocument(this.editorConfig.canSaveDocumentToBinary);
docInfo.put_Wopi(this.editorConfig.wopi);
var enable = !this.editorConfig.customization || (this.editorConfig.customization.macros!==false);
docInfo.asc_putIsEnabledMacroses(!!enable);

View File

@ -138,6 +138,7 @@ PE.ApplicationController = new(function(){
docInfo.put_EncryptedInfo(config.encryptionKeys);
docInfo.put_Lang(config.lang);
docInfo.put_Mode(config.mode);
docInfo.put_Wopi(config.wopi);
var enable = !config.customization || (config.customization.macros!==false);
docInfo.asc_putIsEnabledMacroses(!!enable);

View File

@ -499,6 +499,7 @@ define([
docInfo.put_Lang(this.editorConfig.lang);
docInfo.put_Mode(this.editorConfig.mode);
docInfo.put_SupportsOnSaveDocument(this.editorConfig.canSaveDocumentToBinary);
docInfo.put_Wopi(this.editorConfig.wopi);
var coEditMode = !(this.editorConfig.coEditing && typeof this.editorConfig.coEditing == 'object') ? 'fast' : // fast by default
this.editorConfig.mode === 'view' && this.editorConfig.coEditing.change!==false ? 'fast' : // if can change mode in viewer - set fast for using live viewer

View File

@ -130,6 +130,7 @@ class MainController extends Component {
docInfo.put_EncryptedInfo(this.editorConfig.encryptionKeys);
docInfo.put_Lang(this.editorConfig.lang);
docInfo.put_Mode(this.editorConfig.mode);
docInfo.put_Wopi(this.editorConfig.wopi);
let coEditMode = !(this.editorConfig.coEditing && typeof this.editorConfig.coEditing == 'object') ? 'fast' : // fast by default
this.editorConfig.mode === 'view' && this.editorConfig.coEditing.change!==false ? 'fast' : // if can change mode in viewer - set fast for using live viewer

View File

@ -146,6 +146,7 @@ SSE.ApplicationController = new(function(){
docInfo.put_EncryptedInfo(config.encryptionKeys);
docInfo.put_Lang(config.lang);
docInfo.put_Mode(config.mode);
docInfo.put_Wopi(config.wopi);
var enable = !config.customization || (config.customization.macros!==false);
docInfo.asc_putIsEnabledMacroses(!!enable);

View File

@ -582,6 +582,7 @@ define([
docInfo.put_Mode(this.editorConfig.mode);
docInfo.put_ReferenceData(data.doc.referenceData);
docInfo.put_SupportsOnSaveDocument(this.editorConfig.canSaveDocumentToBinary);
docInfo.put_Wopi(this.editorConfig.wopi);
var coEditMode = !(this.editorConfig.coEditing && typeof this.editorConfig.coEditing == 'object') ? 'fast' : // fast by default
this.editorConfig.mode === 'view' && this.editorConfig.coEditing.change!==false ? 'fast' : // if can change mode in viewer - set fast for using live viewer

View File

@ -174,7 +174,8 @@ class MainController extends Component {
docInfo.put_EncryptedInfo(this.editorConfig.encryptionKeys);
docInfo.put_Lang(this.editorConfig.lang);
docInfo.put_Mode(this.editorConfig.mode);
docInfo.put_Wopi(this.editorConfig.wopi);
let coEditMode = !(this.editorConfig.coEditing && typeof this.editorConfig.coEditing == 'object') ? 'fast' : // fast by default
this.editorConfig.mode === 'view' && this.editorConfig.coEditing.change!==false ? 'fast' : // if can change mode in viewer - set fast for using live viewer
this.editorConfig.coEditing.mode || 'fast';