diff options
author | Eike Rathke <erack@redhat.com> | 2014-07-11 23:15:50 +0200 |
---|---|---|
committer | David Tardon <dtardon@redhat.com> | 2014-07-15 09:50:45 +0000 |
commit | 37b97c83aa23d5a7c1687126d93cf1a69ce4a2d0 (patch) | |
tree | 34f4b7705c66c7d84b0cecbd0a31b9aae5326e90 | |
parent | 1293b2fde524de3668a831bfe962eb9291d7a4ae (diff) |
resolved fdo#77018 keep external references intact during sort
Needs e463de2a56453a0d2cb0b5b58e96f7639f37cdd1 fix for fdo#79441 to
work.
Change-Id: Ide1cbeb4b25b17b5102977ccbdf8e6dbfcadfc60
(cherry picked from commit db0a4c2575ffba1c170d74882b0f5a6229ec072f)
Reviewed-on: https://gerrit.libreoffice.org/10244
Reviewed-by: Muthu Subramanian K <muthusuba@gmail.com>
Reviewed-by: Kohei Yoshida <libreoffice@kohei.us>
Reviewed-by: David Tardon <dtardon@redhat.com>
Tested-by: David Tardon <dtardon@redhat.com>
-rw-r--r-- | sc/source/core/tool/token.cxx | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/sc/source/core/tool/token.cxx b/sc/source/core/tool/token.cxx index 4ac537f45155..87388778ee69 100644 --- a/sc/source/core/tool/token.cxx +++ b/sc/source/core/tool/token.cxx @@ -529,6 +529,9 @@ bool ScToken::Is3DRef() const if ( GetSingleRef().IsFlag3D() ) return true; break; + case svExternalSingleRef: + case svExternalDoubleRef: + return true; default: { // added to avoid warnings @@ -2261,6 +2264,20 @@ void ScTokenArray::ReadjustRelative3DReferences( const ScAddress& rOldPos, } } break; + case svExternalDoubleRef : + { + ScSingleRefData& rRef2 = static_cast<ScToken*>(pCode[j])->GetSingleRef2(); + ScAddress aAbs = rRef2.toAbs(rOldPos); + rRef2.SetAddress(aAbs, rNewPos); + } + //! fallthru + case svExternalSingleRef : + { + ScSingleRefData& rRef1 = static_cast<ScToken*>(pCode[j])->GetSingleRef(); + ScAddress aAbs = rRef1.toAbs(rOldPos); + rRef1.SetAddress(aAbs, rNewPos); + } + break; default: { // added to avoid warnings |