summaryrefslogtreecommitdiff
path: root/filter
diff options
context:
space:
mode:
authorNoel Grandin <noelgrandin@gmail.com>2021-04-13 16:10:04 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2021-04-13 18:42:00 +0200
commit851505db4f0514c2651d9fee6d5de9f63dd73217 (patch)
treed5c9bb7325ad729ab0a13de1eecff01d7dc44e74 /filter
parent19fb87c8a1aab9b172f07a1a1526854cfddd8dc5 (diff)
no need to make copies of these objects
when querying their values. The copy triggers heap allocation, which shows up when loading lots of shapes. Change-Id: I4b70e0c64b2397a97216065bd6da61daaac7f3ba Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114054 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'filter')
-rw-r--r--filter/source/msfilter/svdfppt.cxx12
1 files changed, 6 insertions, 6 deletions
diff --git a/filter/source/msfilter/svdfppt.cxx b/filter/source/msfilter/svdfppt.cxx
index c2c8b8b25070..341198369bac 100644
--- a/filter/source/msfilter/svdfppt.cxx
+++ b/filter/source/msfilter/svdfppt.cxx
@@ -7421,16 +7421,16 @@ static void ApplyCellAttributes( const SdrObject* pObj, Reference< XCell > const
{
eFS = css::drawing::FillStyle_BITMAP;
- const XFillBitmapItem aXFillBitmapItem(pObj->GetMergedItem( XATTR_FILLBITMAP ));
- uno::Reference<graphic::XGraphic> xGraphic = aXFillBitmapItem.GetGraphicObject().GetGraphic().GetXGraphic();
+ const XFillBitmapItem & rXFillBitmapItem(pObj->GetMergedItem( XATTR_FILLBITMAP ));
+ uno::Reference<graphic::XGraphic> xGraphic = rXFillBitmapItem.GetGraphicObject().GetGraphic().GetXGraphic();
uno::Reference<awt::XBitmap> xBitmap(xGraphic, uno::UNO_QUERY);
xPropSet->setPropertyValue("FillBitmap", uno::makeAny(xBitmap));
- const XFillBmpStretchItem aStretchItem(pObj->GetMergedItem( XATTR_FILLBMP_STRETCH ));
- const XFillBmpTileItem aTileItem(pObj->GetMergedItem( XATTR_FILLBMP_TILE ));
- if( aTileItem.GetValue() )
+ const XFillBmpStretchItem & rStretchItem(pObj->GetMergedItem( XATTR_FILLBMP_STRETCH ));
+ const XFillBmpTileItem & rTileItem(pObj->GetMergedItem( XATTR_FILLBMP_TILE ));
+ if( rTileItem.GetValue() )
xPropSet->setPropertyValue("FillBitmapMode", uno::makeAny(drawing::BitmapMode_REPEAT));
- else if( aStretchItem.GetValue() )
+ else if( rStretchItem.GetValue() )
xPropSet->setPropertyValue("FillBitmapMode", uno::makeAny(drawing::BitmapMode_STRETCH));
else
xPropSet->setPropertyValue("FillBitmapMode", uno::makeAny(drawing::BitmapMode_NO_REPEAT));