Commit 9fb2e43c authored by SergeyLuzyanin's avatar SergeyLuzyanin

notes copy/paste

parent c148f0fe
......@@ -1435,6 +1435,11 @@ CopyProcessor.prototype =
//записываем slide
this.oPresentationWriter.WriteSlide(slide);
var oNotes = slide.notes;
this.oPresentationWriter.WriteBool(AscCommon.isRealObject(oNotes));
if(AscCommon.isRealObject(oNotes)){
this.oPresentationWriter.WriteSlideNote(oNotes);
}
//записываем sp_tree параметры
this.oPresentationWriter.WriteULong(sp_tree.length);
......@@ -3901,6 +3906,11 @@ PasteProcessor.prototype =
table_styles_ids.push(-1);
}
arr_slides[i] = loader.ReadSlide(0);
if(stream.GetBool()){
var oNotes = loader.ReadNote();
oNotes.setNotesMaster(loader.presentation.notesMasters[0]);
arr_slides[i].setNotes(oNotes);
}
var sp_tree = arr_slides[i].cSld.spTree;
var t = 0;
for(var s = 0; s < sp_tree.length; ++s)
......
......@@ -56,6 +56,8 @@
this.Master = null;
this.m_oContentChanges = new AscCommon.CContentChanges(); // список изменений(добавление/удаление элементов)
this.kind = AscFormat.TYPE_KIND.NOTES;
this.Id = AscCommon.g_oIdCounter.Get_NewId();
AscCommon.g_oTableId.Add(this, this.Id);
......@@ -64,6 +66,23 @@
this.graphicObjects = new AscFormat.DrawingObjectsController(this);
}
CNotes.prototype.Clear_ContentChanges = function()
{
this.m_oContentChanges.Clear();
};
CNotes.prototype.Add_ContentChanges = function(Changes)
{
this.m_oContentChanges.Add( Changes );
};
CNotes.prototype.Refresh_ContentChanges = function()
{
this.m_oContentChanges.Refresh();
};
CNotes.prototype.getObjectType = function(){
return AscDFH.historyitem_type_Notes;
};
......
......@@ -57,11 +57,17 @@
}
CNotesMaster.prototype.getObjectType = function(){
return AscDFH.historyitem_type_NotesMaster;
};
CNotesMaster.prototype.Get_Id = function(){
return this.Id;
};
CNotesMaster.prototype.Write_ToBinary2 = function(w){
w.WriteLong(this.getObjectType());
w.WriteString2(this.Id);
......
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