Commit 51f9f170 authored by Sergey.Luzyanin's avatar Sergey.Luzyanin Committed by Alexander.Trofimov

Bug 28091 - [CoEdit] Ошибка в консоли при клике в залоченную таблицу в момент...

Bug 28091 - [CoEdit] Ошибка в консоли при клике в залоченную таблицу в момент принятия изменений после удаления ее строк другим пользователем

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@60314 954022d7-b5bf-4e40-9824-e11837661b57
parent fa015c32
...@@ -292,7 +292,7 @@ DrawingObjectsController.prototype = ...@@ -292,7 +292,7 @@ DrawingObjectsController.prototype =
}, },
resetInternalSelection: function() resetInternalSelection: function(noResetContentSelect)
{ {
if(this.selection.groupSelection) if(this.selection.groupSelection)
{ {
...@@ -301,13 +301,26 @@ DrawingObjectsController.prototype = ...@@ -301,13 +301,26 @@ DrawingObjectsController.prototype =
} }
if(this.selection.textSelection) if(this.selection.textSelection)
{ {
// var content = this.selection.textSelection.getDocContent(); if(!(noResetContentSelect === true))
// content && content.Selection_Remove(); {
if(this.selection.textSelection.getObjectType() === historyitem_type_GraphicFrame)
{
if(this.selection.textSelection.graphicObject)
{
this.selection.textSelection.graphicObject.Selection_Remove();
}
}
else
{
var content = this.selection.textSelection.getDocContent();
content && content.Selection_Remove();
}
}
this.selection.textSelection = null; this.selection.textSelection = null;
} }
if(this.selection.chartSelection) if(this.selection.chartSelection)
{ {
this.selection.chartSelection.resetSelection(); this.selection.chartSelection.resetSelection(noResetContentSelect);
this.selection.chartSelection = null; this.selection.chartSelection = null;
} }
if(this.selection.wrapPolygonSelection) if(this.selection.wrapPolygonSelection)
...@@ -513,7 +526,7 @@ DrawingObjectsController.prototype = ...@@ -513,7 +526,7 @@ DrawingObjectsController.prototype =
return this.handleMoveHit(object, e, x, y, group, false, pageIndex, bWord); return this.handleMoveHit(object, e, x, y, group, false, pageIndex, bWord);
} }
} }
this.resetSelection(); this.resetSelection(true);
(group ? group : this).selectObject(object,pageIndex); (group ? group : this).selectObject(object,pageIndex);
object.selectionSetStart(e, x, y, pageIndex); object.selectionSetStart(e, x, y, pageIndex);
if(!group) if(!group)
...@@ -4478,13 +4491,13 @@ DrawingObjectsController.prototype = ...@@ -4478,13 +4491,13 @@ DrawingObjectsController.prototype =
} }
}, },
resetSelection: function() resetSelection: function(noResetContentSelect)
{ {
if(this.document) if(this.document)
{ {
this.checkChartTextSelection(); this.checkChartTextSelection();
} }
this.resetInternalSelection(); this.resetInternalSelection(noResetContentSelect);
for(var i = 0; i < this.selectedObjects.length; ++i) for(var i = 0; i < this.selectedObjects.length; ++i)
{ {
this.selectedObjects[i].selected = false; this.selectedObjects[i].selected = false;
......
...@@ -564,7 +564,7 @@ function handleFloatTable(drawing, drawingObjectsController, e, x, y, group, pag ...@@ -564,7 +564,7 @@ function handleFloatTable(drawing, drawingObjectsController, e, x, y, group, pag
var content, invert_transform_text, tx, ty, hit_paragraph, par, check_hyperlink; var content, invert_transform_text, tx, ty, hit_paragraph, par, check_hyperlink;
if(drawingObjectsController.handleEventMode === HANDLE_EVENT_MODE_HANDLE) if(drawingObjectsController.handleEventMode === HANDLE_EVENT_MODE_HANDLE)
{ {
drawingObjectsController.resetSelection(); drawingObjectsController.resetSelection(true);
(group ? group : drawingObjectsController).selectObject(drawing,pageIndex); (group ? group : drawingObjectsController).selectObject(drawing,pageIndex);
if(!group) if(!group)
{ {
......
...@@ -393,12 +393,15 @@ CChartSpace.prototype = ...@@ -393,12 +393,15 @@ CChartSpace.prototype =
} }
}, },
resetInternalSelection: function() resetInternalSelection: function(noResetContentSelect)
{ {
if(this.selection.textSelection) if(this.selection.textSelection)
{ {
//var content = this.selection.textSelection.getDocContent(); if(!(noResetContentSelect === true))
//content && content.Selection_Remove(); {
var content = this.selection.textSelection.getDocContent();
content && content.Selection_Remove();
}
this.selection.textSelection = null; this.selection.textSelection = null;
} }
}, },
...@@ -414,9 +417,9 @@ CChartSpace.prototype = ...@@ -414,9 +417,9 @@ CChartSpace.prototype =
return this.txPr.content; return this.txPr.content;
}, },
resetSelection: function() resetSelection: function(noResetContentSelect)
{ {
this.resetInternalSelection(); this.resetInternalSelection(noResetContentSelect);
this.selection.title = null; this.selection.title = null;
this.selection.legend = null; this.selection.legend = null;
this.selection.legendEntry = null; this.selection.legendEntry = null;
......
...@@ -199,7 +199,7 @@ NullState.prototype = ...@@ -199,7 +199,7 @@ NullState.prototype =
if(this.drawingObjects.handleEventMode === HANDLE_EVENT_MODE_HANDLE) if(this.drawingObjects.handleEventMode === HANDLE_EVENT_MODE_HANDLE)
{ {
this.drawingObjects.checkChartTextSelection(); this.drawingObjects.checkChartTextSelection();
this.drawingObjects.resetInternalSelection(); this.drawingObjects.resetInternalSelection(true);
} }
if(!b_no_handle_selected) if(!b_no_handle_selected)
{ {
......
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