Commit 16c5aa37 authored by Sergey.Luzyanin's avatar Sergey.Luzyanin Committed by Alexander.Trofimov

Bug 25946 - [CoEdit] Ошибки в консоли при сохранении и select названия...

Bug 25946 - [CoEdit] Ошибки в консоли при сохранении и select названия диаграммы куда были вставленны данные вырезанные у другого пользователя

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@58217 954022d7-b5bf-4e40-9824-e11837661b57
parent f7fc5c1d
...@@ -1085,7 +1085,6 @@ DrawingObjectsController.prototype = ...@@ -1085,7 +1085,6 @@ DrawingObjectsController.prototype =
this.resetSelection(); this.resetSelection();
} }
} }
//this.document.Recalculate();
}, },
paragraphIncDecFontSize: function(bIncrease) paragraphIncDecFontSize: function(bIncrease)
...@@ -4189,42 +4188,46 @@ DrawingObjectsController.prototype = ...@@ -4189,42 +4188,46 @@ DrawingObjectsController.prototype =
{ {
chart_selection.recalcInfo.recalcTitle = null; chart_selection.recalcInfo.recalcTitle = null;
chart_selection.handleUpdateInternalChart(); chart_selection.handleUpdateInternalChart();
chart_selection.addToRecalculate();
if(this.document) if(this.document)
{ {
var para_drawing; chart_selection.recalculate();
if(chart_selection.group) this.document.DrawingDocument.OnRecalculatePage( chart_selection.selectStartPage, this.document.Pages[chart_selection.selectStartPage] );
{ this.document.DrawingDocument.OnEndRecalculate( false, true );
var cur_group = chart_selection.group;
while(cur_group.group) //var para_drawing;
cur_group = cur_group.group; //if(chart_selection.group)
para_drawing = cur_group.parent; //{
} // var cur_group = chart_selection.group;
else // while(cur_group.group)
{ // cur_group = cur_group.group;
para_drawing = chart_selection.parent; // para_drawing = cur_group.parent;
} //}
if(para_drawing && para_drawing.GraphicObj) //else
{ //{
if(para_drawing.Is_Inline()) // para_drawing = chart_selection.parent;
{ //}
para_drawing.OnEnd_ResizeInline(para_drawing.GraphicObj.bounds.w, para_drawing.GraphicObj.bounds.h); //if(para_drawing && para_drawing.GraphicObj)
} //{
else // if(para_drawing.Is_Inline())
{ // {
var pos_x = para_drawing.GraphicObj.bounds.x + para_drawing.GraphicObj.posX; // para_drawing.OnEnd_ResizeInline(para_drawing.GraphicObj.bounds.w, para_drawing.GraphicObj.bounds.h);
var pos_y = para_drawing.GraphicObj.bounds.y + para_drawing.GraphicObj.posY; // }
var nearest_pos = this.document.Get_NearestPos(para_drawing.GraphicObj.selectStartPage, pos_x, pos_y, true, para_drawing); // else
nearest_pos.Paragraph.Check_NearestPos(nearest_pos); // {
para_drawing.Remove_FromDocument(false); // var pos_x = para_drawing.GraphicObj.bounds.x + para_drawing.GraphicObj.posX;
para_drawing.Set_XYForAdd(pos_x, pos_y, nearest_pos, para_drawing.GraphicObj.selectStartPage); // var pos_y = para_drawing.GraphicObj.bounds.y + para_drawing.GraphicObj.posY;
para_drawing.Add_ToDocument2(para_drawing.Get_ParentParagraph()); // var nearest_pos = this.document.Get_NearestPos(para_drawing.GraphicObj.selectStartPage, pos_x, pos_y, true, para_drawing);
} // nearest_pos.Paragraph.Check_NearestPos(nearest_pos);
} // para_drawing.Remove_FromDocument(false);
this.document.Recalculate(); // para_drawing.Set_XYForAdd(pos_x, pos_y, nearest_pos, para_drawing.GraphicObj.selectStartPage);
// para_drawing.Add_ToDocument2(para_drawing.Get_ParentParagraph());
// }
//}
//this.document.Recalculate();
} }
else else
{ {
chart_selection.addToRecalculate();
this.startRecalculate(); this.startRecalculate();
} }
chart_selection.recalcInfo.bRecalculatedTitle = false; chart_selection.recalcInfo.bRecalculatedTitle = false;
......
...@@ -2319,7 +2319,7 @@ function CBinaryFileWriter() ...@@ -2319,7 +2319,7 @@ function CBinaryFileWriter()
{ {
case para_Text: case para_Text:
{ {
_run_text += _elem.Content[j].Value; _run_text += String.fromCharCode(_elem.Content[j].Value);
break; break;
} }
case para_Space : case para_Space :
...@@ -2385,7 +2385,7 @@ function CBinaryFileWriter() ...@@ -2385,7 +2385,7 @@ function CBinaryFileWriter()
{ {
case para_Text: case para_Text:
{ {
_run_text += _elem_h.Content[j].Value; _run_text += String.fromCharCode(_elem_h.Content[j].Value);
break; break;
} }
case para_Space : case para_Space :
......
...@@ -1930,7 +1930,8 @@ CGraphicObjects.prototype = ...@@ -1930,7 +1930,8 @@ CGraphicObjects.prototype =
var content = this.getTargetDocContent(true); var content = this.getTargetDocContent(true);
if(content) if(content)
{ {
content.Remove(Count, bOnlyText, bRemoveOnlySelection, bOnTextAdd) content.Remove(Count, bOnlyText, bRemoveOnlySelection, bOnTextAdd);
this.document.Recalculate();
} }
else if(this.selectedObjects.length > 0) else if(this.selectedObjects.length > 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