summaryrefslogtreecommitdiff
path: root/sc/source/ui/docshell/externalrefmgr.cxx
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2018-03-07 14:17:38 +0200
committerEike Rathke <erack@redhat.com>2018-03-10 19:22:01 +0100
commit6529cd54c29c5800340530a1b8182c341fbeeafb (patch)
tree2b09ee9429a0759b8104575aa97e1f4aeadd443e /sc/source/ui/docshell/externalrefmgr.cxx
parent4ea605cb5c31fe4c7d3931a656782a652b4d96fc (diff)
don't use heap for elements in ScRangeList
no need to store small objects like this out of line. Also - add move constructor and move assignment operator - drop Assign method since it now has the same signature as push_back Change-Id: I9a8647d3a11f24166a83d399a358a2bce3b2cb79 Reviewed-on: https://gerrit.libreoffice.org/50899 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Eike Rathke <erack@redhat.com>
Diffstat (limited to 'sc/source/ui/docshell/externalrefmgr.cxx')
-rw-r--r--sc/source/ui/docshell/externalrefmgr.cxx5
1 files changed, 1 insertions, 4 deletions
diff --git a/sc/source/ui/docshell/externalrefmgr.cxx b/sc/source/ui/docshell/externalrefmgr.cxx
index 9676d89b318d..4ca3df975a36 100644
--- a/sc/source/ui/docshell/externalrefmgr.cxx
+++ b/sc/source/ui/docshell/externalrefmgr.cxx
@@ -435,10 +435,7 @@ void ScExternalRefCache::Table::setCachedCell(SCCOL nCol, SCROW nRow)
void ScExternalRefCache::Table::setCachedCellRange(SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2)
{
ScRange aRange(nCol1, nRow1, 0, nCol2, nRow2, 0);
- if ( maCachedRanges.empty() )
- maCachedRanges.Append(aRange);
- else
- maCachedRanges.Join(aRange);
+ maCachedRanges.Join(aRange);
}
void ScExternalRefCache::Table::setWholeTableCached()