Commit 386ff879 authored by Sergey.Luzyanin's avatar Sergey.Luzyanin Committed by Alexander.Trofimov

перенес c_oAscTypeSelectElement из apiDefines.js всех редакторов в commonDefines.js

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@49757 954022d7-b5bf-4e40-9824-e11837661b57
parent 9ab4b748
......@@ -96,3 +96,16 @@ var c_oAscLineDrawingRule = {
Top : 0,
Bottom : 2
};
var c_oAscTypeSelectElement = {
Paragraph : 0,
Table : 1,
Image : 2,
Header : 3,
Hyperlink : 4,
SpellCheck : 5,
Shape:6,
Slide:7,
Chart: 8
};
\ No newline at end of file
......@@ -381,16 +381,6 @@ var c_oAscLineBeginSize = {
large_large : 8
};
var c_oAscTypeSelectElement = {
Paragraph : 0,
Table : 1,
Image : 2,
Header : 3,
Hyperlink : 4,
SpellCheck : 5,
Shape:6,
Slide:7
};
var c_oAscFillGradType = {
GRAD_LINEAR : 1,
......
......@@ -903,6 +903,13 @@ function Slide(presentation, slideLayout, slideNum)
Slide.prototype =
{
applyTiming: function(timing)
{
var oldTiming = this.timing.createDuplicate();
this.timing.applyProps(oTiming);
History.Add(this, {Type: historyitem_ChangeTiming, oldTiming: oldTiming, newTiming: this.timing.createDuplicate()});
},
changeBackground: function(bg)
{
......@@ -1396,6 +1403,11 @@ Slide.prototype =
break;
}
case historyitem_ChangeTiming:
{
this.timing = data.oldTiming.createDuplicate();
break;
}
}
},
......@@ -1430,6 +1442,11 @@ Slide.prototype =
break;
}
case historyitem_ChangeTiming:
{
this.timing = data.newTiming.createDuplicate();
break;
}
}
},
......@@ -1464,6 +1481,12 @@ Slide.prototype =
w.WriteString2(data.layoutLock);
break;
}
case historyitem_ChangeTiming:
{
data.newTiming.Write_ToBinary2(w);
break;
}
}
},
......@@ -1493,6 +1516,12 @@ Slide.prototype =
this.layoutLock = g_oTableId.Get_ById(r.GetString2());
break;
}
case historyitem_ChangeTiming:
{
this.timing = new CAscSlideTiming();
this.timing.Read_FromBinary2(r);
break;
}
}
}
};
......
......@@ -1126,6 +1126,12 @@ CGraphicObjects.prototype = {
}
var ret = new CChartAsGroup();
var options = {};
options.slide = this.slide;
options.layout = this.slide.Layout;
options.master = this.slide.Layout.Master;
options.theme = this.slide.Layout.Master.Theme;
editor.chartStyleManager.init(options);
ret.chart.initDefault();
ret.spPr.xfrm.offX = 0;
ret.spPr.xfrm.offY = 0;
......
......@@ -211,6 +211,8 @@ var historyitem_RemoveFromSpTree = 0;
var historyitem_AddToSlideSpTree = 1;
var historyitem_AddSlideLocks = 2;
var historyitem_ChangeBg = 3;
var historyitem_ChangeTiming = 4;
......
......@@ -172,6 +172,59 @@ CAscSlideTiming.prototype.setDefaultParams = function()
this.SlideAdvanceDuration = 10000;
}
CAscSlideTiming.prototype.Write_ToBinary2 = function(w)
{
w.WriteBool(isRealNumber(this.TransitionType));
if(isRealNumber(this.TransitionType))
w.WriteLong(this.TransitionType);
w.WriteBool(isRealNumber(this.TransitionOption));
if(isRealNumber(this.TransitionOption))
w.WriteLong(this.TransitionOption);
w.WriteBool(isRealNumber(this.TransitionDuration));
if(isRealNumber(this.TransitionDuration))
w.WriteLong(this.TransitionDuration);
w.WriteBool(isRealBool(this.SlideAdvanceOnMouseClick));
if(isRealBool(this.SlideAdvanceOnMouseClick))
w.WriteBool(this.SlideAdvanceOnMouseClick);
w.WriteBool(isRealBool(this.SlideAdvanceAfter));
if(isRealBool(this.SlideAdvanceAfter))
w.WriteBool(this.SlideAdvanceAfter);
w.WriteBool(isRealNumber(this.SlideAdvanceDuration));
if(isRealNumber(this.SlideAdvanceDuration))
w.WriteLong(this.SlideAdvanceDuration);
};
CAscSlideTiming.prototype.Read_FromBinary2 = function(r)
{
if(r.GetBool())
this.TransitionType = r.GetLong();
if(r.GetBool())
this.TransitionOption = r.GetLong();
if(r.GetBool())
this.TransitionDuration = r.GetLong();
if(r.GetBool())
this.SlideAdvanceOnMouseClick = r.GetBool();
if(r.GetBool())
this.SlideAdvanceAfter = r.GetBool();
if(r.GetBool())
this.SlideAdvanceDuration = r.GetLong();
};
// ---------------------------------------------------------------
function CAscTexture()
......
......@@ -120,16 +120,6 @@ var c_oAscError = {
UserCountExceed: -22
}
};
var c_oAscTypeSelectElement = {
Paragraph : 0,
Table : 1,
Image : 2,
Header : 3,
Hyperlink : 4,
SpellCheck : 5,
Shape:6,
Slide:7
};
var c_oAscContextMenuTypes = {
Main : 0,
......
......@@ -102,14 +102,6 @@ var c_oAscError = {
}
};
var c_oAscTypeSelectElement = {
Paragraph : 0,
Table : 1,
Image : 2,
Header : 3,
Hyperlink : 4,
SpellCheck : 5
};
var c_oAscTableBordersType = {
LEFT:0,
......
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