Commit 37b07bc7 authored by Sergey.Konovalov's avatar Sergey.Konovalov Committed by Alexander.Trofimov

(1.0.0.56): FileConverterUtils2

вместо схемы постоянного опроса реализована схема с event.

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@56308 954022d7-b5bf-4e40-9824-e11837661b57
parent 93e5b083
...@@ -66,7 +66,6 @@ var ASC_DOCS_API_USE_EMBEDDED_FONTS = "@@ASC_DOCS_API_USE_EMBEDDED_FONTS"; ...@@ -66,7 +66,6 @@ var ASC_DOCS_API_USE_EMBEDDED_FONTS = "@@ASC_DOCS_API_USE_EMBEDDED_FONTS";
this.documentFormatSaveCsvDelimiter = c_oAscCsvDelimiter.Comma; this.documentFormatSaveCsvDelimiter = c_oAscCsvDelimiter.Comma;
this.chartEditor = undefined; this.chartEditor = undefined;
this.documentOpenOptions = undefined; // Опции при открытии (пока только опции для CSV) this.documentOpenOptions = undefined; // Опции при открытии (пока только опции для CSV)
this.documentOptions = null;
this.DocInfo = null; this.DocInfo = null;
// объекты, нужные для отправки в тулбар (шрифты, стили) // объекты, нужные для отправки в тулбар (шрифты, стили)
...@@ -431,9 +430,6 @@ var ASC_DOCS_API_USE_EMBEDDED_FONTS = "@@ASC_DOCS_API_USE_EMBEDDED_FONTS"; ...@@ -431,9 +430,6 @@ var ASC_DOCS_API_USE_EMBEDDED_FONTS = "@@ASC_DOCS_API_USE_EMBEDDED_FONTS";
this.documentFormat = this.DocInfo["Format"]; this.documentFormat = this.DocInfo["Format"];
this.documentVKey = this.DocInfo["VKey"]; this.documentVKey = this.DocInfo["VKey"];
this.chartEditor = this.DocInfo["ChartEditor"]; this.chartEditor = this.DocInfo["ChartEditor"];
this.documentOpenOptions = this.DocInfo["Options"];
if(null != this.documentOpenOptions)
this.documentOptions = JSON.stringify(this.documentOpenOptions);
if(this.documentFormat) if(this.documentFormat)
{ {
switch(this.documentFormat) switch(this.documentFormat)
...@@ -751,8 +747,7 @@ var ASC_DOCS_API_USE_EMBEDDED_FONTS = "@@ASC_DOCS_API_USE_EMBEDDED_FONTS"; ...@@ -751,8 +747,7 @@ var ASC_DOCS_API_USE_EMBEDDED_FONTS = "@@ASC_DOCS_API_USE_EMBEDDED_FONTS";
"title": this.documentTitle, "title": this.documentTitle,
"embeddedfonts": this.isUseEmbeddedCutFonts, "embeddedfonts": this.isUseEmbeddedCutFonts,
"delimiter": option.asc_getDelimiter(), "delimiter": option.asc_getDelimiter(),
"codepage": option.asc_getCodePage(), "codepage": option.asc_getCodePage()};
"options": this.documentOptions};
this._asc_sendCommand(function (response) {t._startOpenDocument(response);}, v); this._asc_sendCommand(function (response) {t._startOpenDocument(response);}, v);
} else if (this.advancedOptionsAction === c_oAscAdvancedOptionsAction.Save) } else if (this.advancedOptionsAction === c_oAscAdvancedOptionsAction.Save)
...@@ -1017,8 +1012,7 @@ var ASC_DOCS_API_USE_EMBEDDED_FONTS = "@@ASC_DOCS_API_USE_EMBEDDED_FONTS"; ...@@ -1017,8 +1012,7 @@ var ASC_DOCS_API_USE_EMBEDDED_FONTS = "@@ASC_DOCS_API_USE_EMBEDDED_FONTS";
"editorid" : c_oEditorId.Speadsheet, "editorid" : c_oEditorId.Speadsheet,
"url" : this.documentUrl, "url" : this.documentUrl,
"title" : this.documentTitle, "title" : this.documentTitle,
"embeddedfonts" : this.isUseEmbeddedCutFonts, "embeddedfonts" : this.isUseEmbeddedCutFonts
"options" : this.documentOptions
}; };
if (this.documentOpenOptions && this.documentOpenOptions["isEmpty"]) { if (this.documentOpenOptions && this.documentOpenOptions["isEmpty"]) {
var sEmptyWorkbook = getEmptyWorkbook(); var sEmptyWorkbook = getEmptyWorkbook();
......
...@@ -11,7 +11,6 @@ var documentFormat = 'null'; ...@@ -11,7 +11,6 @@ var documentFormat = 'null';
var documentVKey = null; var documentVKey = null;
var documentOrigin = ""; var documentOrigin = "";
var documentFormatSave = c_oAscFileType.PPTX;//пока не во что другое сохранять не можем. var documentFormatSave = c_oAscFileType.PPTX;//пока не во что другое сохранять не можем.
var documentOptions = null;
var c_oSerFormat = var c_oSerFormat =
{ {
...@@ -817,9 +816,6 @@ asc_docs_api.prototype.LoadDocument = function(c_DocInfo) ...@@ -817,9 +816,6 @@ asc_docs_api.prototype.LoadDocument = function(c_DocInfo)
documentUrl = this.DocInfo.get_Url(); documentUrl = this.DocInfo.get_Url();
documentTitle = this.DocInfo.get_Title(); documentTitle = this.DocInfo.get_Title();
documentFormat = this.DocInfo.get_Format(); documentFormat = this.DocInfo.get_Format();
var options = this.DocInfo.get_Options();
if(null != options)
documentOptions = JSON.stringify(options);
var nIndex = -1; var nIndex = -1;
if(documentTitle) if(documentTitle)
nIndex = documentTitle.lastIndexOf("."); nIndex = documentTitle.lastIndexOf(".");
...@@ -865,8 +861,7 @@ asc_docs_api.prototype.LoadDocument = function(c_DocInfo) ...@@ -865,8 +861,7 @@ asc_docs_api.prototype.LoadDocument = function(c_DocInfo)
"c":"open", "c":"open",
"url": documentUrl, "url": documentUrl,
"title": documentTitle, "title": documentTitle,
"embeddedfonts": this.isUseEmbeddedCutFonts, "embeddedfonts": this.isUseEmbeddedCutFonts};
"options": documentOptions};
sendCommand( oThis, function(){}, rData ); sendCommand( oThis, function(){}, rData );
......
...@@ -13,7 +13,6 @@ var documentVKey = null; ...@@ -13,7 +13,6 @@ var documentVKey = null;
var documentOrigin = ""; var documentOrigin = "";
var documentFormatSave = c_oAscFileType.DOCX; var documentFormatSave = c_oAscFileType.DOCX;
var documentFormatSaveTxtCodepage = 65001;//utf8 var documentFormatSaveTxtCodepage = 65001;//utf8
var documentOptions = null;
function CDocOpenProgress() function CDocOpenProgress()
{ {
...@@ -927,9 +926,6 @@ asc_docs_api.prototype.LoadDocument = function(c_DocInfo) ...@@ -927,9 +926,6 @@ asc_docs_api.prototype.LoadDocument = function(c_DocInfo)
documentUrl = this.DocInfo.get_Url(); documentUrl = this.DocInfo.get_Url();
documentTitle = this.DocInfo.get_Title(); documentTitle = this.DocInfo.get_Title();
documentFormat = this.DocInfo.get_Format(); documentFormat = this.DocInfo.get_Format();
var options = this.DocInfo.get_Options();
if(null != options)
documentOptions = JSON.stringify(options);
if(documentFormat) if(documentFormat)
{ {
switch(documentFormat) switch(documentFormat)
...@@ -996,8 +992,7 @@ asc_docs_api.prototype.LoadDocument = function(c_DocInfo) ...@@ -996,8 +992,7 @@ asc_docs_api.prototype.LoadDocument = function(c_DocInfo)
"url": documentUrl, "url": documentUrl,
"title": documentTitle, "title": documentTitle,
"embeddedfonts": this.isUseEmbeddedCutFonts, "embeddedfonts": this.isUseEmbeddedCutFonts,
"data": g_sEmpty_bin, "data": g_sEmpty_bin};
"options": documentOptions};
sendCommand( oThis, function(){}, rData ); sendCommand( oThis, function(){}, rData );
editor.OpenDocument2(g_sResourceServiceLocalUrl + documentId + "/", g_sEmpty_bin); editor.OpenDocument2(g_sResourceServiceLocalUrl + documentId + "/", g_sEmpty_bin);
...@@ -1020,8 +1015,7 @@ asc_docs_api.prototype.LoadDocument = function(c_DocInfo) ...@@ -1020,8 +1015,7 @@ asc_docs_api.prototype.LoadDocument = function(c_DocInfo)
"c": "open", "c": "open",
"url": documentUrl, "url": documentUrl,
"title": documentTitle, "title": documentTitle,
"embeddedfonts": this.isUseEmbeddedCutFonts, "embeddedfonts": this.isUseEmbeddedCutFonts};
"options": documentOptions};
sendCommand( oThis, function(){}, rData ); sendCommand( oThis, function(){}, rData );
} }
...@@ -7143,8 +7137,7 @@ function sendCommand(editor, fCallback, rdata){ ...@@ -7143,8 +7137,7 @@ function sendCommand(editor, fCallback, rdata){
"url": documentUrl, "url": documentUrl,
"title": documentTitle, "title": documentTitle,
"codepage": documentFormatSaveTxtCodepage, "codepage": documentFormatSaveTxtCodepage,
"embeddedfonts": editor.isUseEmbeddedCutFonts, "embeddedfonts": editor.isUseEmbeddedCutFonts};
"options": documentOptions};
sendCommand(editor, fCallback, rData) sendCommand(editor, fCallback, rData)
break; break;
......
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