summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
authorKohei Yoshida <kohei.yoshida@collabora.com>2014-02-14 11:41:02 -0500
committerEike Rathke <erack@redhat.com>2014-03-06 08:56:12 -0600
commitb6df2950db8394e6bd73fe708dbc20f3d8f4e5c2 (patch)
treebd967511b50f71d2bb2e59058c865154a6123917 /sc
parent24de7939b2f4416506bf4858711b91d48064a201 (diff)
fdo#72390: Let's not skip auto styles from unmodified sheets.
We do re-use sheet XML stream for unmodified sheets on re-save, which is okay. But skipping auto style population from unmodified sheets is not okay because autostyles are shared across all sheets and written outside the sheet XML streams. Skipping styles from unmodified sheets could potentially fail to export used styles, not to mention could cause a crash as reported in the bug. Change-Id: I73e439f7354e341c2c07e28ecca5452193985860 (cherry picked from commit 5000e64ecc55efd47d92714cf6db375ff37aac4b) (cherry picked from commit 47e540d8323e8ea2db5e7aae455503b32f306ca3) Reviewed-on: https://gerrit.libreoffice.org/8051 Reviewed-by: Eike Rathke <erack@redhat.com> Tested-by: Eike Rathke <erack@redhat.com>
Diffstat (limited to 'sc')
-rw-r--r--sc/source/filter/xml/xmlexprt.cxx7
1 files changed, 0 insertions, 7 deletions
diff --git a/sc/source/filter/xml/xmlexprt.cxx b/sc/source/filter/xml/xmlexprt.cxx
index 09dc864ec3fa..4b09c3bd4865 100644
--- a/sc/source/filter/xml/xmlexprt.cxx
+++ b/sc/source/filter/xml/xmlexprt.cxx
@@ -2322,10 +2322,6 @@ void ScXMLExport::_ExportAutoStyles()
CollectShapesAutoStyles(nTableCount);
for (sal_Int32 nTable = 0; nTable < nTableCount; ++nTable, IncrementProgressBar(false))
{
- bool bUseStream = pSheetData && pDoc && pDoc->IsStreamValid((SCTAB)nTable) &&
- pSheetData->HasStreamPos(nTable) && xSourceStream.is() &&
- !pDoc->GetChangeTrack();
-
Reference <sheet::XSpreadsheet> xTable(xIndex->getByIndex(nTable), uno::UNO_QUERY);
if (!xTable.is())
continue;
@@ -2344,9 +2340,6 @@ void ScXMLExport::_ExportAutoStyles()
}
}
- if (bUseStream)
- continue;
-
// collect other auto-styles only for non-copied sheets
Reference<sheet::XUniqueCellFormatRangesSupplier> xCellFormatRanges ( xTable, uno::UNO_QUERY );
if ( xCellFormatRanges.is() )