Commit 2772f50f authored by Alexander.Trofimov's avatar Alexander.Trofimov Committed by Alexander.Trofimov

delete ChartPreviewManager.isReady

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@57049 954022d7-b5bf-4e40-9824-e11837661b57
parent 83561b27
...@@ -5302,7 +5302,7 @@ function DrawingObjects() { ...@@ -5302,7 +5302,7 @@ function DrawingObjects() {
_this.getAscChartObject = function() { _this.getAscChartObject = function() {
// if ( !api.chartStyleManager.isReady() || !api.chartPreviewManager.isReady() ) { // if ( !api.chartStyleManager.isReady()) {
// api.chartStyleManager.init(); // api.chartStyleManager.init();
// api.chartPreviewManager.init(); // api.chartPreviewManager.init();
// _this.callTrigger("asc_onUpdateChartStyles"); // _this.callTrigger("asc_onUpdateChartStyles");
...@@ -5778,7 +5778,7 @@ function ClickCounter() { ...@@ -5778,7 +5778,7 @@ function ClickCounter() {
} }
} }
function CoordsManager(ws, bLog) { function CoordsManager(ws) {
var _t = this; var _t = this;
var worksheet = ws; var worksheet = ws;
......
...@@ -116,7 +116,6 @@ function ChartStyleManager() { ...@@ -116,7 +116,6 @@ function ChartStyleManager() {
function ChartPreviewManager() { function ChartPreviewManager() {
var _this = this; var _this = this;
var bReady = false;
var previewGroups = []; var previewGroups = [];
var chartsByTypes = []; var chartsByTypes = [];
...@@ -444,16 +443,11 @@ function ChartPreviewManager() { ...@@ -444,16 +443,11 @@ function ChartPreviewManager() {
} }
} }
} }
bReady = true;
/** proprietary end **/ /** proprietary end **/
//var endTime = new Date(); //var endTime = new Date();
//console.log( "ChartPreviewManager init: " + (endTime.getTime() - startTime.getTime()) ); //console.log( "ChartPreviewManager init: " + (endTime.getTime() - startTime.getTime()) );
}
_this.isReady = function() {
return true;
}; };
_this.createAscChart = function(type) _this.createAscChart = function(type)
......
...@@ -2545,14 +2545,11 @@ var ASC_DOCS_API_USE_EMBEDDED_FONTS = "@@ASC_DOCS_API_USE_EMBEDDED_FONTS"; ...@@ -2545,14 +2545,11 @@ var ASC_DOCS_API_USE_EMBEDDED_FONTS = "@@ASC_DOCS_API_USE_EMBEDDED_FONTS";
asc_getChartPreviews: function(chartType, chartSubType) { asc_getChartPreviews: function(chartType, chartSubType) {
if ( this.chartPreviewManager.isReady() )
{
if(isRealNumber(REV_TYPE_SUBTYPE_BY_TYPE[chartType])) if(isRealNumber(REV_TYPE_SUBTYPE_BY_TYPE[chartType]))
chartType = REV_TYPE_SUBTYPE_BY_TYPE[chartType]; chartType = REV_TYPE_SUBTYPE_BY_TYPE[chartType];
else if(Array.isArray(REV_TYPE_SUBTYPE_BY_TYPE[chartType]) && isRealNumber(REV_TYPE_SUBTYPE_BY_TYPE[chartType][chartSubType])) else if(Array.isArray(REV_TYPE_SUBTYPE_BY_TYPE[chartType]) && isRealNumber(REV_TYPE_SUBTYPE_BY_TYPE[chartType][chartSubType]))
chartType = REV_TYPE_SUBTYPE_BY_TYPE[chartType][chartSubType]; chartType = REV_TYPE_SUBTYPE_BY_TYPE[chartType][chartSubType];
return this.chartPreviewManager.getChartPreviews(chartType); return this.chartPreviewManager.getChartPreviews(chartType);
}
}, },
asc_checkChartInterval: function(type, interval, isRows) { asc_checkChartInterval: function(type, interval, isRows) {
......
...@@ -672,7 +672,7 @@ asc_docs_api.prototype.sync_BeginCatchSelectedElements = function() ...@@ -672,7 +672,7 @@ asc_docs_api.prototype.sync_BeginCatchSelectedElements = function()
asc_docs_api.prototype.sync_EndCatchSelectedElements = function(options) asc_docs_api.prototype.sync_EndCatchSelectedElements = function(options)
{ {
if ( this.chartStyleManager && this.chartPreviewManager && ( !this.chartStyleManager.isReady() || !this.chartPreviewManager.isReady() )) if ( this.chartStyleManager && this.chartPreviewManager && ( !this.chartStyleManager.isReady() ))
{ {
for ( var i = 0; i < this.SelectedObjectsStack.length; i++ ) for ( var i = 0; i < this.SelectedObjectsStack.length; i++ )
{ {
...@@ -4943,9 +4943,7 @@ asc_docs_api.prototype.asc_editChartDrawingObject = function(chartBinary) ...@@ -4943,9 +4943,7 @@ asc_docs_api.prototype.asc_editChartDrawingObject = function(chartBinary)
asc_docs_api.prototype.asc_getChartPreviews = function(chartType, chartSubType) asc_docs_api.prototype.asc_getChartPreviews = function(chartType, chartSubType)
{ {
if ( this.chartPreviewManager.isReady() ) {
return this.chartPreviewManager.getChartPreviews(chartType, chartSubType); return this.chartPreviewManager.getChartPreviews(chartType, chartSubType);
}
} }
asc_docs_api.prototype.sync_closeChartEditor = function() asc_docs_api.prototype.sync_closeChartEditor = function()
......
...@@ -7632,13 +7632,11 @@ asc_docs_api.prototype.asc_editChartDrawingObject = function(chartBinary) ...@@ -7632,13 +7632,11 @@ asc_docs_api.prototype.asc_editChartDrawingObject = function(chartBinary)
asc_docs_api.prototype.asc_getChartPreviews = function(chartType, chartSubType) asc_docs_api.prototype.asc_getChartPreviews = function(chartType, chartSubType)
{ {
if ( this.chartPreviewManager.isReady() ) {
if(isRealNumber(REV_TYPE_SUBTYPE_BY_TYPE[chartType])) if(isRealNumber(REV_TYPE_SUBTYPE_BY_TYPE[chartType]))
chartType = REV_TYPE_SUBTYPE_BY_TYPE[chartType]; chartType = REV_TYPE_SUBTYPE_BY_TYPE[chartType];
else if(Array.isArray(REV_TYPE_SUBTYPE_BY_TYPE[chartType]) && isRealNumber(REV_TYPE_SUBTYPE_BY_TYPE[chartType][chartSubType])) else if(Array.isArray(REV_TYPE_SUBTYPE_BY_TYPE[chartType]) && isRealNumber(REV_TYPE_SUBTYPE_BY_TYPE[chartType][chartSubType]))
chartType = REV_TYPE_SUBTYPE_BY_TYPE[chartType][chartSubType]; chartType = REV_TYPE_SUBTYPE_BY_TYPE[chartType][chartSubType];
return this.chartPreviewManager.getChartPreviews(chartType, chartSubType); return this.chartPreviewManager.getChartPreviews(chartType, chartSubType);
}
}; };
asc_docs_api.prototype.sync_closeChartEditor = function() asc_docs_api.prototype.sync_closeChartEditor = function()
......
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