[Libreoffice-commits] .: Branch 'feature/gsoc-calc-perf' - sc/source
Daniel Bankston
dbank at kemper.freedesktop.org
Thu May 10 13:17:06 PDT 2012
sc/source/filter/inc/sheetdatabuffer.hxx | 4 ----
sc/source/filter/oox/sheetdatabuffer.cxx | 27 ++++-----------------------
2 files changed, 4 insertions(+), 27 deletions(-)
New commits:
commit 7012cffe396999ba34918cc14a78d494822665ef
Author: Daniel Bankston <daniel.e.bankston at gmail.com>
Date: Thu May 10 15:10:01 2012 -0500
Remove getCellBlock() code that always returns null.
- Removed CellBlockBuffer::getCellBlock() method that always returns null as per my IRC convo yesterday with Kohei.
Change-Id: If57429c8cf48d309a610c703d97b53406653a767
diff --git a/sc/source/filter/inc/sheetdatabuffer.hxx b/sc/source/filter/inc/sheetdatabuffer.hxx
index 65612bc..c8dc451 100644
--- a/sc/source/filter/inc/sheetdatabuffer.hxx
+++ b/sc/source/filter/inc/sheetdatabuffer.hxx
@@ -152,10 +152,6 @@ public:
/** Sets column span information for a row. */
void setColSpans( sal_Int32 nRow, const ValueRangeSet& rColSpans );
- /** Tries to find a cell block. Recalculates the map of cell blocks, if the
- passed cell address is located in another row than the last cell. */
- CellBlock* getCellBlock( const ::com::sun::star::table::CellAddress& rCellAddr );
-
/** Inserts all cells of all open cell blocks into the Calc document. */
void finalizeImport();
diff --git a/sc/source/filter/oox/sheetdatabuffer.cxx b/sc/source/filter/oox/sheetdatabuffer.cxx
index 245b167..6d4e305 100644
--- a/sc/source/filter/oox/sheetdatabuffer.cxx
+++ b/sc/source/filter/oox/sheetdatabuffer.cxx
@@ -211,13 +211,6 @@ void CellBlockBuffer::setColSpans( sal_Int32 nRow, const ValueRangeSet& rColSpan
maColSpans[ nRow ] = rColSpans.getRanges();
}
-CellBlock* CellBlockBuffer::getCellBlock( const CellAddress& rCellAddr )
-{
- (void) rCellAddr;
- // TODO: Fix this.
- return NULL;
-}
-
void CellBlockBuffer::finalizeImport()
{
maCellBlocks.forEachMem( &CellBlock::finalizeImport );
@@ -244,19 +237,13 @@ void SheetDataBuffer::setBlankCell( const CellModel& rModel )
void SheetDataBuffer::setValueCell( const CellModel& rModel, double fValue )
{
- if( CellBlock* pCellBlock = maCellBlocks.getCellBlock( rModel.maCellAddr ) )
- pCellBlock->getCellAny( rModel.maCellAddr.Column ) <<= fValue;
- else
- putValue( rModel.maCellAddr, fValue );
+ putValue( rModel.maCellAddr, fValue );
setCellFormat( rModel );
}
void SheetDataBuffer::setStringCell( const CellModel& rModel, const OUString& rText )
{
- if( CellBlock* pCellBlock = maCellBlocks.getCellBlock( rModel.maCellAddr ) )
- pCellBlock->getCellAny( rModel.maCellAddr.Column ) <<= rText;
- else
- putString( rModel.maCellAddr, rText );
+ putString( rModel.maCellAddr, rText );
setCellFormat( rModel );
}
@@ -271,10 +258,7 @@ void SheetDataBuffer::setStringCell( const CellModel& rModel, const RichStringRe
}
else
{
- if( CellBlock* pCellBlock = maCellBlocks.getCellBlock( rModel.maCellAddr ) )
- pCellBlock->insertRichString( rModel.maCellAddr, rxString, pFirstPortionFont );
- else
- putRichString( rModel.maCellAddr, *rxString, pFirstPortionFont );
+ putRichString( rModel.maCellAddr, *rxString, pFirstPortionFont );
setCellFormat( rModel );
}
}
@@ -574,10 +558,7 @@ void SheetDataBuffer::setCellFormula( const CellAddress& rCellAddr, const ApiTok
{
if( rTokens.hasElements() )
{
- if( CellBlock* pCellBlock = maCellBlocks.getCellBlock( rCellAddr ) )
- pCellBlock->getCellAny( rCellAddr.Column ) <<= rTokens;
- else
- putFormulaTokens( rCellAddr, rTokens );
+ putFormulaTokens( rCellAddr, rTokens );
}
}
More information about the Libreoffice-commits
mailing list