Kaydet (Commit) 2118ec36 authored tarafından Markus Mohrhard's avatar Markus Mohrhard

update the relatice refs after the absolute refs, fdo#47285

The algoithm for updating absolute refs needs to calculate the old
position based on the information before any updates to the RefData
üst bd43abc9
...@@ -788,9 +788,6 @@ ScFormulaCell::ScFormulaCell( const ScFormulaCell& rCell, ScDocument& rDoc, cons ...@@ -788,9 +788,6 @@ ScFormulaCell::ScFormulaCell( const ScFormulaCell& rCell, ScDocument& rDoc, cons
{ {
pCode = rCell.pCode->Clone(); pCode = rCell.pCode->Clone();
if ( nCloneFlags & SC_CLONECELL_ADJUST3DREL )
pCode->ReadjustRelative3DReferences( rCell.aPos, aPos );
// evtl. Fehler zuruecksetzen und neu kompilieren // evtl. Fehler zuruecksetzen und neu kompilieren
// nicht im Clipboard - da muss das Fehlerflag erhalten bleiben // nicht im Clipboard - da muss das Fehlerflag erhalten bleiben
// Spezialfall Laenge=0: als Fehlerzelle erzeugt, dann auch Fehler behalten // Spezialfall Laenge=0: als Fehlerzelle erzeugt, dann auch Fehler behalten
...@@ -827,6 +824,9 @@ ScFormulaCell::ScFormulaCell( const ScFormulaCell& rCell, ScDocument& rDoc, cons ...@@ -827,6 +824,9 @@ ScFormulaCell::ScFormulaCell( const ScFormulaCell& rCell, ScDocument& rDoc, cons
pCode->AdjustAbsoluteRefs( rCell.pDocument, rCell.aPos, aPos ); pCode->AdjustAbsoluteRefs( rCell.pDocument, rCell.aPos, aPos );
} }
if ( nCloneFlags & SC_CLONECELL_ADJUST3DREL )
pCode->ReadjustRelative3DReferences( rCell.aPos, aPos );
if( !bCompile ) if( !bCompile )
{ // Name references with references and ColRowNames { // Name references with references and ColRowNames
pCode->Reset(); pCode->Reset();
......
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