Commit 5bcdaefe authored by Igor.Zotov's avatar Igor.Zotov Committed by Alexander.Trofimov

+ к ревизии 55729

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@55731 954022d7-b5bf-4e40-9824-e11837661b57
parent 59f5ec1f
......@@ -2993,7 +2993,7 @@ PasteProcessor.prototype =
{
var openParams = { checkFileSize: false, charCount: 0, parCount: 0 };
var oBinaryFileReader = new BinaryFileReader(this.oDocument, openParams);
var oRes = oBinaryFileReader.ReadFromString(sBase64);
var oRes = oBinaryFileReader.ReadFromString(sBase64, true);
this.bInBlock = oRes.bInBlock;
return oRes;
},
......
......@@ -5259,7 +5259,7 @@ function BinaryFileReader(doc, openParams)
this.Document.On_EndLoad();
};
this.ReadFromString = function (sBase64) {
this.ReadFromString = function (sBase64, isCopyPaste) {
//надо сбросить то, что остался после открытия документа
window.global_pptx_content_loader.Clear();
window.global_pptx_content_loader.Start_UseFullUrl();
......@@ -5372,6 +5372,20 @@ function BinaryFileReader(doc, openParams)
var aPrepeareImages = [];
for (var i in oPastedImagesUnique)
aPrepeareImages.push(i);
if(!isCopyPaste)
{
this.Document.Content = this.oReadResult.DocumentContent;
if(this.Document.Content.length == 0)
{
var oNewParagraph = new Paragraph(this.Document.DrawingDocument, this.Document, 0, 0, 0, 0, 0 );
this.Document.Content.push(oNewParagraph);
};
this.Document.On_EndLoad();
};
return { content: aContent, fonts: aPrepeareFonts, images: aPrepeareImages, bAddNewStyles: addNewStyles, aPastedImages: aPastedImages, bInBlock: bInBlock };
}
};
......
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