[Libreoffice-commits] core.git: Branch 'feature/inherited-number-format-removal' - 2 commits - sc/qa sc/source
Markus Mohrhard
markus.mohrhard at googlemail.com
Sun May 26 14:34:26 PDT 2013
sc/qa/unit/helper/csv_handler.hxx | 4 ++--
sc/source/core/data/column3.cxx | 4 ++++
2 files changed, 6 insertions(+), 2 deletions(-)
New commits:
commit b84b02b25d07846c2c2283f8cc9b47fef5229c3b
Author: Markus Mohrhard <markus.mohrhard at googlemail.com>
Date: Sun May 26 23:26:46 2013 +0200
temporary ugly hack for ordering problem
Currently we have a problem with the ordering of the calls when we come
to old cells that had inherited formats. They may not yet contain a
number format when we get the number format.
Change-Id: I0ddcdd10ff6ff0a43dbfecaf191e5903d3c0f9ce
diff --git a/sc/source/core/data/column3.cxx b/sc/source/core/data/column3.cxx
index 0b3c64f..eaf0226 100644
--- a/sc/source/core/data/column3.cxx
+++ b/sc/source/core/data/column3.cxx
@@ -1721,6 +1721,10 @@ void ScColumn::GetString( SCROW nRow, OUString& rString ) const
aCell.assign(*maItems[nIndex].pCell);
if (aCell.meType != CELLTYPE_NOTE)
{
+ // ugly hack for ordering problem with GetNumberFormat and missing inherited formats
+ if(aCell.meType == CELLTYPE_FORMULA)
+ aCell.mpFormula->MaybeInterpret();
+
sal_uLong nFormat = GetNumberFormat( nRow );
ScCellFormat::GetString(aCell, nFormat, rString, &pColor, *(pDocument->GetFormatTable()));
}
commit 101612e49c50871f70346c4285e6413292b2df80
Author: Markus Mohrhard <markus.mohrhard at googlemail.com>
Date: Sat May 25 16:04:39 2013 +0200
use the correct order of arguments for expected and actual in calc tests
Change-Id: I40fc9b46d35e7046ef51c6ea92f9a1595f6d74a1
diff --git a/sc/qa/unit/helper/csv_handler.hxx b/sc/qa/unit/helper/csv_handler.hxx
index a591cf8..aa98257 100644
--- a/sc/qa/unit/helper/csv_handler.hxx
+++ b/sc/qa/unit/helper/csv_handler.hxx
@@ -123,7 +123,7 @@ public:
std::cout << "result: " << (int)(aCSVString == aString) << std::endl;
#endif //DEBUG_CSV_HANDLER
- CPPUNIT_ASSERT_EQUAL_MESSAGE(createErrorMessage(mnCol, mnRow, mnTab, aCSVString, aString).getStr(), aString, aCSVString);
+ CPPUNIT_ASSERT_EQUAL_MESSAGE(createErrorMessage(mnCol, mnRow, mnTab, aCSVString, aString).getStr(), aCSVString, aString);
}
else
{
@@ -151,7 +151,7 @@ public:
std::cout << "result: " << (int)(aCSVString == aString) << std::endl;
#endif //DEBUG_CSV_HANDLER
- CPPUNIT_ASSERT_EQUAL_MESSAGE(createErrorMessage(mnCol, mnRow, mnTab, aCSVString, aString).getStr(), aString, aCSVString);
+ CPPUNIT_ASSERT_EQUAL_MESSAGE(createErrorMessage(mnCol, mnRow, mnTab, aCSVString, aString).getStr(), aCSVString, aString);
}
else
{
More information about the Libreoffice-commits
mailing list