summaryrefslogtreecommitdiff
path: root/reportdesign/source/ui/report/ReportController.cxx
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2021-05-07 22:06:14 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2021-05-08 17:36:54 +0200
commit1545949690c750d7b512000723b564e69cf3c3a6 (patch)
tree1463c8b2912a9e269fe8b7ef3f7326dc85173830 /reportdesign/source/ui/report/ReportController.cxx
parentc10ce2698a3b001d22db3d33f2f43513cc49ebda (diff)
ref-count SfxItemPool
so we can remove SfxItemPoolUser, which is a right performance hog when we have large calc spreadsheets Change-Id: I344002f536f6eead5cf98c6647dd1667fd9c8874 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115247 Tested-by: Noel Grandin <noel.grandin@collabora.co.uk> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'reportdesign/source/ui/report/ReportController.cxx')
-rw-r--r--reportdesign/source/ui/report/ReportController.cxx8
1 files changed, 4 insertions, 4 deletions
diff --git a/reportdesign/source/ui/report/ReportController.cxx b/reportdesign/source/ui/report/ReportController.cxx
index 6b7f10c377af..de4be54c181e 100644
--- a/reportdesign/source/ui/report/ReportController.cxx
+++ b/reportdesign/source/ui/report/ReportController.cxx
@@ -2369,7 +2369,7 @@ void OReportController::openPageDialog(const uno::Reference<report::XSection>& _
SID_ATTR_METRIC,SID_ATTR_METRIC,
0
};
- std::unique_ptr<SfxItemPool, SfxItemPoolDeleter> pPool( new SfxItemPool("ReportPageProperties", RPTUI_ID_LRSPACE, RPTUI_ID_METRIC, aItemInfos ) );
+ rtl::Reference<SfxItemPool> pPool( new SfxItemPool("ReportPageProperties", RPTUI_ID_LRSPACE, RPTUI_ID_METRIC, aItemInfos ) );
const Graphic aNullGraphic;
const ::Color aNullLineCol(COL_DEFAULT_SHAPE_STROKE); // #i121448# Use defined default color
@@ -2513,7 +2513,7 @@ void OReportController::openPageDialog(const uno::Reference<report::XSection>& _
{
DBG_UNHANDLED_EXCEPTION("reportdesign");
}
- pPool.reset();
+ pPool.clear();
for (SfxPoolItem* pDefault : pDefaults)
delete pDefault;
@@ -4218,7 +4218,7 @@ void OReportController::openZoomDialog()
SID_ATTR_ZOOM,SID_ATTR_ZOOM,
0
};
- std::unique_ptr<SfxItemPool, SfxItemPoolDeleter> pPool( new SfxItemPool("ZoomProperties", SID_ATTR_ZOOM,SID_ATTR_ZOOM, aItemInfos, &pDefaults) );
+ rtl::Reference<SfxItemPool> pPool( new SfxItemPool("ZoomProperties", SID_ATTR_ZOOM,SID_ATTR_ZOOM, aItemInfos, &pDefaults) );
pPool->SetDefaultMetric( MapUnit::Map100thMM ); // ripped, don't understand why
pPool->FreezeIdRanges(); // the same
try
@@ -4248,7 +4248,7 @@ void OReportController::openZoomDialog()
{
DBG_UNHANDLED_EXCEPTION("reportdesign");
}
- pPool.reset();
+ pPool.clear();
for (SfxPoolItem* pDefault : pDefaults)
delete pDefault;