Kaydet (Commit) f2ac9fab authored tarafından Eike Rathke's avatar Eike Rathke

fdo#68385 update references only if cut originates from the same document

Change-Id: Ia7b27309251cf9e47505c58d8ed0172d134280f4
üst 64c479e9
...@@ -2548,11 +2548,16 @@ void ScDocument::CopyBlockFromClip( ...@@ -2548,11 +2548,16 @@ void ScDocument::CopyBlockFromClip(
aRefCxt.mnTabDelta = nDz; aRefCxt.mnTabDelta = nDz;
if (rCxt.getClipDoc()->GetClipParam().mbCutMode) if (rCxt.getClipDoc()->GetClipParam().mbCutMode)
{ {
bool bOldInserting = IsInsertingFromOtherDoc(); // Update references only if cut originates from the same
SetInsertingFromOtherDoc( true); // document we are pasting into.
aRefCxt.meMode = URM_MOVE; if (rCxt.getClipDoc()->GetPool() == GetPool())
UpdateReference(aRefCxt, rCxt.getUndoDoc(), false); {
SetInsertingFromOtherDoc( bOldInserting); bool bOldInserting = IsInsertingFromOtherDoc();
SetInsertingFromOtherDoc( true);
aRefCxt.meMode = URM_MOVE;
UpdateReference(aRefCxt, rCxt.getUndoDoc(), false);
SetInsertingFromOtherDoc( bOldInserting);
}
} }
else else
{ {
......
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