Commit c80dee9f authored by konovalovsergey's avatar konovalovsergey

grpFill open/save

parent 37bcf44e
......@@ -1215,6 +1215,7 @@ window['AscDFH'].historyitem_type_SlideComments = 1119;
window['AscDFH'].historyitem_type_PropLocker = 1120;
window['AscDFH'].historyitem_type_Theme = 1121;
window['AscDFH'].historyitem_type_GraphicFrame = 1122;
window['AscDFH'].historyitem_type_GrpFill = 1123;
......
......@@ -3015,6 +3015,87 @@ CNoFill.prototype =
}
};
function CGrpFill()
{
this.type = c_oAscFill.FILL_TYPE_GRP;
}
CGrpFill.prototype =
{
Get_Id: function()
{
return this.Id;
},
Refresh_RecalcData: function()
{},
check: function()
{},
getObjectType: function()
{
return AscDFH.historyitem_type_GrpFill;
},
Write_ToBinary: function(w)
{
w.WriteLong(c_oAscFill.FILL_TYPE_GRP);
},
Read_FromBinary: function(r)
{
},
checkWordMods: function()
{
return false;
},
convertToPPTXMods: function()
{
},
canConvertPPTXModsToWord: function()
{
return false;
},
convertToWordMods: function()
{
},
createDuplicate : function()
{
return new CGrpFill();
},
IsIdentical : function(fill)
{
if(fill == null)
{
return false;
}
return fill.type === c_oAscFill.FILL_TYPE_GRP;
},
compare : function(grpfill)
{
if(grpfill == null)
{
return null;
}
if(grpfill.type === this.type)
{
return new CGrpFill();
}
return null;
}
};
function CreateBlackRGBUnifill()
{
......@@ -3067,6 +3148,7 @@ CUniFill.prototype =
case c_oAscFill.FILL_TYPE_NONE:
case c_oAscFill.FILL_TYPE_BLIP:
case c_oAscFill.FILL_TYPE_NOFILL:
case c_oAscFill.FILL_TYPE_GRP:
{
break;
}
......@@ -3114,6 +3196,7 @@ CUniFill.prototype =
case c_oAscFill.FILL_TYPE_NONE:
case c_oAscFill.FILL_TYPE_BLIP:
case c_oAscFill.FILL_TYPE_NOFILL:
case c_oAscFill.FILL_TYPE_GRP:
{
break;
}
......@@ -3244,6 +3327,12 @@ CUniFill.prototype =
this.fill.Read_FromBinary(r);
break;
}
case c_oAscFill.FILL_TYPE_GRP:
{
this.fill = new CGrpFill();
this.fill.Read_FromBinary(r);
break;
}
}
}
},
......@@ -11177,6 +11266,11 @@ function CreateAscFill(unifill)
ret.type = c_oAscFill.FILL_TYPE_NOFILL;
break;
}
case c_oAscFill.FILL_TYPE_GRP:
{
ret.type = c_oAscFill.FILL_TYPE_GRP;
break;
}
default:
break;
}
......@@ -11208,6 +11302,11 @@ function CorrectUniFill(asc_fill, unifill, editorId)
ret.fill = new CNoFill();
break;
}
case c_oAscFill.FILL_TYPE_GRP:
{
ret.fill = new CGrpFill();
break;
}
case c_oAscFill.FILL_TYPE_BLIP:
{
......@@ -11833,6 +11932,7 @@ function CorrectUniColor(asc_color, unicolor, flag)
window['AscFormat'].CGradFill = CGradFill;
window['AscFormat'].CPattFill = CPattFill;
window['AscFormat'].CNoFill = CNoFill;
window['AscFormat'].CGrpFill = CGrpFill;
window['AscFormat'].CUniFill = CUniFill;
window['AscFormat'].CompareUniFill = CompareUniFill;
window['AscFormat'].CompareUnifillBool = CompareUnifillBool;
......
......@@ -2536,6 +2536,11 @@ function BinaryPPTYLoader()
uni_fill.setFill(new AscFormat.CNoFill());
break;
}
case c_oAscFill.FILL_TYPE_GRP:
{
uni_fill.setFill(new AscFormat.CGrpFill());
break;
}
}
}
......
......@@ -2215,6 +2215,12 @@ function CBinaryFileWriter()
oThis.EndRecord();
break;
}
case c_oAscFill.FILL_TYPE_GRP:
{
oThis.StartRecord(c_oAscFill.FILL_TYPE_GRP);
oThis.EndRecord();
break;
}
case c_oAscFill.FILL_TYPE_GRAD:
{
oThis.StartRecord(c_oAscFill.FILL_TYPE_GRAD);
......
......@@ -640,8 +640,8 @@ var c_oAscFill = {
FILL_TYPE_NOFILL : 2,
FILL_TYPE_SOLID : 3,
FILL_TYPE_GRAD : 4,
FILL_TYPE_PATT : 5
FILL_TYPE_PATT : 5,
FILL_TYPE_GRP : 6
};
// Chart defines
......@@ -1290,6 +1290,7 @@ var offlineMode = '_offline_';
prot['FILL_TYPE_SOLID'] = prot.FILL_TYPE_SOLID;
prot['FILL_TYPE_GRAD'] = prot.FILL_TYPE_GRAD;
prot['FILL_TYPE_PATT'] = prot.FILL_TYPE_PATT;
prot['FILL_TYPE_GRP'] = prot.FILL_TYPE_GRP;
window['Asc']['c_oAscFillGradType'] = window['Asc'].c_oAscFillGradType = c_oAscFillGradType;
prot = c_oAscFillGradType;
prot['GRAD_LINEAR'] = prot.GRAD_LINEAR;
......
......@@ -540,7 +540,7 @@ function CPPTXContentLoader()
case 1:
{
var spPr = new AscFormat.CSpPr();
this.ReadSpPr(spPr);
this.Reader.ReadGrSpPr(spPr);
shape.setSpPr(spPr);
shape.spPr.setParent(shape);
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