Commit 15966de7 authored by Ilya.Kirillov's avatar Ilya.Kirillov Committed by Alexander.Trofimov

Исправлены баги при копировании диаграмм (баг 24615).

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@56582 954022d7-b5bf-4e40-9824-e11837661b57
parent fec05ac8
......@@ -1748,6 +1748,20 @@ CPlotArea.prototype =
c.addAxis(this.axId[i].createDuplicate());
}
//TODO: разобраться с осями в дочерних объектах
if ( this.valAx )
c.valAx = this.valAx.createDuplicate();
if ( this.catAx )
c.catAx = this.catAx.createDuplicate();
if ( this.dateAx )
c.dateAx = this.dateAx.createDuplicate();
if ( this.chart )
c.chart = this.chart.createDuplicate();
return c;
},
Write_ToBinary2: function(w)
......@@ -11576,7 +11590,7 @@ CLineChart.prototype =
return historyitem_type_LineChart;
},
craeteDuplicate: function()
createDuplicate: function()
{
var c = new CLineChart();
if(this.dLbls)
......@@ -12717,7 +12731,7 @@ CMinusPlus.prototype =
}
if(this.numLit)
{
c.setNumLit(this.numLit.craeteDuplicate());
c.setNumLit(this.numLit.createDuplicate());
}
return c;
},
......@@ -13115,6 +13129,7 @@ CNumRef.prototype =
{
c.setNumCache(this.numCache.createDuplicate());
}
return c;
},
getObjectType: function()
......@@ -15133,7 +15148,7 @@ CPivotFmt.prototype =
}
if(this.txPr)
{
c.setTxPr(this.txPr.craeteDuplicate());
c.setTxPr(this.txPr.createDuplicate());
}
return c;
},
......@@ -15379,7 +15394,7 @@ CRadarChart.prototype =
var c = new CRadarChart();
if(this.dLbls)
{
c.setDLbls(this.dLbls.craeteDuplicate());
c.setDLbls(this.dLbls.createDuplicate());
}
c.setRadarStyle(this.radarStyle);
for(var i = 0; i < this.series.length; ++i)
......@@ -15694,7 +15709,7 @@ CRadarSeries.prototype =
}
if(this.dLbls)
{
c.setDLbls(this.dLbls.craeteDuplicate());
c.setDLbls(this.dLbls.createDuplicate());
}
for(var i = 0; i < this.dPt.length; ++i)
{
......@@ -16615,7 +16630,7 @@ CScatterSeries.prototype =
c.setSmooth(this.smooth);
if(this.spPr)
{
c.setSpPr(this.spPr.craeteDuplicate());
c.setSpPr(this.spPr.createDuplicate());
}
if(this.trendline)
{
......@@ -18104,7 +18119,7 @@ CSurfaceChart.prototype =
var c = new CSurfaceChart(), i;
for(i = 0; i < this.bandFmts.length; ++i)
{
c.addBandFmt(this.bandFmts[i].craeteDuplicate());
c.addBandFmt(this.bandFmts[i].createDuplicate());
}
for(i =0 ; i < this.series.length; ++i)
{
......@@ -18726,7 +18741,7 @@ CTitle.prototype =
}
if(this.tx)
{
c.setTx(this.tx.craeteDuplicate());
c.setTx(this.tx.createDuplicate());
}
if(this.txPr)
{
......@@ -19813,6 +19828,8 @@ CYVal.prototype =
{
copy.setNumRef(this.numRef.createDuplicate());
}
return copy;
},
getObjectType: function()
......@@ -19960,7 +19977,36 @@ CChart.prototype =
createDuplicate: function()
{
// TODO: Проверить данную функцию
var c = new CChart();
c.autoTitleDeleted = this.autoTitleDeleted;
c.backWall = this.backWall;
c.dispBlanksAs = this.dispBlanksAs;
c.floor = this.floor;
if ( this.legend )
c.legend = this.legend.createDuplicate();
var Count = this.pivotFmts;
for ( var i = 0; i < this.pivotFmts; i++ )
c.pivotFmts[i] = this.pivotFmts[i];
if ( this.plotArea )
c.plotArea = this.plotArea.createDuplicate();
c.plotVisOnly = this.plotVisOnly;
c.showDLblsOverMax = this.showDLblsOverMax;
c.sideWall = this.sideWall;
if ( this.title )
c.title = this.title.createDuplicate();
if ( this.view3D )
c.view3D = this.view3D.createDuplicate();
return c;
},
Write_ToBinary2: function(w)
......
......@@ -7983,6 +7983,21 @@ CPrintSettings.prototype =
return this.Id;
},
createDuplicate : function()
{
var oPS = new CPrintSettings();
if ( this.headerFooter )
oPS.headerFooter = this.headerFooter.createDuplicate();
if ( this.pageMargins )
oPS.pageMargins = this.pageMargins.createDuplicate();
if ( this.pageSetup )
oPS.pageSetup = this.pageSetup.createDuplicate();
return oPS;
},
Refresh_RecalcData: function()
{},
......@@ -8126,6 +8141,36 @@ CHeaderFooterChart.prototype =
return this.Id;
},
createDuplicate : function()
{
// TODO: Проверить работу данной функции
var oHFC = new CHeaderFooterChart();
oHFC.alignWithMargins = this.alignWithMargins;
oHFC.differentFirst = this.differentFirst;
oHFC.differentOddEven = this.differentOddEven;
if ( this.evenFooter )
oHFC.evenFooter = this.evenFooter.createDuplicate();
if ( this.evenHeader )
oHFC.evenHeader = this.evenHeader.createDuplicate();
if ( this.firstFooter )
oHFC.firstFooter = this.firstFooter.createDuplicate();
if ( this.firstHeader )
oHFC.firstHeader = this.firstHeader.createDuplicate();
if ( this.oddFooter )
oHFC.oddFooter = this.oddFooter.createDuplicate();
if ( this.oddHeader )
oHFC.oddHeader = this.oddHeader.createDuplicate();
return oHFC;
},
Refresh_RecalcData: function()
{},
......@@ -8396,6 +8441,19 @@ CPageMarginsChart.prototype =
return this.Id;
},
createDuplicate : function()
{
var oPMC = new CPageMarginsChart();
oPMC.b = this.b;
oPMC.footer = this.footer;
oPMC.header = this.header;
oPMC.l = this.l;
oPMC.r = this.r;
oPMC.t = this.t;
return oPMC;
},
Refresh_RecalcData: function()
{},
......@@ -8606,6 +8664,25 @@ CPageSetup.prototype =
{
return this.Id;
},
createDuplicate : function()
{
var oPS = new CPageSetup();
oPS.blackAndWhite = this.blackAndWhite;
oPS.copies = this.copies;
oPS.draft = this.draft;
oPS.firstPageNumber = this.firstPageNumber;
oPS.horizontalDpi = this.horizontalDpi;
oPS.orientation = this.orientation;
oPS.paperHeight = this.paperHeight;
oPS.paperSize = this.paperSize;
oPS.paperWidth = this.paperWidth;
oPS.useFirstPageNumb = this.useFirstPageNumb;
oPS.verticalDpi = this.verticalDpi;
return oPS;
},
Refresh_RecalcData: 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