diff options
author | Noel Grandin <noel@peralex.com> | 2012-03-16 09:47:04 +0200 |
---|---|---|
committer | Fridrich Štrba <fridrich.strba@bluewin.ch> | 2012-03-22 06:55:58 +0100 |
commit | 6af00cf90f4314be11ac7d8f186bb9da4f228cf1 (patch) | |
tree | 303e25dbad2214a76c27ec4fb3be42af5ea27e1e /sc | |
parent | 13bf19769e6e0522d920594225b9baa2c1b7dd63 (diff) |
remove unnecessary use of local variable and auto_ptr
Diffstat (limited to 'sc')
-rw-r--r-- | sc/source/ui/unoobj/chart2uno.cxx | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/sc/source/ui/unoobj/chart2uno.cxx b/sc/source/ui/unoobj/chart2uno.cxx index 1a04ce472a15..0c86655c9fe0 100644 --- a/sc/source/ui/unoobj/chart2uno.cxx +++ b/sc/source/ui/unoobj/chart2uno.cxx @@ -717,7 +717,6 @@ void Chart2Positioner::createPositionMap() bool bNoGlue = (meGlue == GLUETYPE_NONE); SAL_WNODEPRECATED_DECLARATIONS_PUSH auto_ptr<Table> pCols(new Table); - auto_ptr<Table> pNewRowTable(new Table); SAL_WNODEPRECATED_DECLARATIONS_POP Table* pCol = NULL; SCROW nNoGlueRow = 0; @@ -752,9 +751,8 @@ void Chart2Positioner::createPositionMap() pCol = static_cast<Table*>(pCols->Get(nInsCol)); if (!pCol) { - pCol = pNewRowTable.get(); - pCols->Insert(nInsCol, pNewRowTable.release()); - pNewRowTable.reset(new Table); + pCol = new Table; + pCols->Insert(nInsCol, pCol); } sal_uInt32 nInsRow = static_cast<sal_uInt32>(bNoGlue ? nNoGlueRow : nRow1); @@ -773,7 +771,7 @@ void Chart2Positioner::createPositionMap() if (pCol->Get(nInsRow) == NULL) { if (bExternal) - pCol->Insert(nInsRow, new ScExternalSingleRefToken(nFileId, aTabName, aCellData)) + pCol->Insert(nInsRow, new ScExternalSingleRefToken(nFileId, aTabName, aCellData)); else pCol->Insert(nInsRow, new ScSingleRefToken(aCellData)); } @@ -782,7 +780,6 @@ void Chart2Positioner::createPositionMap() } nNoGlueRow += nRow2 - nRow1 + 1; } - pNewRowTable.reset(NULL); bool bFillRowHeader = mbRowHeaders; bool bFillColumnHeader = mbColHeaders; |