summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
authorEike Rathke <erack@redhat.com>2016-04-01 00:59:09 +0200
committerEike Rathke <erack@redhat.com>2016-04-01 01:01:02 +0200
commit6959ed39e4f6f4a71a860acbf734b19b14f9c604 (patch)
treea406605a17acd7f57d8171d71083279756e9af14 /sc
parent37f5df5537341232fdb0d68868408dec8fd84116 (diff)
re-enable copying global names to other docs
Change-Id: Ide022525decbbec1fb4a498074752615786daab4
Diffstat (limited to 'sc')
-rw-r--r--sc/source/core/data/formulacell.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/sc/source/core/data/formulacell.cxx b/sc/source/core/data/formulacell.cxx
index c3db7a97121c..e234bf0b4ab4 100644
--- a/sc/source/core/data/formulacell.cxx
+++ b/sc/source/core/data/formulacell.cxx
@@ -728,7 +728,7 @@ void adjustRangeName(formula::FormulaToken* pToken, ScDocument& rNewDoc, const S
pOldRangeData, rNewDoc, pOldDoc, rNewPos, rOldPos,
bGlobalNamesToLocal, nTmpSheet, nNewSheet, bSameDoc);
}
- if (bGlobalNamesToLocal && !aReferencingNames.isEmpty(-1))
+ if ((bGlobalNamesToLocal || !bSameDoc) && !aReferencingNames.isEmpty(-1))
{
const SCTAB nTmpSheet = -1;
ScRangeData* pTmpData = copyRangeNames( aSheetIndexMap, aRangeDataVec, aReferencingNames, -1,