summaryrefslogtreecommitdiff
path: root/sc/source/core/data/document.cxx
diff options
context:
space:
mode:
authorKohei Yoshida <kohei.yoshida@collabora.com>2014-02-24 13:10:17 -0500
committerMarkus Mohrhard <markus.mohrhard@googlemail.com>2014-02-27 00:47:23 -0600
commit4274001144adeb0b0a1e7da05d52c1bedbe899e5 (patch)
treec2d386d5907a6f959133ff1225fbde624e8d6396 /sc/source/core/data/document.cxx
parent872312d4bbea4d2fa6f8a3a1eb667e709085d54d (diff)
fdo#75259: Let undo document share its string pool with the source doc.
We already do that for the pool helper. It would only make sense to do it for shared strings as well. Change-Id: I813d262799af6f0c1d3fa12246ad973f852ac199 (cherry picked from commit e752620bf593af8839831f693ec21bb02a8b23d6) Reviewed-on: https://gerrit.libreoffice.org/8210 Tested-by: Markus Mohrhard <markus.mohrhard@googlemail.com> Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
Diffstat (limited to 'sc/source/core/data/document.cxx')
-rw-r--r--sc/source/core/data/document.cxx3
1 files changed, 3 insertions, 0 deletions
diff --git a/sc/source/core/data/document.cxx b/sc/source/core/data/document.cxx
index ec2c21a07627..ab39965d2863 100644
--- a/sc/source/core/data/document.cxx
+++ b/sc/source/core/data/document.cxx
@@ -1852,7 +1852,10 @@ void ScDocument::InitUndo( ScDocument* pSrcDoc, SCTAB nTab1, SCTAB nTab2,
{
Clear();
+ // Undo document shares its pooled resources with the source document.
xPoolHelper = pSrcDoc->xPoolHelper;
+ mpCellStringPool = pSrcDoc->mpCellStringPool;
+
if (pSrcDoc->pShell->GetMedium())
maFileURL = pSrcDoc->pShell->GetMedium()->GetURLObject().GetMainURL(INetURLObject::DECODE_TO_IURI);