Commit 3cad6ab0 authored by Sergey Luzyanin's avatar Sergey Luzyanin

fix crash, when we insert table from presentation editor into doc or spreadsheet editors

parent 038f33c9
...@@ -1151,7 +1151,7 @@ ...@@ -1151,7 +1151,7 @@
//отдельная обработка для вставки таблички из презентаций //отдельная обработка для вставки таблички из презентаций
if(data.Drawings.length === 1 && typeof CGraphicFrame !== "undefined" && drawingObject.graphicObject instanceof CGraphicFrame) if(data.Drawings.length === 1 && typeof AscFormat.CGraphicFrame !== "undefined" && drawingObject.graphicObject instanceof AscFormat.CGraphicFrame)
{ {
//вставляем табличку из презентаций //вставляем табличку из презентаций
var oPasteFromBinaryWord = new pasteFromBinaryWord(this, ws); var oPasteFromBinaryWord = new pasteFromBinaryWord(this, ws);
......
...@@ -6008,11 +6008,11 @@ function BinaryPPTYLoader() ...@@ -6008,11 +6008,11 @@ function BinaryPPTYLoader()
} }
} }
if(this.presentation && Array.isArray(this.presentation.Slides)){
var bLoadVal = AscCommon.g_oIdCounter.m_bLoad; var bLoadVal = AscCommon.g_oIdCounter.m_bLoad;
var bRead = AscCommon.g_oIdCounter.m_bRead; var bRead = AscCommon.g_oIdCounter.m_bRead;
AscCommon.g_oIdCounter.m_bLoad = false; AscCommon.g_oIdCounter.m_bLoad = false;
AscCommon.g_oIdCounter.m_bRead = false; AscCommon.g_oIdCounter.m_bRead = false;
for(i = 0; i < row.Content.length; ++i){ for(i = 0; i < row.Content.length; ++i){
var oCell = row.Content[i]; var oCell = row.Content[i];
var oMargins = oCell.Get_Margins(); var oMargins = oCell.Get_Margins();
...@@ -6033,23 +6033,7 @@ function BinaryPPTYLoader() ...@@ -6033,23 +6033,7 @@ function BinaryPPTYLoader()
AscCommon.g_oIdCounter.m_bLoad = bLoadVal; AscCommon.g_oIdCounter.m_bLoad = bLoadVal;
AscCommon.g_oIdCounter.m_bRead = bRead; AscCommon.g_oIdCounter.m_bRead = bRead;
row.Set_Height(Math.max(1, fRowHeight - fMaxTopMargin - fMaxBottomMargin - fMaxTopBorder/2 - fMaxBottomBorder/2), Asc.linerule_AtLeast); row.Set_Height(Math.max(1, fRowHeight - fMaxTopMargin - fMaxBottomMargin - fMaxTopBorder/2 - fMaxBottomBorder/2), Asc.linerule_AtLeast);
/*
if (row.Content.length == _count)
{
for (var i = 0; i < _count; i++)
{
s.Skip2(1);
var bIsNoHMerge = this.ReadCell(row.Content[i]);
if (bIsNoHMerge === false)
{
row.Remove_Cell(i);
i--;
_count--;
}
} }
}
*/
s.Seek2(_end_rec); s.Seek2(_end_rec);
} }
......
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