[Libreoffice-commits] core.git: 2 commits - sc/source
Eike Rathke
erack at redhat.com
Mon Dec 15 17:02:43 PST 2014
sc/source/core/data/formulacell.cxx | 2 +-
sc/source/filter/oox/sheetdatabuffer.cxx | 7 ++++++-
2 files changed, 7 insertions(+), 2 deletions(-)
New commits:
commit a1dc5e97da273bf35d58d54e625149022569a993
Author: Eike Rathke <erack at redhat.com>
Date: Tue Dec 16 01:56:58 2014 +0100
construct grouped ScFormulaCell with bDirty=true, fdo#79249 related
Noticed when loading
https://bugs.freedesktop.org/attachment.cgi?id=99844
with fdo#79249 fix where oox::xls::applyCellFormulas() groups the
consecutive =#N/A formulas. Only A1 result was displayed, other cells
were displayed empty.
Change-Id: I3a541f74d3d25e1515a1c6d47f02ec6a8e817c93
diff --git a/sc/source/core/data/formulacell.cxx b/sc/source/core/data/formulacell.cxx
index 7cf0656..56776ae 100644
--- a/sc/source/core/data/formulacell.cxx
+++ b/sc/source/core/data/formulacell.cxx
@@ -751,7 +751,7 @@ ScFormulaCell::ScFormulaCell(
nSeenInIteration(0),
cMatrixFlag ( cInd ),
nFormatType(xGroup->mnFormatType),
- bDirty(false),
+ bDirty(true),
bChanged( false ),
bRunning( false ),
bCompile( false ),
commit 994607b55104b9ae4554554c13b001b8d5d513b6
Author: Eike Rathke <erack at redhat.com>
Date: Tue Dec 16 01:37:31 2014 +0100
fdo#79249 call formula compiler with error string
... instead of attempting to stringize a NaN coded error value.
Regression introduced with 30a20743ae17e6e02183a65603d38968253b3ffb
Change-Id: Ia7a8ca39938820ac75db169404446fa696c6ee1b
diff --git a/sc/source/filter/oox/sheetdatabuffer.cxx b/sc/source/filter/oox/sheetdatabuffer.cxx
index 7cdf627..1e66c87 100644
--- a/sc/source/filter/oox/sheetdatabuffer.cxx
+++ b/sc/source/filter/oox/sheetdatabuffer.cxx
@@ -197,11 +197,16 @@ void SheetDataBuffer::setBooleanCell( const CellModel& rModel, bool bValue )
void SheetDataBuffer::setErrorCell( const CellModel& rModel, const OUString& rErrorCode )
{
- setErrorCell( rModel, getUnitConverter().calcBiffErrorCode( rErrorCode ) );
+ // Using the formula compiler now we can simply pass on the error string.
+ getFormulaBuffer().setCellFormula( rModel.maCellAddr, rErrorCode);
+ setCellFormat( rModel );
}
void SheetDataBuffer::setErrorCell( const CellModel& rModel, sal_uInt8 nErrorCode )
{
+ assert(!"stringizing any NaN will only give 'nan'");
+ /* FIXME: map nErrorCode to error string and call setErrorCell() above. */
+
OUStringBuffer aBuf;
aBuf.append('{');
aBuf.append(BiffHelper::calcDoubleFromError(nErrorCode));
More information about the Libreoffice-commits
mailing list