Commit b363ddf0 authored by Alexander.Trofimov's avatar Alexander.Trofimov

delete global CDocsCoApi -> Asc.CDocsCoApi

delete global CSpellCheckApi -> Asc.CSpellCheckApi
parent fe3cae06
...@@ -191,11 +191,11 @@ function DesktopOfflineUpdateLocalName(_api) ...@@ -191,11 +191,11 @@ function DesktopOfflineUpdateLocalName(_api)
window["AscDesktopEditor"]["SetDocumentName"](_name); window["AscDesktopEditor"]["SetDocumentName"](_name);
} }
window["CDocsCoApi"].prototype.askSaveChanges = function(callback) Asc.CDocsCoApi.prototype.askSaveChanges = function(callback)
{ {
callback({"saveLock": false}); callback({"saveLock": false});
}; };
window["CDocsCoApi"].prototype.saveChanges = function(arrayChanges, deleteIndex, excelAdditionalInfo) Asc.CDocsCoApi.prototype.saveChanges = function(arrayChanges, deleteIndex, excelAdditionalInfo)
{ {
window["AscDesktopEditor"]["LocalFileSaveChanges"](arrayChanges.join("\",\""), deleteIndex, arrayChanges.length); window["AscDesktopEditor"]["LocalFileSaveChanges"](arrayChanges.join("\",\""), deleteIndex, arrayChanges.length);
//this.onUnSaveLock(); //this.onUnSaveLock();
......
...@@ -89,7 +89,7 @@ function baseEditorsApi(name) { ...@@ -89,7 +89,7 @@ function baseEditorsApi(name) {
// CoAuthoring and Chat // CoAuthoring and Chat
this.User = undefined; this.User = undefined;
this.CoAuthoringApi = new window['CDocsCoApi'](); this.CoAuthoringApi = new Asc.CDocsCoApi();
this.isCoAuthoringEnable = true; this.isCoAuthoringEnable = true;
// Массив lock-ов, которые были на открытии документа // Массив lock-ов, которые были на открытии документа
this.arrPreOpenLocksObjects = []; this.arrPreOpenLocksObjects = [];
......
...@@ -1324,5 +1324,5 @@ ...@@ -1324,5 +1324,5 @@
return window['SockJS'] ? window['SockJS'] : require('sockjs'); return window['SockJS'] ? window['SockJS'] : require('sockjs');
}; };
window["CDocsCoApi"] = CDocsCoApi; asc.CDocsCoApi = CDocsCoApi;
})(window); })(window);
\ No newline at end of file
...@@ -24,9 +24,11 @@ ...@@ -24,9 +24,11 @@
*/ */
"use strict"; "use strict";
(function(global) { (function(window) {
'use strict'; 'use strict';
var asc = window["Asc"];
// Класс надстройка, для online и offline работы // Класс надстройка, для online и offline работы
var CSpellCheckApi = function(options) { var CSpellCheckApi = function(options) {
this._SpellCheckApi = new SpellCheckApi(); this._SpellCheckApi = new SpellCheckApi();
...@@ -235,7 +237,7 @@ ...@@ -235,7 +237,7 @@
this.sockjs_url = this._url + '/doc/' + docid + '/c'; this.sockjs_url = this._url + '/doc/' + docid + '/c';
this.sockjs = initSocksJs(this.sockjs_url, this); this.sockjs = initSocksJs(this.sockjs_url, this);
}; };
global["CSpellCheckApi"] = CSpellCheckApi;
asc.CSpellCheckApi = CSpellCheckApi;
})(window); })(window);
...@@ -40,8 +40,6 @@ function asc_docs_api(name) ...@@ -40,8 +40,6 @@ function asc_docs_api(name)
asc_docs_api.superclass.constructor.call(this, name); asc_docs_api.superclass.constructor.call(this, name);
this.editorId = c_oEditorId.Presentation; this.editorId = c_oEditorId.Presentation;
var CSpellCheckApi = window["CSpellCheckApi"];
History = new CHistory(); History = new CHistory();
g_oTableId = new CTableId(); g_oTableId = new CTableId();
......
...@@ -291,8 +291,6 @@ function asc_docs_api(name) ...@@ -291,8 +291,6 @@ function asc_docs_api(name)
window["AscDesktopEditor"]["CreateEditorApi"](); window["AscDesktopEditor"]["CreateEditorApi"]();
} }
var CSpellCheckApi = window["CSpellCheckApi"];
History = new CHistory(); History = new CHistory();
g_oTableId = new CTableId(); g_oTableId = new CTableId();
...@@ -329,7 +327,7 @@ function asc_docs_api(name) ...@@ -329,7 +327,7 @@ function asc_docs_api(name)
this.isCoMarksDraw = false; this.isCoMarksDraw = false;
// Spell Checking // Spell Checking
this.SpellCheckApi = (window["AscDesktopEditor"] === undefined) ? new CSpellCheckApi() : new CSpellCheckApi_desktop(); this.SpellCheckApi = (window["AscDesktopEditor"] === undefined) ? new Asc.CSpellCheckApi() : new CSpellCheckApi_desktop();
this.isSpellCheckEnable = true; this.isSpellCheckEnable = true;
// это чтобы сразу показать ридер, без возможности вернуться в редактор/вьюер // это чтобы сразу показать ридер, без возможности вернуться в редактор/вьюер
...@@ -7167,11 +7165,11 @@ window["asc_docs_api"].prototype["asc_nativeOpenFile"] = function(base64File, ve ...@@ -7167,11 +7165,11 @@ window["asc_docs_api"].prototype["asc_nativeOpenFile"] = function(base64File, ve
if (window["NATIVE_EDITOR_ENJINE"] === true && undefined != window["native"]) if (window["NATIVE_EDITOR_ENJINE"] === true && undefined != window["native"])
{ {
window["CDocsCoApi"].prototype.askSaveChanges = function(callback) Asc.CDocsCoApi.prototype.askSaveChanges = function(callback)
{ {
callback({"saveLock": false}); callback({"saveLock": false});
}; };
window["CDocsCoApi"].prototype.saveChanges = function(arrayChanges, deleteIndex, excelAdditionalInfo) Asc.CDocsCoApi.prototype.saveChanges = function(arrayChanges, deleteIndex, excelAdditionalInfo)
{ {
if (window["native"]["SaveChanges"]) if (window["native"]["SaveChanges"])
window["native"]["SaveChanges"](arrayChanges.join("\",\""), deleteIndex, arrayChanges.length); window["native"]["SaveChanges"](arrayChanges.join("\",\""), deleteIndex, arrayChanges.length);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment