Commit 5a4d4c4e authored by Ilya Kirillov's avatar Ilya Kirillov

Fixed bug #34253. Now if autoshape or image were selected then we don't remove...

Fixed bug #34253. Now if autoshape or image were selected then we don't remove them from document on a paste function.
parent a4041006
......@@ -2256,7 +2256,7 @@ PasteProcessor.prototype =
var oThis = this;
//удаляем в начале, иначе может получиться что будем вставлять в элементы, которое потом удалим.
//todo с удалением в начале есть проблема, что удаляем элементы даже при пустом буфере
this.oLogicDocument.Remove(1, true, true, true);
this.oLogicDocument.RemoveBeforePaste();
this.oDocument = this._GetTargetDocument(this.oDocument);
if(this.oDocument && this.oDocument.bPresentation){
......
......@@ -4273,6 +4273,13 @@ CDocument.prototype.Remove = function(nDirection, bOnlyText, bRemoveOnlySelectio
this.Document_UpdateInterfaceState();
this.Document_UpdateRulersState();
};
CDocument.prototype.RemoveBeforePaste = function()
{
if (docpostype_DrawingObjects === this.Get_DocPosType() && null === this.DrawingObjects.getTargetDocContent())
this.Selection_Remove();
else
this.Remove(1, true, true, true);
};
CDocument.prototype.Cursor_GetPos = function()
{
return this.Controller.GetCursorPosXY();
......
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