Commit 41b4a3f2 authored by Sergey Luzyanin's avatar Sergey Luzyanin

fix Bug 34334

parent a1754441
......@@ -7700,7 +7700,6 @@ DrawingObjectsController.prototype =
oSpPr.setFill(AscFormat.CreateNoFillUniFill());
oSpPr.setLn(AscFormat.CreateNoFillLine());
oSpPr.setGeometry(AscFormat.CreateGeometry("rect"));
oSpPr.geometry.setParent(oSpPr);
oShape.setSpPr(oSpPr);
oSpPr.setParent(oShape);
var oContent = oShape.getDocContent();
......
......@@ -5611,7 +5611,6 @@ CSpPr.prototype =
if(this.geometry!=null)
{
duplicate.setGeometry(this.geometry.createDuplicate());
duplicate.geometry.setParent(duplicate);
}
if(this.Fill!=null)
{
......@@ -5714,6 +5713,9 @@ CSpPr.prototype =
{
History.Add(new CChangesDrawingsObject(this, AscDFH.historyitem_SpPr_SetGeometry, this.geometry, pr));
this.geometry = pr;
if(this.geometry){
this.geometry.setParent(this);
}
this.handleUpdateGeometry();
},
......
......@@ -4554,7 +4554,6 @@ CShape.prototype.changePresetGeom = function (sPreset) {
if(sPreset === "textRect")
{
this.spPr.setGeometry(AscFormat.CreateGeometry("rect"));
this.spPr.geometry.setParent(this.spPr);
this.setStyle(AscFormat.CreateDefaultTextRectStyle());
var fill = new AscFormat.CUniFill();
fill.setFill(new AscFormat.CSolidFill());
......@@ -4733,10 +4732,6 @@ CShape.prototype.changePresetGeom = function (sPreset) {
}
if (_final_preset != null) {
this.spPr.setGeometry(AscFormat.CreateGeometry(_final_preset));
if(this.spPr.geometry)
{
this.spPr.geometry.setParent(this.spPr);
}
}
else {
this.spPr.geometry = null;
......
......@@ -498,7 +498,6 @@ function NewShapeTrack(presetGeom, startX, startY, theme, master, layout, slide,
if(this.presetGeom === "textRect")
{
shape.spPr.setGeometry(AscFormat.CreateGeometry("rect"));
shape.spPr.geometry.setParent(shape.spPr);
var fill, ln;
if(!drawingObjects || !drawingObjects.cSld)
{
......@@ -550,7 +549,6 @@ function NewShapeTrack(presetGeom, startX, startY, theme, master, layout, slide,
else
{
shape.spPr.setGeometry(AscFormat.CreateGeometry(this.presetGeom));
shape.spPr.geometry.setParent(shape.spPr);
shape.setStyle(AscFormat.CreateDefaultShapeStyle(this.presetGeom));
if(this.arrowsCount > 0)
{
......
......@@ -4057,8 +4057,6 @@ function BinaryPPTYLoader()
var oGeometry = this.ReadGeometry(spPr.xfrm);
if(oGeometry && oGeometry.pathLst.length > 0)
spPr.setGeometry(oGeometry);
if(spPr.geometry)
spPr.geometry.setParent(spPr);
break;
}
case 2:
......@@ -9249,8 +9247,6 @@ function CPres()
var oGeometry = this.Reader.ReadGeometry(spPr.xfrm);
if(oGeometry && oGeometry.pathLst.length > 0)
spPr.setGeometry(oGeometry);
if(spPr.geometry)
spPr.geometry.setParent(spPr);
break;
}
case 2:
......
......@@ -5017,7 +5017,6 @@
oSpPr.setFill(AscFormat.CreateNoFillUniFill());
oSpPr.setLn(AscFormat.CreateNoFillLine());
oSpPr.setGeometry(AscFormat.CreateGeometry("rect"));
oSpPr.geometry.setParent(oSpPr);
oShape.setSpPr(oSpPr);
oSpPr.setParent(oShape);
var oContent = oShape.getDocContent();
......
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