diff options
author | Eike Rathke <erack@redhat.com> | 2014-07-11 23:15:50 +0200 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2014-07-22 14:01:21 +0000 |
commit | 9e83928e4dd65a1cf570f9cea65f456bd089ea33 (patch) | |
tree | 23116e06b64b6a1b0dc9868db8aaa14285c13d97 | |
parent | c4ad8f54e39d40b58223bcac99510d9798b7cdda (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/10246
Reviewed-by: David Tardon <dtardon@redhat.com>
Reviewed-by: Kohei Yoshida <libreoffice@kohei.us>
Reviewed-by: Muthu Subramanian K <muthusuba@gmail.com>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@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 8f51a724604c..ab47bee3f770 100644 --- a/sc/source/core/tool/token.cxx +++ b/sc/source/core/tool/token.cxx @@ -531,6 +531,9 @@ bool ScToken::Is3DRef() const if ( GetSingleRef().IsFlag3D() ) return true; break; + case svExternalSingleRef: + case svExternalDoubleRef: + return true; default: { // added to avoid warnings @@ -2251,6 +2254,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 |