[Libreoffice-commits] core.git: 5 commits - chart2/source cui/source dbaccess/source filter/source writerfilter/inc writerfilter/source

Noel Grandin noel at peralex.com
Tue Apr 12 09:26:17 UTC 2016


 chart2/source/controller/chartapiwrapper/ChartDocumentWrapper.cxx                  |    2 
 chart2/source/controller/chartapiwrapper/DiagramWrapper.cxx                        |    2 
 chart2/source/controller/chartapiwrapper/WrappedAxisAndGridExistenceProperties.cxx |    6 -
 chart2/source/controller/chartapiwrapper/WrappedAxisAndGridExistenceProperties.hxx |    6 -
 chart2/source/controller/chartapiwrapper/WrappedDataCaptionProperties.cxx          |    6 -
 chart2/source/controller/chartapiwrapper/WrappedDataCaptionProperties.hxx          |    4 -
 chart2/source/controller/chartapiwrapper/WrappedScaleProperty.cxx                  |    2 
 chart2/source/controller/chartapiwrapper/WrappedScaleProperty.hxx                  |    2 
 chart2/source/controller/chartapiwrapper/WrappedScaleTextProperties.cxx            |    2 
 chart2/source/controller/chartapiwrapper/WrappedScaleTextProperties.hxx            |    2 
 chart2/source/controller/chartapiwrapper/WrappedSceneProperty.cxx                  |    2 
 chart2/source/controller/chartapiwrapper/WrappedSceneProperty.hxx                  |    2 
 chart2/source/controller/chartapiwrapper/WrappedSplineProperties.cxx               |    2 
 chart2/source/controller/chartapiwrapper/WrappedSplineProperties.hxx               |    2 
 chart2/source/controller/chartapiwrapper/WrappedStatisticProperties.cxx            |   12 +--
 chart2/source/controller/chartapiwrapper/WrappedStatisticProperties.hxx            |    4 -
 chart2/source/controller/chartapiwrapper/WrappedStockProperties.cxx                |    2 
 chart2/source/controller/chartapiwrapper/WrappedStockProperties.hxx                |    2 
 chart2/source/controller/chartapiwrapper/WrappedSymbolProperties.cxx               |    6 -
 chart2/source/controller/chartapiwrapper/WrappedSymbolProperties.hxx               |    4 -
 chart2/source/controller/dialogs/tp_RangeChooser.cxx                               |    1 
 chart2/source/controller/itemsetwrapper/RegressionCurveItemConverter.cxx           |    6 -
 chart2/source/controller/itemsetwrapper/StatisticsItemConverter.cxx                |    6 -
 chart2/source/controller/main/ChartController.cxx                                  |    4 -
 chart2/source/controller/main/DragMethod_RotateDiagram.cxx                         |    2 
 chart2/source/controller/sidebar/ChartAreaPanel.cxx                                |   18 ++--
 chart2/source/controller/sidebar/ChartAxisPanel.cxx                                |   18 ++--
 chart2/source/controller/sidebar/ChartColorWrapper.cxx                             |    6 -
 chart2/source/controller/sidebar/ChartColorWrapper.hxx                             |    2 
 chart2/source/controller/sidebar/ChartElementsPanel.cxx                            |   22 ++---
 chart2/source/controller/sidebar/ChartErrorBarPanel.cxx                            |   20 ++---
 chart2/source/controller/sidebar/ChartLinePanel.cxx                                |    6 -
 chart2/source/controller/sidebar/ChartSeriesPanel.cxx                              |   28 +++----
 chart2/source/inc/chartview/DataPointSymbolSupplier.hxx                            |    2 
 chart2/source/model/main/ChartModel_Persistence.cxx                                |    3 
 chart2/source/model/template/ChartTypeTemplate.cxx                                 |    2 
 chart2/source/model/template/ChartTypeTemplate.hxx                                 |    4 -
 chart2/source/view/charttypes/BarChart.cxx                                         |    5 -
 chart2/source/view/charttypes/VSeriesPlotter.cxx                                   |    6 -
 chart2/source/view/inc/AbstractShapeFactory.hxx                                    |    2 
 chart2/source/view/main/AbstractShapeFactory.cxx                                   |    2 
 chart2/source/view/main/ChartView.cxx                                              |    2 
 chart2/source/view/main/DataPointSymbolSupplier.cxx                                |    2 
 chart2/source/view/main/ShapeFactory.cxx                                           |    2 
 cui/source/customize/cfg.cxx                                                       |    2 
 cui/source/customize/cfgutil.cxx                                                   |    2 
 cui/source/customize/macropg.cxx                                                   |    4 -
 cui/source/customize/selector.cxx                                                  |    2 
 cui/source/dialogs/SpellDialog.cxx                                                 |    6 -
 cui/source/dialogs/hangulhanjadlg.cxx                                              |    2 
 cui/source/dialogs/hlmarkwn.cxx                                                    |    2 
 cui/source/dialogs/scriptdlg.cxx                                                   |    2 
 cui/source/inc/SpellDialog.hxx                                                     |    4 -
 cui/source/inc/cfg.hxx                                                             |    2 
 cui/source/inc/cfgutil.hxx                                                         |    2 
 cui/source/inc/cuitabarea.hxx                                                      |    2 
 cui/source/inc/hlmarkwn.hxx                                                        |    2 
 cui/source/inc/macropg.hxx                                                         |    4 -
 cui/source/inc/scriptdlg.hxx                                                       |    2 
 cui/source/inc/selector.hxx                                                        |    2 
 cui/source/options/connpooloptions.cxx                                             |    4 -
 cui/source/options/personalization.cxx                                             |    2 
 cui/source/options/personalization.hxx                                             |    2 
 cui/source/tabpages/tpcolor.cxx                                                    |    2 
 dbaccess/source/core/api/BookmarkSet.cxx                                           |    2 
 dbaccess/source/core/api/BookmarkSet.hxx                                           |    2 
 dbaccess/source/core/api/SingleSelectQueryComposer.cxx                             |    2 
 dbaccess/source/core/api/WrappedResultSet.cxx                                      |    2 
 dbaccess/source/core/api/WrappedResultSet.hxx                                      |    2 
 dbaccess/source/core/dataaccess/definitioncontainer.cxx                            |    6 -
 dbaccess/source/core/inc/definitioncontainer.hxx                                   |    6 -
 dbaccess/source/filter/xml/xmlfilter.cxx                                           |    2 
 dbaccess/source/ui/dlg/DbAdminImpl.cxx                                             |    2 
 dbaccess/source/ui/inc/FieldDescriptions.hxx                                       |    2 
 dbaccess/source/ui/inc/QueryDesignView.hxx                                         |    2 
 dbaccess/source/ui/inc/UITools.hxx                                                 |    2 
 dbaccess/source/ui/inc/indexcollection.hxx                                         |    2 
 dbaccess/source/ui/misc/UITools.cxx                                                |    2 
 dbaccess/source/ui/misc/indexcollection.cxx                                        |    2 
 dbaccess/source/ui/querydesign/QueryDesignView.cxx                                 |    4 -
 dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx                              |    2 
 dbaccess/source/ui/querydesign/SelectionBrowseBox.hxx                              |    2 
 dbaccess/source/ui/tabledesign/FieldDescriptions.cxx                               |    2 
 filter/source/flash/swfexporter.cxx                                                |    6 -
 filter/source/flash/swfexporter.hxx                                                |    6 -
 filter/source/flash/swffilter.cxx                                                  |    2 
 filter/source/msfilter/escherex.cxx                                                |    2 
 filter/source/msfilter/msdffimp.cxx                                                |    2 
 filter/source/msfilter/svdfppt.cxx                                                 |    4 -
 filter/source/placeware/exporter.cxx                                               |    6 -
 filter/source/placeware/exporter.hxx                                               |    4 -
 filter/source/svg/svgexport.cxx                                                    |    4 -
 filter/source/svg/svgfilter.cxx                                                    |    4 -
 filter/source/svg/svgfilter.hxx                                                    |    4 -
 filter/source/xsltdialog/typedetectionexport.cxx                                   |    6 -
 filter/source/xsltdialog/typedetectionexport.hxx                                   |    6 -
 filter/source/xsltdialog/typedetectionimport.cxx                                   |    2 
 filter/source/xsltdialog/typedetectionimport.hxx                                   |    2 
 filter/source/xsltdialog/xmlfiltercommon.hxx                                       |    2 
 filter/source/xsltdialog/xmlfilterjar.cxx                                          |    4 -
 filter/source/xsltdialog/xmlfilterjar.hxx                                          |    4 -
 filter/source/xsltdialog/xmlfiltersettingsdialog.cxx                               |    2 
 filter/source/xsltdialog/xmlfiltertestdialog.cxx                                   |    2 
 filter/source/xsltdialog/xmlfiltertestdialog.hxx                                   |    2 
 writerfilter/inc/ooxml/OOXMLDocument.hxx                                           |   10 +-
 writerfilter/source/dmapper/DomainMapper.cxx                                       |    6 -
 writerfilter/source/dmapper/DomainMapper.hxx                                       |    6 -
 writerfilter/source/dmapper/DomainMapperTableHandler.cxx                           |   14 +--
 writerfilter/source/dmapper/DomainMapperTableHandler.hxx                           |    6 -
 writerfilter/source/dmapper/DomainMapperTableManager.hxx                           |    8 +-
 writerfilter/source/dmapper/DomainMapper_Impl.cxx                                  |   38 +++++-----
 writerfilter/source/dmapper/DomainMapper_Impl.hxx                                  |   30 +++----
 writerfilter/source/dmapper/GraphicImport.cxx                                      |    6 -
 writerfilter/source/dmapper/NumberingManager.cxx                                   |    2 
 writerfilter/source/dmapper/NumberingManager.hxx                                   |    2 
 writerfilter/source/dmapper/OLEHandler.cxx                                         |    4 -
 writerfilter/source/dmapper/OLEHandler.hxx                                         |    8 +-
 writerfilter/source/dmapper/PropertyMap.cxx                                        |    8 +-
 writerfilter/source/dmapper/PropertyMap.hxx                                        |    8 +-
 writerfilter/source/dmapper/SdtHelper.cxx                                          |    2 
 writerfilter/source/dmapper/StyleSheetTable.cxx                                    |    6 -
 writerfilter/source/dmapper/StyleSheetTable.hxx                                    |    4 -
 writerfilter/source/dmapper/TDefTableHandler.cxx                                   |    4 -
 writerfilter/source/dmapper/TDefTableHandler.hxx                                   |    4 -
 writerfilter/source/dmapper/TableManager.cxx                                       |   14 +--
 writerfilter/source/dmapper/TableManager.hxx                                       |   14 +--
 writerfilter/source/dmapper/TagLogger.cxx                                          |    4 -
 writerfilter/source/dmapper/TagLogger.hxx                                          |    4 -
 writerfilter/source/ooxml/OOXMLDocumentImpl.cxx                                    |    8 +-
 writerfilter/source/ooxml/OOXMLDocumentImpl.hxx                                    |    6 -
 writerfilter/source/ooxml/OOXMLFactory.cxx                                         |    2 
 writerfilter/source/ooxml/OOXMLFactory.hxx                                         |    2 
 writerfilter/source/ooxml/OOXMLFastContextHandler.cxx                              |   24 +++---
 writerfilter/source/ooxml/OOXMLFastContextHandler.hxx                              |   24 +++---
 writerfilter/source/ooxml/OOXMLParserState.cxx                                     |    8 +-
 writerfilter/source/ooxml/OOXMLParserState.hxx                                     |    8 +-
 writerfilter/source/ooxml/OOXMLPropertySet.cxx                                     |    6 -
 writerfilter/source/ooxml/OOXMLPropertySet.hxx                                     |    6 -
 writerfilter/source/ooxml/OOXMLStreamImpl.cxx                                      |   10 +-
 writerfilter/source/ooxml/OOXMLStreamImpl.hxx                                      |    3 
 writerfilter/source/ooxml/factory_ns.py                                            |    2 
 writerfilter/source/ooxml/factoryimpl_ns.py                                        |    4 -
 writerfilter/source/rtftok/rtfdocumentimpl.cxx                                     |    6 -
 143 files changed, 374 insertions(+), 376 deletions(-)

New commits:
commit 6a8873c874db41e8818a74eb6bf2561dfdb296db
Author: Noel Grandin <noel at peralex.com>
Date:   Tue Apr 12 11:25:03 2016 +0200

    clang-tidy performance-unnecessary-value-param in filter
    
    Change-Id: I6818f6c9593bfe7105cc194fcf6f69131046e4f3

diff --git a/filter/source/flash/swfexporter.cxx b/filter/source/flash/swfexporter.cxx
index 075bd7f..4aa4845 100644
--- a/filter/source/flash/swfexporter.cxx
+++ b/filter/source/flash/swfexporter.cxx
@@ -129,7 +129,7 @@ const sal_uInt16 cBackgroundObjectsDepth = 3;
 const sal_uInt16 cPageObjectsDepth = 4;
 const sal_uInt16 cWaitButtonDepth = 10;
 
-bool FlashExporter::exportAll( Reference< XComponent > xDoc, Reference< XOutputStream > &xOutputStream, Reference< XStatusIndicator> &xStatusIndicator )
+bool FlashExporter::exportAll( const Reference< XComponent >& xDoc, Reference< XOutputStream > &xOutputStream, Reference< XStatusIndicator> &xStatusIndicator )
 {
     Reference< XServiceInfo > xDocServInfo( xDoc, UNO_QUERY );
     if( xDocServInfo.is() )
@@ -272,7 +272,7 @@ bool FlashExporter::exportAll( Reference< XComponent > xDoc, Reference< XOutputS
 }
 
 
-bool FlashExporter::exportSlides( Reference< XDrawPage > xDrawPage, Reference< XOutputStream > &xOutputStream, sal_uInt16 /* nPage */ )
+bool FlashExporter::exportSlides( const Reference< XDrawPage >& xDrawPage, Reference< XOutputStream > &xOutputStream, sal_uInt16 /* nPage */ )
 {
     Reference< XPropertySet > xPropSet( xDrawPage, UNO_QUERY );
     if( !xDrawPage.is() || !xPropSet.is() )
@@ -308,7 +308,7 @@ bool FlashExporter::exportSlides( Reference< XDrawPage > xDrawPage, Reference< X
     return true;
 }
 
-sal_uInt16 FlashExporter::exportBackgrounds( Reference< XDrawPage > xDrawPage, Reference< XOutputStream > &xOutputStream, sal_uInt16 nPage, bool bExportObjects )
+sal_uInt16 FlashExporter::exportBackgrounds( const Reference< XDrawPage >& xDrawPage, Reference< XOutputStream > &xOutputStream, sal_uInt16 nPage, bool bExportObjects )
 {
     Reference< XPropertySet > xPropSet( xDrawPage, UNO_QUERY );
     if( !xDrawPage.is() || !xPropSet.is() )
diff --git a/filter/source/flash/swfexporter.hxx b/filter/source/flash/swfexporter.hxx
index b369312..5bf4f51 100644
--- a/filter/source/flash/swfexporter.hxx
+++ b/filter/source/flash/swfexporter.hxx
@@ -128,9 +128,9 @@ public:
 
     void Flush();
 
-    bool exportAll( css::uno::Reference< css::lang::XComponent > xDoc, css::uno::Reference< css::io::XOutputStream > &xOutputStream,    css::uno::Reference< css::task::XStatusIndicator> &xStatusIndicator );
-    bool exportSlides( css::uno::Reference< css::drawing::XDrawPage > xDrawPage, css::uno::Reference< css::io::XOutputStream > &xOutputStream, sal_uInt16 nPage);
-    sal_uInt16 exportBackgrounds( css::uno::Reference< css::drawing::XDrawPage > xDrawPage, css::uno::Reference< css::io::XOutputStream > &xOutputStream, sal_uInt16 nPage, bool bExportObjects );
+    bool exportAll( const css::uno::Reference< css::lang::XComponent >& xDoc, css::uno::Reference< css::io::XOutputStream > &xOutputStream,    css::uno::Reference< css::task::XStatusIndicator> &xStatusIndicator );
+    bool exportSlides( const css::uno::Reference< css::drawing::XDrawPage >& xDrawPage, css::uno::Reference< css::io::XOutputStream > &xOutputStream, sal_uInt16 nPage);
+    sal_uInt16 exportBackgrounds( const css::uno::Reference< css::drawing::XDrawPage >& xDrawPage, css::uno::Reference< css::io::XOutputStream > &xOutputStream, sal_uInt16 nPage, bool bExportObjects );
     sal_uInt16 exportBackgrounds( css::uno::Reference< css::drawing::XDrawPage > xDrawPage, sal_uInt16 nPage, bool bExportObjects );
 
     ChecksumCache gMasterCache;
diff --git a/filter/source/flash/swffilter.cxx b/filter/source/flash/swffilter.cxx
index 0976193..3fad7e5 100644
--- a/filter/source/flash/swffilter.cxx
+++ b/filter/source/flash/swffilter.cxx
@@ -186,7 +186,7 @@ FlashExportFilter::FlashExportFilter(const Reference< XComponentContext > &rxCon
 {
 }
 
-OUString exportBackground(FlashExporter &aFlashExporter, Reference< XDrawPage > xDrawPage, const OUString& sPath, sal_uInt32 nPage, const char* suffix)
+OUString exportBackground(FlashExporter &aFlashExporter, const Reference< XDrawPage >& xDrawPage, const OUString& sPath, sal_uInt32 nPage, const char* suffix)
 {
     OUString filename = STR("slide") + VAL(nPage+1) + STR(suffix) + STR(".swf");
     OUString fullpath = sPath + STR("/") + filename;
diff --git a/filter/source/msfilter/escherex.cxx b/filter/source/msfilter/escherex.cxx
index b51989e..cf6ce7a 100644
--- a/filter/source/msfilter/escherex.cxx
+++ b/filter/source/msfilter/escherex.cxx
@@ -1124,7 +1124,7 @@ void EscherPropertyContainer::CreateLineProperties(
     }
 }
 
-static Size lcl_SizeToEmu(Size aPrefSize, MapMode aPrefMapMode)
+static Size lcl_SizeToEmu(Size aPrefSize, const MapMode& aPrefMapMode)
 {
     Size aRetSize;
     if (aPrefMapMode == MAP_PIXEL)
diff --git a/filter/source/msfilter/msdffimp.cxx b/filter/source/msfilter/msdffimp.cxx
index c8fd4dc..29ae6d8 100644
--- a/filter/source/msfilter/msdffimp.cxx
+++ b/filter/source/msfilter/msdffimp.cxx
@@ -3691,7 +3691,7 @@ OUString SvxMSDffManager::MSDFFReadZString(SvStream& rIn,
     return comphelper::string::stripEnd(sBuf, 0);
 }
 
-static Size lcl_GetPrefSize(const Graphic& rGraf, MapMode aWanted)
+static Size lcl_GetPrefSize(const Graphic& rGraf, const MapMode& aWanted)
 {
     MapMode aPrefMapMode(rGraf.GetPrefMapMode());
     if (aPrefMapMode == aWanted)
diff --git a/filter/source/msfilter/svdfppt.cxx b/filter/source/msfilter/svdfppt.cxx
index ebea1c2..af3d57f 100644
--- a/filter/source/msfilter/svdfppt.cxx
+++ b/filter/source/msfilter/svdfppt.cxx
@@ -7343,7 +7343,7 @@ void GetLinePositions( const SdrObject* pObj, const std::set< sal_Int32 >& rRows
     }
 }
 
-void CreateTableRows( Reference< XTableRows > xTableRows, const std::set< sal_Int32 >& rRows, sal_Int32 nTableBottom )
+void CreateTableRows( const Reference< XTableRows >& xTableRows, const std::set< sal_Int32 >& rRows, sal_Int32 nTableBottom )
 {
     if ( rRows.size() > 1 )
         xTableRows->insertByIndex( 0, rRows.size() - 1 );
@@ -7367,7 +7367,7 @@ void CreateTableRows( Reference< XTableRows > xTableRows, const std::set< sal_In
     }
 }
 
-void CreateTableColumns( Reference< XTableColumns > xTableColumns, const std::set< sal_Int32 >& rColumns, sal_Int32 nTableRight )
+void CreateTableColumns( const Reference< XTableColumns >& xTableColumns, const std::set< sal_Int32 >& rColumns, sal_Int32 nTableRight )
 {
     if ( rColumns.size() > 1 )
         xTableColumns->insertByIndex( 0, rColumns.size() - 1 );
diff --git a/filter/source/placeware/exporter.cxx b/filter/source/placeware/exporter.cxx
index 6deaec9..fd6e84e 100644
--- a/filter/source/placeware/exporter.cxx
+++ b/filter/source/placeware/exporter.cxx
@@ -179,7 +179,7 @@ static OString convertString( const OUString& aInput )
     return aRet;
 }
 
-static void createSlideFile( Reference< XComponent > xDoc, PlacewareZipFile& rZipFile, const OUString& rURL, vector< PageEntry* >& rPageEntries  ) throw( css::uno::Exception, std::exception )
+static void createSlideFile( const Reference< XComponent >& xDoc, PlacewareZipFile& rZipFile, const OUString& rURL, vector< PageEntry* >& rPageEntries  ) throw( css::uno::Exception, std::exception )
 {
     OString aInfo;
 
@@ -282,8 +282,8 @@ static void createSlideFile( Reference< XComponent > xDoc, PlacewareZipFile& rZi
 
 //#define PLACEWARE_DEBUG 1
 
-bool PlaceWareExporter::doExport( Reference< XComponent > xDoc, Reference < XOutputStream > xOutputStream,
-                                        const OUString& rURL, Reference < XInterface > /* xHandler */, Reference < XStatusIndicator >& xStatusIndicator )
+bool PlaceWareExporter::doExport( const Reference< XComponent >& xDoc, Reference < XOutputStream > xOutputStream,
+                                  const OUString& rURL, const Reference < XInterface >& /* xHandler */, Reference < XStatusIndicator >& xStatusIndicator )
 {
     bool bRet = false;
 
diff --git a/filter/source/placeware/exporter.hxx b/filter/source/placeware/exporter.hxx
index c70bd7e..a855a97 100644
--- a/filter/source/placeware/exporter.hxx
+++ b/filter/source/placeware/exporter.hxx
@@ -35,10 +35,10 @@ public:
     explicit PlaceWareExporter( const css::uno::Reference< css::uno::XComponentContext >& rxContext );
     ~PlaceWareExporter();
 
-    bool doExport( css::uno::Reference< css::lang::XComponent > xDoc,
+    bool doExport( const css::uno::Reference< css::lang::XComponent >& xDoc,
                    css::uno::Reference < css::io::XOutputStream > xOutputStream,
                    const OUString& rURL,
-                   css::uno::Reference < css::uno::XInterface > xHandler,
+                   const css::uno::Reference < css::uno::XInterface >& xHandler,
                    css::uno::Reference < css::task::XStatusIndicator >& rxStatusIndicator );
 
 private:
diff --git a/filter/source/svg/svgexport.cxx b/filter/source/svg/svgexport.cxx
index 17a8828..c2a5354 100644
--- a/filter/source/svg/svgexport.cxx
+++ b/filter/source/svg/svgexport.cxx
@@ -118,7 +118,7 @@ public:
     {
         pSVGExport->AddAttribute( XML_NAMESPACE_NONE, "class", getClassName() );
     }
-    void insertMasterPage( Reference< XDrawPage> xMasterPage )
+    void insertMasterPage( const Reference< XDrawPage>& xMasterPage )
     {
         mMasterPageSet.insert( xMasterPage );
     }
@@ -907,7 +907,7 @@ template< typename TextFieldType >
 OUString implGenerateFieldId( std::vector< TextField* > & aFieldSet,
                               const TextFieldType & aField,
                               const OUString & sOOOElemField,
-                              Reference< XDrawPage > xMasterPage )
+                              const Reference< XDrawPage >& xMasterPage )
 {
     bool bFound = false;
     sal_Int32 i;
diff --git a/filter/source/svg/svgfilter.cxx b/filter/source/svg/svgfilter.cxx
index 503510a..2c5769e 100644
--- a/filter/source/svg/svgfilter.cxx
+++ b/filter/source/svg/svgfilter.cxx
@@ -304,7 +304,7 @@ void SAL_CALL SVGFilter::setTargetDocument( const Reference< XComponent >& xDoc
     mxDstDoc = xDoc;
 }
 
-bool SVGFilter::isStreamGZip(uno::Reference<io::XInputStream> xInput)
+bool SVGFilter::isStreamGZip(const uno::Reference<io::XInputStream>& xInput)
 {
     uno::Reference<io::XSeekable> xSeek(xInput, uno::UNO_QUERY);
     if(xSeek.is())
@@ -321,7 +321,7 @@ bool SVGFilter::isStreamGZip(uno::Reference<io::XInputStream> xInput)
     return false;
 }
 
-bool SVGFilter::isStreamSvg(uno::Reference<io::XInputStream> xInput)
+bool SVGFilter::isStreamSvg(const uno::Reference<io::XInputStream>& xInput)
 {
     uno::Reference<io::XSeekable> xSeek(xInput, uno::UNO_QUERY);
     if(xSeek.is())
diff --git a/filter/source/svg/svgfilter.hxx b/filter/source/svg/svgfilter.hxx
index 83417a6..0d4008c 100644
--- a/filter/source/svg/svgfilter.hxx
+++ b/filter/source/svg/svgfilter.hxx
@@ -289,8 +289,8 @@ private:
                                                                 const Reference< XPropertySetInfo > & rxPropSetInfo );
     DECL_LINK_TYPED( CalcFieldHdl, EditFieldInfo*, void );
 
-    static bool isStreamGZip(css::uno::Reference<css::io::XInputStream> xInput);
-    static bool isStreamSvg(css::uno::Reference<css::io::XInputStream> xInput);
+    static bool isStreamGZip(const css::uno::Reference<css::io::XInputStream>& xInput);
+    static bool isStreamSvg(const css::uno::Reference<css::io::XInputStream>& xInput);
 
 protected:
 
diff --git a/filter/source/xsltdialog/typedetectionexport.cxx b/filter/source/xsltdialog/typedetectionexport.cxx
index bb307e1..53446da 100644
--- a/filter/source/xsltdialog/typedetectionexport.cxx
+++ b/filter/source/xsltdialog/typedetectionexport.cxx
@@ -72,7 +72,7 @@ static OUString createRelativeURL( const OUString& rFilterName, const OUString&
     }
 }
 
-void TypeDetectionExporter::doExport( Reference< XOutputStream > xOS,  const XMLFilterVector& rFilters )
+void TypeDetectionExporter::doExport( const Reference< XOutputStream >& xOS,  const XMLFilterVector& rFilters )
 {
     try
     {
@@ -218,7 +218,7 @@ void TypeDetectionExporter::doExport( Reference< XOutputStream > xOS,  const XML
     }
 }
 
-void TypeDetectionExporter::addProperty( Reference< XWriter > xHandler, const OUString& rName, const OUString& rValue )
+void TypeDetectionExporter::addProperty( const Reference< XWriter >& xHandler, const OUString& rName, const OUString& rValue )
 {
     try
     {
@@ -248,7 +248,7 @@ void TypeDetectionExporter::addProperty( Reference< XWriter > xHandler, const OU
     }
 }
 
-void TypeDetectionExporter::addLocaleProperty( Reference< XWriter > xHandler, const OUString& rName, const OUString& rValue )
+void TypeDetectionExporter::addLocaleProperty( const Reference< XWriter >& xHandler, const OUString& rName, const OUString& rValue )
 {
     try
     {
diff --git a/filter/source/xsltdialog/typedetectionexport.hxx b/filter/source/xsltdialog/typedetectionexport.hxx
index dcb0ca0..7081a14 100644
--- a/filter/source/xsltdialog/typedetectionexport.hxx
+++ b/filter/source/xsltdialog/typedetectionexport.hxx
@@ -30,11 +30,11 @@ class TypeDetectionExporter
 public:
     explicit TypeDetectionExporter( css::uno::Reference< css::uno::XComponentContext >& mxContext );
 
-    void doExport(css::uno::Reference < css::io::XOutputStream > xOS,  const XMLFilterVector& rFilters );
+    void doExport(const css::uno::Reference < css::io::XOutputStream >& xOS,  const XMLFilterVector& rFilters );
 
 private:
-    static void addProperty( css::uno::Reference< css::xml::sax::XWriter > xWriter, const OUString& rName, const OUString& rValue );
-    static void addLocaleProperty( css::uno::Reference< css::xml::sax::XWriter > xWriter, const OUString& rName, const OUString& rValue );
+    static void addProperty( const css::uno::Reference< css::xml::sax::XWriter >& xWriter, const OUString& rName, const OUString& rValue );
+    static void addLocaleProperty( const css::uno::Reference< css::xml::sax::XWriter >& xWriter, const OUString& rName, const OUString& rValue );
 
     css::uno::Reference< css::uno::XComponentContext > mxContext;
 };
diff --git a/filter/source/xsltdialog/typedetectionimport.cxx b/filter/source/xsltdialog/typedetectionimport.cxx
index 0865121..fbe10b5 100644
--- a/filter/source/xsltdialog/typedetectionimport.cxx
+++ b/filter/source/xsltdialog/typedetectionimport.cxx
@@ -47,7 +47,7 @@ TypeDetectionImporter::~TypeDetectionImporter()
 {
 }
 
-void TypeDetectionImporter::doImport( const Reference< XComponentContext >& rxContext, Reference< XInputStream > xIS, XMLFilterVector& rFilters )
+void TypeDetectionImporter::doImport( const Reference< XComponentContext >& rxContext, const Reference< XInputStream >& xIS, XMLFilterVector& rFilters )
 {
     try
     {
diff --git a/filter/source/xsltdialog/typedetectionimport.hxx b/filter/source/xsltdialog/typedetectionimport.hxx
index 9d2be2d..ccdcd6d 100644
--- a/filter/source/xsltdialog/typedetectionimport.hxx
+++ b/filter/source/xsltdialog/typedetectionimport.hxx
@@ -64,7 +64,7 @@ public:
     TypeDetectionImporter();
     virtual ~TypeDetectionImporter();
 
-    static void doImport( const css::uno::Reference< css::uno::XComponentContext >& rxContext, css::uno::Reference < css::io::XInputStream > xOS, XMLFilterVector& rFilters );
+    static void doImport( const css::uno::Reference< css::uno::XComponentContext >& rxContext, const css::uno::Reference < css::io::XInputStream >& xOS, XMLFilterVector& rFilters );
 
     virtual void SAL_CALL startDocument(  )
         throw(css::xml::sax::SAXException, css::uno::RuntimeException, std::exception) override;
diff --git a/filter/source/xsltdialog/xmlfiltercommon.hxx b/filter/source/xsltdialog/xmlfiltercommon.hxx
index 7a73ba8..952cd1e 100644
--- a/filter/source/xsltdialog/xmlfiltercommon.hxx
+++ b/filter/source/xsltdialog/xmlfiltercommon.hxx
@@ -32,7 +32,7 @@
 extern OUString string_encode( const OUString & rText );
 extern OUString string_decode( const OUString & rText );
 
-bool copyStreams( css::uno::Reference< css::io::XInputStream > xIS, css::uno::Reference< css::io::XOutputStream > xOS );
+bool copyStreams( const css::uno::Reference< css::io::XInputStream >& xIS, const css::uno::Reference< css::io::XOutputStream >& xOS );
 bool createDirectory( OUString& rURL );
 
 
diff --git a/filter/source/xsltdialog/xmlfilterjar.cxx b/filter/source/xsltdialog/xmlfilterjar.cxx
index f5a44eb..effc2fb 100644
--- a/filter/source/xsltdialog/xmlfilterjar.cxx
+++ b/filter/source/xsltdialog/xmlfilterjar.cxx
@@ -303,7 +303,7 @@ void XMLFilterJarHelper::openPackage( const OUString& rPackageURL, XMLFilterVect
     }
 }
 
-bool XMLFilterJarHelper::copyFiles( Reference< XHierarchicalNameAccess > xIfc, filter_info_impl* pFilter )
+bool XMLFilterJarHelper::copyFiles( const Reference< XHierarchicalNameAccess >& xIfc, filter_info_impl* pFilter )
 {
     bool bOk = copyFile( xIfc, pFilter->maExportXSLT, sXSLTPath );
 
@@ -316,7 +316,7 @@ bool XMLFilterJarHelper::copyFiles( Reference< XHierarchicalNameAccess > xIfc, f
     return bOk;
 }
 
-bool XMLFilterJarHelper::copyFile( Reference< XHierarchicalNameAccess > xIfc, OUString& rURL, const OUString& rTargetURL )
+bool XMLFilterJarHelper::copyFile( const Reference< XHierarchicalNameAccess >& xIfc, OUString& rURL, const OUString& rTargetURL )
 {
     if( !rURL.matchIgnoreAsciiCase( sVndSunStarPackage ) )
         return true;
diff --git a/filter/source/xsltdialog/xmlfilterjar.hxx b/filter/source/xsltdialog/xmlfilterjar.hxx
index 0da990e..4a57ce8 100644
--- a/filter/source/xsltdialog/xmlfilterjar.hxx
+++ b/filter/source/xsltdialog/xmlfilterjar.hxx
@@ -40,8 +40,8 @@ public:
 private:
     void addFile( css::uno::Reference< css::uno::XInterface > xRootFolder, css::uno::Reference< css::lang::XSingleServiceFactory > xFactory, const OUString& rSourceFile ) throw( css::uno::Exception, std::exception );
 
-    bool copyFile( css::uno::Reference< css::container::XHierarchicalNameAccess > xIfc, OUString& rURL, const OUString& rTargetURL );
-    bool copyFiles( css::uno::Reference< css::container::XHierarchicalNameAccess > xIfc, filter_info_impl* pFilter );
+    bool copyFile( const css::uno::Reference< css::container::XHierarchicalNameAccess >& xIfc, OUString& rURL, const OUString& rTargetURL );
+    bool copyFiles( const css::uno::Reference< css::container::XHierarchicalNameAccess >& xIfc, filter_info_impl* pFilter );
 
     css::uno::Reference< css::uno::XComponentContext > mxContext;
 
diff --git a/filter/source/xsltdialog/xmlfiltersettingsdialog.cxx b/filter/source/xsltdialog/xmlfiltersettingsdialog.cxx
index 60e0847..8583483 100644
--- a/filter/source/xsltdialog/xmlfiltersettingsdialog.cxx
+++ b/filter/source/xsltdialog/xmlfiltersettingsdialog.cxx
@@ -1617,7 +1617,7 @@ OUString string_decode( const OUString & rText )
     return Uri::decode( rText, rtl_UriDecodeWithCharset, RTL_TEXTENCODING_UTF8 );
 }
 
-bool copyStreams( Reference< XInputStream > xIS, Reference< XOutputStream > xOS )
+bool copyStreams( const Reference< XInputStream >& xIS, const Reference< XOutputStream >& xOS )
 {
     try
     {
diff --git a/filter/source/xsltdialog/xmlfiltertestdialog.cxx b/filter/source/xsltdialog/xmlfiltertestdialog.cxx
index 613ada3..8262449 100644
--- a/filter/source/xsltdialog/xmlfiltertestdialog.cxx
+++ b/filter/source/xsltdialog/xmlfiltertestdialog.cxx
@@ -441,7 +441,7 @@ void XMLFilterTestDialog::onExportCurrentDocument()
     doExport( getFrontMostDocument( m_pFilterInfo->maDocumentService ) );
 }
 
-void XMLFilterTestDialog::doExport( Reference< XComponent > xComp )
+void XMLFilterTestDialog::doExport( const Reference< XComponent >& xComp )
 {
     try
     {
diff --git a/filter/source/xsltdialog/xmlfiltertestdialog.hxx b/filter/source/xsltdialog/xmlfiltertestdialog.hxx
index 09998d0..39261c4 100644
--- a/filter/source/xsltdialog/xmlfiltertestdialog.hxx
+++ b/filter/source/xsltdialog/xmlfiltertestdialog.hxx
@@ -55,7 +55,7 @@ private:
     css::uno::Reference< css::lang::XComponent > getFrontMostDocument( const OUString& rServiceName );
     void import( const OUString& rURL );
     static void displayXMLFile( const OUString& rURL );
-    void doExport( css::uno::Reference< css::lang::XComponent > xComp );
+    void doExport( const css::uno::Reference< css::lang::XComponent >& xComp );
 
 private:
     css::uno::Reference< css::uno::XComponentContext >              mxContext;
commit dbd1f4b75a22150af80a6fbd8de1a38d5dc4b4c3
Author: Noel Grandin <noel at peralex.com>
Date:   Tue Apr 12 11:16:51 2016 +0200

    clang-tidy performance-unnecessary-value-param in dbaccess
    
    Change-Id: I9cec61867b4e6e8abde7749047974c6de87b9669

diff --git a/dbaccess/source/core/api/BookmarkSet.cxx b/dbaccess/source/core/api/BookmarkSet.cxx
index faca631..d3869e0 100644
--- a/dbaccess/source/core/api/BookmarkSet.cxx
+++ b/dbaccess/source/core/api/BookmarkSet.cxx
@@ -131,7 +131,7 @@ void OBookmarkSet::fillValueRow(ORowSetRow& _rRow,sal_Int32 _nPosition)
     OCacheSet::fillValueRow(_rRow,_nPosition);
 }
 
-void OBookmarkSet::updateColumn(sal_Int32 nPos,Reference< XRowUpdate > _xParameter,const ORowSetValue& _rValue)
+void OBookmarkSet::updateColumn(sal_Int32 nPos, const Reference< XRowUpdate >& _xParameter, const ORowSetValue& _rValue)
 {
     if(_rValue.isBound() && _rValue.isModified())
     {
diff --git a/dbaccess/source/core/api/BookmarkSet.hxx b/dbaccess/source/core/api/BookmarkSet.hxx
index a4b11c2..6a1c007 100644
--- a/dbaccess/source/core/api/BookmarkSet.hxx
+++ b/dbaccess/source/core/api/BookmarkSet.hxx
@@ -30,7 +30,7 @@ namespace dbaccess
     {
         css::uno::Reference< css::sdbcx::XRowLocate> m_xRowLocate;
 
-        void updateColumn(sal_Int32 nPos,css::uno::Reference< css::sdbc::XRowUpdate > _xParameter,const connectivity::ORowSetValue& _rValue);
+        void updateColumn(sal_Int32 nPos, const css::uno::Reference< css::sdbc::XRowUpdate >& _xParameter, const connectivity::ORowSetValue& _rValue);
     public:
         explicit OBookmarkSet(sal_Int32 i_nMaxRows) : OCacheSet(i_nMaxRows)
         {}
diff --git a/dbaccess/source/core/api/SingleSelectQueryComposer.cxx b/dbaccess/source/core/api/SingleSelectQueryComposer.cxx
index 622d86b..3f80fc8 100644
--- a/dbaccess/source/core/api/SingleSelectQueryComposer.cxx
+++ b/dbaccess/source/core/api/SingleSelectQueryComposer.cxx
@@ -154,7 +154,7 @@ namespace
     /** transforms a parse node describing a complete statement into a pure select
         statement, without any filter/order/groupby/having clauses
     */
-    OUString getPureSelectStatement( const OSQLParseNode* _pRootNode, Reference< XConnection > _rxConnection )
+    OUString getPureSelectStatement( const OSQLParseNode* _pRootNode, const Reference< XConnection >& _rxConnection )
     {
         OUString sSQL = STR_SELECT;
         _pRootNode->getChild(1)->parseNodeToStr( sSQL, _rxConnection );
diff --git a/dbaccess/source/core/api/WrappedResultSet.cxx b/dbaccess/source/core/api/WrappedResultSet.cxx
index d9659a1..86c0d4f 100644
--- a/dbaccess/source/core/api/WrappedResultSet.cxx
+++ b/dbaccess/source/core/api/WrappedResultSet.cxx
@@ -115,7 +115,7 @@ void WrappedResultSet::fillValueRow(ORowSetRow& _rRow,sal_Int32 _nPosition)
     OCacheSet::fillValueRow(_rRow,_nPosition);
 }
 
-void WrappedResultSet::updateColumn(sal_Int32 nPos,Reference< XRowUpdate > _xParameter,const ORowSetValue& _rValue)
+void WrappedResultSet::updateColumn(sal_Int32 nPos, const Reference< XRowUpdate >& _xParameter, const ORowSetValue& _rValue)
 {
     if(_rValue.isBound() && _rValue.isModified())
     {
diff --git a/dbaccess/source/core/api/WrappedResultSet.hxx b/dbaccess/source/core/api/WrappedResultSet.hxx
index 8e458e4..db76925 100644
--- a/dbaccess/source/core/api/WrappedResultSet.hxx
+++ b/dbaccess/source/core/api/WrappedResultSet.hxx
@@ -33,7 +33,7 @@ namespace dbaccess
         css::uno::Reference< css::sdbc::XResultSetUpdate> m_xUpd;
         css::uno::Reference< css::sdbc::XRowUpdate>       m_xUpdRow;
 
-        void updateColumn(sal_Int32 nPos, css::uno::Reference< css::sdbc::XRowUpdate > _xParameter,const connectivity::ORowSetValue& _rValue);
+        void updateColumn(sal_Int32 nPos, const css::uno::Reference< css::sdbc::XRowUpdate >& _xParameter, const connectivity::ORowSetValue& _rValue);
     public:
         explicit WrappedResultSet(sal_Int32 i_nMaxRows) : OCacheSet(i_nMaxRows)
         {}
diff --git a/dbaccess/source/core/dataaccess/definitioncontainer.cxx b/dbaccess/source/core/dataaccess/definitioncontainer.cxx
index 16cedbb..a8b2d4fe 100644
--- a/dbaccess/source/core/dataaccess/definitioncontainer.cxx
+++ b/dbaccess/source/core/dataaccess/definitioncontainer.cxx
@@ -53,14 +53,14 @@ namespace dbaccess
 {
 
 // ODefinitionContainer_Impl
-void ODefinitionContainer_Impl::erase( TContentPtr _pDefinition )
+void ODefinitionContainer_Impl::erase( const TContentPtr& _pDefinition )
 {
     NamedDefinitions::const_iterator aPos = find( _pDefinition );
     if ( aPos != end() )
         m_aDefinitions.erase( aPos );
 }
 
-ODefinitionContainer_Impl::const_iterator ODefinitionContainer_Impl::find( TContentPtr _pDefinition ) const
+ODefinitionContainer_Impl::const_iterator ODefinitionContainer_Impl::find( const TContentPtr& _pDefinition ) const
 {
     return ::std::find_if(
         m_aDefinitions.begin(),
@@ -70,7 +70,7 @@ ODefinitionContainer_Impl::const_iterator ODefinitionContainer_Impl::find( TCont
         });
 }
 
-ODefinitionContainer_Impl::iterator ODefinitionContainer_Impl::find( TContentPtr _pDefinition )
+ODefinitionContainer_Impl::iterator ODefinitionContainer_Impl::find( const TContentPtr& _pDefinition )
 {
     return ::std::find_if(
         m_aDefinitions.begin(),
diff --git a/dbaccess/source/core/inc/definitioncontainer.hxx b/dbaccess/source/core/inc/definitioncontainer.hxx
index bdefec3..eaa1b0d 100644
--- a/dbaccess/source/core/inc/definitioncontainer.hxx
+++ b/dbaccess/source/core/inc/definitioncontainer.hxx
@@ -64,10 +64,10 @@ public:
     inline const_iterator end() const     { return m_aDefinitions.end(); }
 
     inline const_iterator find( const OUString& _rName ) const { return m_aDefinitions.find( _rName ); }
-           const_iterator find( TContentPtr _pDefinition ) const;
+           const_iterator find( const TContentPtr& _pDefinition ) const;
 
     inline void erase( const OUString& _rName ) { m_aDefinitions.erase( _rName ); }
-    void erase( TContentPtr _pDefinition );
+    void erase( const TContentPtr& _pDefinition );
 
     inline void insert( const OUString& _rName, TContentPtr _pDefinition )
     {
@@ -75,7 +75,7 @@ public:
     }
 
 private:
-    iterator find( TContentPtr _pDefinition );
+    iterator find( const TContentPtr& _pDefinition );
         // (for the moment, this is private. Make it public if needed. If really needed.)
 };
 
diff --git a/dbaccess/source/filter/xml/xmlfilter.cxx b/dbaccess/source/filter/xml/xmlfilter.cxx
index a9ebf6c..1c12a46 100644
--- a/dbaccess/source/filter/xml/xmlfilter.cxx
+++ b/dbaccess/source/filter/xml/xmlfilter.cxx
@@ -140,7 +140,7 @@ sal_Int32 ReadThroughComponent(
 
 /// read a component (storage version)
 sal_Int32 ReadThroughComponent(
-    uno::Reference< embed::XStorage > xStorage,
+    const uno::Reference< embed::XStorage >& xStorage,
     const uno::Reference<XComponent>& xModelComponent,
     const sal_Char* pStreamName,
     const sal_Char* pCompatibilityStreamName,
diff --git a/dbaccess/source/ui/dlg/DbAdminImpl.cxx b/dbaccess/source/ui/dlg/DbAdminImpl.cxx
index 22ca33f..fe14de0 100644
--- a/dbaccess/source/ui/dlg/DbAdminImpl.cxx
+++ b/dbaccess/source/ui/dlg/DbAdminImpl.cxx
@@ -90,7 +90,7 @@ using namespace com::sun::star::frame;
 
 namespace
 {
-    bool implCheckItemType( SfxItemSet& _rSet, const sal_uInt16 _nId, std::function<bool ( const SfxPoolItem* )> isItemType )
+    bool implCheckItemType( SfxItemSet& _rSet, const sal_uInt16 _nId, const std::function<bool ( const SfxPoolItem* )>& isItemType )
     {
         bool bCorrectType = false;
 
diff --git a/dbaccess/source/ui/inc/FieldDescriptions.hxx b/dbaccess/source/ui/inc/FieldDescriptions.hxx
index 8144a44..e6128c1 100644
--- a/dbaccess/source/ui/inc/FieldDescriptions.hxx
+++ b/dbaccess/source/ui/inc/FieldDescriptions.hxx
@@ -71,7 +71,7 @@ namespace dbaui
         void SetDefaultValue(const css::uno::Any& _rDefaultValue);
         void SetControlDefault(const css::uno::Any& _rControlDefault);
         void SetAutoIncrementValue(const OUString& _sAutoIncValue);
-        void SetType(TOTypeInfoSP _pType);
+        void SetType(const TOTypeInfoSP& _pType);
         void SetTypeValue(sal_Int32 _nType);
         void SetTypeName(const OUString& _sTypeName);
         void SetPrecision(const sal_Int32& _rPrecision);
diff --git a/dbaccess/source/ui/inc/QueryDesignView.hxx b/dbaccess/source/ui/inc/QueryDesignView.hxx
index 743b33d..67f8f8e 100644
--- a/dbaccess/source/ui/inc/QueryDesignView.hxx
+++ b/dbaccess/source/ui/inc/QueryDesignView.hxx
@@ -140,7 +140,7 @@ namespace dbaui
                     const css::uno::Sequence< css::beans::PropertyValue >& i_rFieldDescriptions
                 );
 
-        ::connectivity::OSQLParseNode* getPredicateTreeFromEntry(   OTableFieldDescRef pEntry,
+        ::connectivity::OSQLParseNode* getPredicateTreeFromEntry(   const OTableFieldDescRef& pEntry,
                                                                     const OUString& _sCriteria,
                                                                     OUString& _rsErrorMessage,
                                                                     css::uno::Reference< css::beans::XPropertySet>& _rxColumn) const;
diff --git a/dbaccess/source/ui/inc/UITools.hxx b/dbaccess/source/ui/inc/UITools.hxx
index 7964c79..0340ca2 100644
--- a/dbaccess/source/ui/inc/UITools.hxx
+++ b/dbaccess/source/ui/inc/UITools.hxx
@@ -166,7 +166,7 @@ namespace dbaui
         getDataSourceByName(
                 const OUString& _rDataSourceName,
                 vcl::Window* _pErrorMessageParent,
-                css::uno::Reference< css::uno::XComponentContext > _rxContext,
+                const css::uno::Reference< css::uno::XComponentContext >& _rxContext,
                 ::dbtools::SQLExceptionInfo* _pErrorInfo
             );
 
diff --git a/dbaccess/source/ui/inc/indexcollection.hxx b/dbaccess/source/ui/inc/indexcollection.hxx
index baa39afd..7dbbae4 100644
--- a/dbaccess/source/ui/inc/indexcollection.hxx
+++ b/dbaccess/source/ui/inc/indexcollection.hxx
@@ -87,7 +87,7 @@ namespace dbaui
 
     protected:
         void implConstructFrom(const css::uno::Reference< css::container::XNameAccess >& _rxIndexes);
-        static void implFillIndexInfo(OIndex& _rIndex, css::uno::Reference< css::beans::XPropertySet > _rxDescriptor);
+        static void implFillIndexInfo(OIndex& _rIndex, const css::uno::Reference< css::beans::XPropertySet >& _rxDescriptor);
         void implFillIndexInfo(OIndex& _rIndex);
     };
 
diff --git a/dbaccess/source/ui/misc/UITools.cxx b/dbaccess/source/ui/misc/UITools.cxx
index 22c2abf..0079841 100644
--- a/dbaccess/source/ui/misc/UITools.cxx
+++ b/dbaccess/source/ui/misc/UITools.cxx
@@ -209,7 +209,7 @@ SQLExceptionInfo createConnection(  const Reference< css::beans::XPropertySet>&
 }
 
 Reference< XDataSource > getDataSourceByName( const OUString& _rDataSourceName,
-    vcl::Window* _pErrorMessageParent, Reference< XComponentContext > _rxContext, ::dbtools::SQLExceptionInfo* _pErrorInfo )
+    vcl::Window* _pErrorMessageParent, const Reference< XComponentContext >& _rxContext, ::dbtools::SQLExceptionInfo* _pErrorInfo )
 {
     Reference< XDatabaseContext > xDatabaseContext = DatabaseContext::create(_rxContext);
 
diff --git a/dbaccess/source/ui/misc/indexcollection.cxx b/dbaccess/source/ui/misc/indexcollection.cxx
index c7a07ac..94790d3 100644
--- a/dbaccess/source/ui/misc/indexcollection.cxx
+++ b/dbaccess/source/ui/misc/indexcollection.cxx
@@ -250,7 +250,7 @@ namespace dbaui
             implFillIndexInfo(_rIndex, xIndex);
     }
 
-    void OIndexCollection::implFillIndexInfo(OIndex& _rIndex, Reference< XPropertySet > _rxDescriptor)
+    void OIndexCollection::implFillIndexInfo(OIndex& _rIndex, const Reference< XPropertySet >& _rxDescriptor)
     {
         static const char s_sPrimaryIndexPropertyName[] = "IsPrimaryKeyIndex";
         static const char s_sUniquePropertyName[] = "IsUnique";
diff --git a/dbaccess/source/ui/querydesign/QueryDesignView.cxx b/dbaccess/source/ui/querydesign/QueryDesignView.cxx
index 0e7271f..8d88ec3 100644
--- a/dbaccess/source/ui/querydesign/QueryDesignView.cxx
+++ b/dbaccess/source/ui/querydesign/QueryDesignView.cxx
@@ -124,7 +124,7 @@ namespace
         }
         return sTableRange;
     }
-    void insertConnection(const OQueryDesignView* _pView,const EJoinType& _eJoinType,OTableFieldDescRef _aDragLeft,OTableFieldDescRef _aDragRight,bool _bNatural = false)
+    void insertConnection(const OQueryDesignView* _pView,const EJoinType& _eJoinType, const OTableFieldDescRef& _aDragLeft, const OTableFieldDescRef& _aDragRight, bool _bNatural = false)
     {
         OQueryTableView* pTableView = static_cast<OQueryTableView*>(_pView->getTableView());
         OQueryTableConnection* pConn = static_cast<OQueryTableConnection*>( pTableView->GetTabConn(static_cast<OTableWindow*>(_aDragLeft->GetTabWindow()),static_cast<OTableWindow*>(_aDragRight->GetTabWindow()),true));
@@ -2998,7 +2998,7 @@ void OQueryDesignView::SaveUIConfig()
         rCtrl.setSplitPos( m_aSplitter->GetSplitPosPixel() );
 }
 
-OSQLParseNode* OQueryDesignView::getPredicateTreeFromEntry(OTableFieldDescRef pEntry,
+OSQLParseNode* OQueryDesignView::getPredicateTreeFromEntry(const OTableFieldDescRef& pEntry,
                                                            const OUString& _sCriteria,
                                                            OUString& _rsErrorMessage,
                                                            Reference<XPropertySet>& _rxColumn) const
diff --git a/dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx b/dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx
index 2348389..a35cdc4 100644
--- a/dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx
+++ b/dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx
@@ -1473,7 +1473,7 @@ Rectangle OSelectionBrowseBox::GetInvalidRect( sal_uInt16 nColId )
     return aInvalidRect;
 }
 
-void OSelectionBrowseBox::InsertColumn(OTableFieldDescRef pEntry, sal_uInt16& _nColumnPosition)
+void OSelectionBrowseBox::InsertColumn(const OTableFieldDescRef& pEntry, sal_uInt16& _nColumnPosition)
 {
     // the control should have exactly one more column: the HandleColumn
     OSL_ENSURE(_nColumnPosition == BROWSER_INVALIDID || (_nColumnPosition <= (long)getFields().size()), "OSelectionBrowseBox::InsertColumn : invalid parameter nColId.");
diff --git a/dbaccess/source/ui/querydesign/SelectionBrowseBox.hxx b/dbaccess/source/ui/querydesign/SelectionBrowseBox.hxx
index c482bc4..ea2e827 100644
--- a/dbaccess/source/ui/querydesign/SelectionBrowseBox.hxx
+++ b/dbaccess/source/ui/querydesign/SelectionBrowseBox.hxx
@@ -84,7 +84,7 @@ namespace dbaui
         void                        initialize();
         OTableFieldDescRef          InsertField( const OJoinExchangeData& jxdSource );
         OTableFieldDescRef          InsertField( const OTableFieldDescRef& rInfo, sal_uInt16 _nColumnPosition = BROWSER_INVALIDID, bool bVis=true, bool bActivate=true );
-        void                        InsertColumn( OTableFieldDescRef pEntry, sal_uInt16& _nColumnPosition );
+        void                        InsertColumn( const OTableFieldDescRef& pEntry, sal_uInt16& _nColumnPosition );
         void                        RemoveColumn( sal_uInt16 _nColumnId );
         void                        DeleteFields( const OUString& rAliasName );
 
diff --git a/dbaccess/source/ui/tabledesign/FieldDescriptions.cxx b/dbaccess/source/ui/tabledesign/FieldDescriptions.cxx
index 9763f63..7b92318 100644
--- a/dbaccess/source/ui/tabledesign/FieldDescriptions.cxx
+++ b/dbaccess/source/ui/tabledesign/FieldDescriptions.cxx
@@ -326,7 +326,7 @@ void OFieldDescription::SetAutoIncrementValue(const OUString& _sAutoIncValue)
     }
 }
 
-void OFieldDescription::SetType(TOTypeInfoSP _pType)
+void OFieldDescription::SetType(const TOTypeInfoSP& _pType)
 {
     m_pType = _pType;
     if ( m_pType.get() )
commit f520af173500bc2a0c35e20e96353a5e2305bb63
Author: Noel Grandin <noel at peralex.com>
Date:   Tue Apr 12 11:02:36 2016 +0200

    clang-tidy performance-unnecessary-value-param in cui
    
    Change-Id: I93a09bf8e475ec1aa2ebf7754c7048c81696922b

diff --git a/cui/source/customize/cfg.cxx b/cui/source/customize/cfg.cxx
index d89f288..8f5c1c4 100644
--- a/cui/source/customize/cfg.cxx
+++ b/cui/source/customize/cfg.cxx
@@ -3711,7 +3711,7 @@ ToolbarSaveInData::~ToolbarSaveInData()
 }
 
 void ToolbarSaveInData::SetSystemStyle(
-    uno::Reference< frame::XFrame > xFrame,
+    const uno::Reference< frame::XFrame >& xFrame,
     const OUString& rResourceURL,
     sal_Int32 nStyle )
 {
diff --git a/cui/source/customize/cfgutil.cxx b/cui/source/customize/cfgutil.cxx
index 7120d23..2cdbfba 100644
--- a/cui/source/customize/cfgutil.cxx
+++ b/cui/source/customize/cfgutil.cxx
@@ -700,7 +700,7 @@ void SfxConfigGroupListBox::Init(const css::uno::Reference< css::uno::XComponent
 }
 
 Image SfxConfigGroupListBox::GetImage(
-    Reference< browse::XBrowseNode > node,
+    const Reference< browse::XBrowseNode >& node,
     Reference< XComponentContext > xCtx,
     bool bIsRootNode
 )
diff --git a/cui/source/customize/macropg.cxx b/cui/source/customize/macropg.cxx
index 6e7c2de..efffa67 100644
--- a/cui/source/customize/macropg.cxx
+++ b/cui/source/customize/macropg.cxx
@@ -712,7 +712,7 @@ long _SvxMacroTabPage::GenericHandler_Impl( _SvxMacroTabPage* pThis, PushButton*
 
 // pass in the XNameReplace.
 // can remove the 3rd arg once issue ?? is fixed
-void _SvxMacroTabPage::InitAndSetHandler( Reference< container::XNameReplace> xAppEvents, Reference< container::XNameReplace> xDocEvents, Reference< util::XModifiable > xModifiable )
+void _SvxMacroTabPage::InitAndSetHandler( const Reference< container::XNameReplace>& xAppEvents, const Reference< container::XNameReplace>& xDocEvents, const Reference< util::XModifiable >& xModifiable )
 {
     m_xAppEvents = xAppEvents;
     m_xDocEvents = xDocEvents;
@@ -799,7 +799,7 @@ Any _SvxMacroTabPage::GetPropsByName( const OUString& eventName, EventsHash& eve
 
 // converts the Any returned by GetByName into a pair which can be stored in
 // the EventHash
-::std::pair< OUString, OUString  > _SvxMacroTabPage::GetPairFromAny( Any aAny )
+::std::pair< OUString, OUString  > _SvxMacroTabPage::GetPairFromAny( const Any& aAny )
 {
     Sequence< beans::PropertyValue > props;
     OUString type, url;
diff --git a/cui/source/customize/selector.cxx b/cui/source/customize/selector.cxx
index 01d4f42..eba339d 100644
--- a/cui/source/customize/selector.cxx
+++ b/cui/source/customize/selector.cxx
@@ -555,7 +555,7 @@ void SvxConfigGroupListBox::Init(bool bShowSlots, const Reference< frame::XFrame
 }
 
 Image SvxConfigGroupListBox::GetImage(
-    Reference< browse::XBrowseNode > node,
+    const Reference< browse::XBrowseNode >& node,
     Reference< XComponentContext > xCtx,
     bool bIsRootNode
 )
diff --git a/cui/source/dialogs/SpellDialog.cxx b/cui/source/dialogs/SpellDialog.cxx
index 0a5815f..75a14c8 100644
--- a/cui/source/dialogs/SpellDialog.cxx
+++ b/cui/source/dialogs/SpellDialog.cxx
@@ -144,7 +144,7 @@ public:
     void                    SetErrorLanguageSelected(bool bSet){ m_bIsErrorLanguageSelected = bSet;}
     bool                    IsErrorLanguageSelected() const {return m_bIsErrorLanguageSelected;}
 
-    void                    SetDictionary(Reference<XDictionary> xDict) { m_xDictionary = xDict; }
+    void                    SetDictionary(const Reference<XDictionary>& xDict) { m_xDictionary = xDict; }
     Reference<XDictionary>  GetDictionary() const {return m_xDictionary;}
     void                    SetAddedWord(const OUString& rWord) {m_sAddedWord = rWord;}
     const OUString&         GetAddedWord() const { return m_sAddedWord;}
@@ -1580,7 +1580,7 @@ void SentenceEditWindow_Impl::dispose()
     VclMultiLineEdit::dispose();
 }
 
-bool SentenceEditWindow_Impl::MarkNextError( bool bIgnoreCurrentError, css::uno::Reference<css::linguistic2::XSpellChecker1> xSpell )
+bool SentenceEditWindow_Impl::MarkNextError( bool bIgnoreCurrentError, const css::uno::Reference<css::linguistic2::XSpellChecker1>& xSpell )
 {
     if (bIgnoreCurrentError)
         m_aIgnoreErrorsAt.insert( m_nErrorStart );
@@ -1775,7 +1775,7 @@ void SentenceEditWindow_Impl::RestoreCurrentError()
 }
 
 
-void SentenceEditWindow_Impl::SetAlternatives( Reference< XSpellAlternatives> xAlt )
+void SentenceEditWindow_Impl::SetAlternatives( const Reference< XSpellAlternatives>& xAlt )
 {
     TextPaM aCursor(0, m_nErrorStart);
     DBG_ASSERT(static_cast<const SpellErrorAttrib*>(
diff --git a/cui/source/dialogs/hangulhanjadlg.cxx b/cui/source/dialogs/hangulhanjadlg.cxx
index a073dfa..2e600ab 100644
--- a/cui/source/dialogs/hangulhanjadlg.cxx
+++ b/cui/source/dialogs/hangulhanjadlg.cxx
@@ -1465,7 +1465,7 @@ namespace svx
 
     namespace
     {
-        bool GetConversions(    Reference< XConversionDictionary >  _xDict,
+        bool GetConversions(    const Reference< XConversionDictionary >&  _xDict,
                                 const OUString& _rOrg,
                                 Sequence< OUString >& _rEntries )
         {
diff --git a/cui/source/dialogs/hlmarkwn.cxx b/cui/source/dialogs/hlmarkwn.cxx
index 10f8ead..96e2a04 100644
--- a/cui/source/dialogs/hlmarkwn.cxx
+++ b/cui/source/dialogs/hlmarkwn.cxx
@@ -396,7 +396,7 @@ bool SvxHlinkDlgMarkWnd::RefreshFromDoc(const OUString& aURL)
 |*
 |************************************************************************/
 
-int SvxHlinkDlgMarkWnd::FillTree( uno::Reference< container::XNameAccess > xLinks, SvTreeListEntry* pParentEntry )
+int SvxHlinkDlgMarkWnd::FillTree( const uno::Reference< container::XNameAccess >& xLinks, SvTreeListEntry* pParentEntry )
 {
     int nEntries=0;
     const uno::Sequence< OUString > aNames( xLinks->getElementNames() );
diff --git a/cui/source/dialogs/scriptdlg.cxx b/cui/source/dialogs/scriptdlg.cxx
index 0e85986..01dbaaa 100644
--- a/cui/source/dialogs/scriptdlg.cxx
+++ b/cui/source/dialogs/scriptdlg.cxx
@@ -1140,7 +1140,7 @@ bool SvxScriptOrgDialog::getBoolProperty( Reference< beans::XPropertySet >& xPro
     return result;
 }
 
-OUString SvxScriptOrgDialog::getListOfChildren( Reference< browse::XBrowseNode > node, int depth )
+OUString SvxScriptOrgDialog::getListOfChildren( const Reference< browse::XBrowseNode >& node, int depth )
 {
     OUString result = "\n";
     for( int i=0;i<=depth;i++ )
diff --git a/cui/source/inc/SpellDialog.hxx b/cui/source/inc/SpellDialog.hxx
index e0ad793..595035d 100644
--- a/cui/source/inc/SpellDialog.hxx
+++ b/cui/source/inc/SpellDialog.hxx
@@ -88,14 +88,14 @@ public:
     void            SetAttrib( const TextAttrib& rAttr, sal_uLong nPara, sal_uInt16 nStart, sal_uInt16 nEnd );
     void            SetText( const OUString& rStr ) override;
 
-    bool            MarkNextError( bool bIgnoreCurrentError, css::uno::Reference<css::linguistic2::XSpellChecker1> );
+    bool            MarkNextError( bool bIgnoreCurrentError, const css::uno::Reference<css::linguistic2::XSpellChecker1>& );
     void            ChangeMarkedWord(const OUString& rNewWord, LanguageType eLanguage);
     void            MoveErrorMarkTo(sal_uInt16 nErrorStart, sal_uInt16 nErrorEnd, bool bGrammar);
     OUString        GetErrorText() const;
     void            RestoreCurrentError();
 
     void            SetAlternatives(
-                        css::uno::Reference<css::linguistic2::XSpellAlternatives> );
+                        const css::uno::Reference<css::linguistic2::XSpellAlternatives>& );
 
     const SpellErrorDescription* GetAlternatives();
 
diff --git a/cui/source/inc/cfg.hxx b/cui/source/inc/cfg.hxx
index 104f2e5..acbdc90 100644
--- a/cui/source/inc/cfg.hxx
+++ b/cui/source/inc/cfg.hxx
@@ -635,7 +635,7 @@ public:
     void            SetSystemStyle( const OUString& rResourceURL, sal_Int32 nStyle );
 
     void            SetSystemStyle(
-        css::uno::Reference< css::frame::XFrame > xFrame,
+        const css::uno::Reference< css::frame::XFrame >& xFrame,
         const OUString& rResourceURL, sal_Int32 nStyle );
 
     SvxEntries*     GetEntries() override;
diff --git a/cui/source/inc/cfgutil.hxx b/cui/source/inc/cfgutil.hxx
index fddbdc1..7701291 100644
--- a/cui/source/inc/cfgutil.hxx
+++ b/cui/source/inc/cfgutil.hxx
@@ -134,7 +134,7 @@ class SfxConfigGroupListBox : public SvTreeListBox
     css::uno::Reference< css::container::XNameAccess > m_xUICmdDescription;
 
     Image GetImage(
-        css::uno::Reference< css::script::browse::XBrowseNode > node,
+        const css::uno::Reference< css::script::browse::XBrowseNode >& node,
         css::uno::Reference< css::uno::XComponentContext > xCtx,
         bool bIsRootNode
     );
diff --git a/cui/source/inc/cuitabarea.hxx b/cui/source/inc/cuitabarea.hxx
index 671d422..575d290 100644
--- a/cui/source/inc/cuitabarea.hxx
+++ b/cui/source/inc/cuitabarea.hxx
@@ -754,7 +754,7 @@ public:
 
     void             SetPropertyList( XPropertyListType t, const XPropertyListRef &xRef );
 
-    void    SetColorList( XColorListRef pColList );
+    void    SetColorList( const XColorListRef& pColList );
     XColorListRef GetColorList() { return pColorList; }
     void    SaveToViewFrame( SfxViewFrame *pViewFrame );
     void    SetupForViewFrame( SfxViewFrame *pViewFrame );
diff --git a/cui/source/inc/hlmarkwn.hxx b/cui/source/inc/hlmarkwn.hxx
index 71b82b6..6d3bb8a 100644
--- a/cui/source/inc/hlmarkwn.hxx
+++ b/cui/source/inc/hlmarkwn.hxx
@@ -82,7 +82,7 @@ protected:
 
     SvTreeListEntry* FindEntry(const OUString& aStrName);
     void ClearTree();
-    int FillTree( css::uno::Reference< css::container::XNameAccess > xLinks, SvTreeListEntry* pParentEntry =nullptr );
+    int FillTree( const css::uno::Reference< css::container::XNameAccess >& xLinks, SvTreeListEntry* pParentEntry =nullptr );
 
     virtual void Move () override;
 
diff --git a/cui/source/inc/macropg.hxx b/cui/source/inc/macropg.hxx
index 5036d4b..8f2afbd 100644
--- a/cui/source/inc/macropg.hxx
+++ b/cui/source/inc/macropg.hxx
@@ -79,7 +79,7 @@ protected:
 
     void                        EnableButtons();
     static css::uno::Any  GetPropsByName( const OUString& eventName, EventsHash& eventsHash );
-    static ::std::pair< OUString, OUString > GetPairFromAny( css::uno::Any aAny );
+    static ::std::pair< OUString, OUString > GetPairFromAny( const css::uno::Any& aAny );
 
 public:
 
@@ -87,7 +87,7 @@ public:
     virtual void                dispose() override;
     void                        InitResources();
 
-    void                        InitAndSetHandler( css::uno::Reference< css::container::XNameReplace > xAppEvents, css::uno::Reference< css::container::XNameReplace > xDocEvents, css::uno::Reference< css::util::XModifiable > xModifiable );
+    void                        InitAndSetHandler( const css::uno::Reference< css::container::XNameReplace >& xAppEvents, const css::uno::Reference< css::container::XNameReplace >& xDocEvents, const css::uno::Reference< css::util::XModifiable >& xModifiable );
     virtual bool                FillItemSet( SfxItemSet* rSet ) override;
 
     virtual void                Reset( const SfxItemSet* ) override;
diff --git a/cui/source/inc/scriptdlg.hxx b/cui/source/inc/scriptdlg.hxx
index 1dcfc36..53c92b0 100644
--- a/cui/source/inc/scriptdlg.hxx
+++ b/cui/source/inc/scriptdlg.hxx
@@ -167,7 +167,7 @@ protected:
     static css::uno::Reference< css::script::browse::XBrowseNode >
                 getBrowseNode( SvTreeListEntry* pEntry );
     static css::uno::Reference< css::frame::XModel > getModel( SvTreeListEntry* pEntry );
-    OUString    getListOfChildren( css::uno::Reference< css::script::browse::XBrowseNode > node, int depth );
+    OUString    getListOfChildren( const css::uno::Reference< css::script::browse::XBrowseNode >& node, int depth );
     void        StoreCurrentSelection();
     void        RestorePreviousSelection();
 
diff --git a/cui/source/inc/selector.hxx b/cui/source/inc/selector.hxx
index d9b6172..98b7991 100644
--- a/cui/source/inc/selector.hxx
+++ b/cui/source/inc/selector.hxx
@@ -135,7 +135,7 @@ class SvxConfigGroupListBox : public SvTreeListBox
     OUString m_sMyMacros;
     OUString m_sProdMacros;
     Image GetImage(
-        css::uno::Reference< css::script::browse::XBrowseNode > node,
+        const css::uno::Reference< css::script::browse::XBrowseNode >& node,
         css::uno::Reference< css::uno::XComponentContext > xCtx,
         bool bIsRootNode
     );
diff --git a/cui/source/options/connpooloptions.cxx b/cui/source/options/connpooloptions.cxx
index 4f09494..df19499 100644
--- a/cui/source/options/connpooloptions.cxx
+++ b/cui/source/options/connpooloptions.cxx
@@ -84,7 +84,7 @@ namespace offapp
 
 
     private:
-        OUString implGetCellText(DriverPoolingSettings::const_iterator _rPos, sal_uInt16 _nColId) const;
+        OUString implGetCellText(const DriverPoolingSettings::const_iterator& _rPos, sal_uInt16 _nColId) const;
     };
 
 
@@ -192,7 +192,7 @@ namespace offapp
     }
 
 
-    OUString DriverListControl::implGetCellText(DriverPoolingSettings::const_iterator _rPos, sal_uInt16 _nColId) const
+    OUString DriverListControl::implGetCellText(const DriverPoolingSettings::const_iterator& _rPos, sal_uInt16 _nColId) const
     {
         OSL_ENSURE(_rPos < m_aSettings.end(), "DriverListControl::implGetCellText: invalid position!");
 
diff --git a/cui/source/options/personalization.cxx b/cui/source/options/personalization.cxx
index 3532d56..bd97e91 100644
--- a/cui/source/options/personalization.cxx
+++ b/cui/source/options/personalization.cxx
@@ -220,7 +220,7 @@ void SelectPersonaDialog::SetProgress( OUString& rProgress )
     }
 }
 
-void SelectPersonaDialog::SetImages( Image aImage, sal_Int32 nIndex )
+void SelectPersonaDialog::SetImages( const Image& aImage, sal_Int32 nIndex )
 {
     m_vResultList[nIndex]->Enable();
     m_vResultList[nIndex]->SetModeImage( aImage );
diff --git a/cui/source/options/personalization.hxx b/cui/source/options/personalization.hxx
index ea92dc2..362fa6c 100644
--- a/cui/source/options/personalization.hxx
+++ b/cui/source/options/personalization.hxx
@@ -98,7 +98,7 @@ public:
 
     OUString GetSelectedPersona() const;
     void SetProgress( OUString& );
-    void SetImages( Image, sal_Int32 );
+    void SetImages( const Image&, sal_Int32 );
     void AddPersonaSetting( OUString& );
     void ClearSearchResults();
     void SetAppliedPersonaSetting( OUString& );
diff --git a/cui/source/tabpages/tpcolor.cxx b/cui/source/tabpages/tpcolor.cxx
index f376503..033dbf1 100644
--- a/cui/source/tabpages/tpcolor.cxx
+++ b/cui/source/tabpages/tpcolor.cxx
@@ -1180,7 +1180,7 @@ void SvxColorTabPage::SetPropertyList( XPropertyListType t, const XPropertyListR
     pColorList = XColorListRef( static_cast<XColorList *>(xRef.get() ) );
 }
 
-void SvxColorTabPage::SetColorList( XColorListRef pColList )
+void SvxColorTabPage::SetColorList( const XColorListRef& pColList )
 {
     SetPropertyList( XCOLOR_LIST, XPropertyListRef( ( pColList.get() ) ) );
 }
commit 9cfa0810bd4af4c1ebfcedaa62e82db87b3aea08
Author: Noel Grandin <noel at peralex.com>
Date:   Tue Apr 12 10:50:29 2016 +0200

    clang-tidy performance-unnecessary-value-param in chart2
    
    Change-Id: Id33dce9714737dd28ce48c22f966c9747c2db20b

diff --git a/chart2/source/controller/chartapiwrapper/ChartDocumentWrapper.cxx b/chart2/source/controller/chartapiwrapper/ChartDocumentWrapper.cxx
index 00ccc33..deb0abe 100644
--- a/chart2/source/controller/chartapiwrapper/ChartDocumentWrapper.cxx
+++ b/chart2/source/controller/chartapiwrapper/ChartDocumentWrapper.cxx
@@ -1134,7 +1134,7 @@ uno::Reference< drawing::XDrawPage > ChartDocumentWrapper::impl_getDrawPage() co
 
 namespace {
 
-uno::Reference< lang::XMultiServiceFactory > getShapeFactory(uno::Reference<uno::XInterface> xChartView)
+uno::Reference< lang::XMultiServiceFactory > getShapeFactory(const uno::Reference<uno::XInterface>& xChartView)
 {
     Reference< lang::XUnoTunnel> xUnoTunnel(xChartView,uno::UNO_QUERY);
     if(xUnoTunnel.is())
diff --git a/chart2/source/controller/chartapiwrapper/DiagramWrapper.cxx b/chart2/source/controller/chartapiwrapper/DiagramWrapper.cxx
index 60c7f65..21eb43f 100644
--- a/chart2/source/controller/chartapiwrapper/DiagramWrapper.cxx
+++ b/chart2/source/controller/chartapiwrapper/DiagramWrapper.cxx
@@ -501,7 +501,7 @@ bool lcl_isXYChart( const Reference< chart2::XDiagram >& rDiagram )
 
 sal_Int32 lcl_getNewAPIIndexForOldAPIIndex(
                 sal_Int32 nOldAPIIndex
-                , Reference< chart2::XDiagram > xDiagram )
+                , const Reference< chart2::XDiagram >& xDiagram )
 {
     sal_Int32 nNewAPIIndex = nOldAPIIndex;
 
diff --git a/chart2/source/controller/chartapiwrapper/WrappedAxisAndGridExistenceProperties.cxx b/chart2/source/controller/chartapiwrapper/WrappedAxisAndGridExistenceProperties.cxx
index 7bb7f82..0b1bd66 100644
--- a/chart2/source/controller/chartapiwrapper/WrappedAxisAndGridExistenceProperties.cxx
+++ b/chart2/source/controller/chartapiwrapper/WrappedAxisAndGridExistenceProperties.cxx
@@ -56,7 +56,7 @@ private: //member
 };
 
 void WrappedAxisAndGridExistenceProperties::addWrappedProperties( std::vector< WrappedProperty* >& rList
-            , std::shared_ptr< Chart2ModelContact > spChart2ModelContact )
+            , const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact )
 {
     rList.push_back( new WrappedAxisAndGridExistenceProperty( true, true, 0, spChart2ModelContact ) );//x axis
     rList.push_back( new WrappedAxisAndGridExistenceProperty( true, false, 0, spChart2ModelContact ) );//x secondary axis
@@ -221,7 +221,7 @@ private: //member
 };
 
 void WrappedAxisTitleExistenceProperties::addWrappedProperties( std::vector< WrappedProperty* >& rList
-            , std::shared_ptr< Chart2ModelContact > spChart2ModelContact )
+            , const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact )
 {
     rList.push_back( new WrappedAxisTitleExistenceProperty( 0, spChart2ModelContact ) );//x axis title
     rList.push_back( new WrappedAxisTitleExistenceProperty( 1, spChart2ModelContact ) );//y axis title
@@ -336,7 +336,7 @@ private: //member
 };
 
 void WrappedAxisLabelExistenceProperties::addWrappedProperties( std::vector< WrappedProperty* >& rList
-            , std::shared_ptr< Chart2ModelContact > spChart2ModelContact )
+            , const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact )
 {
     rList.push_back( new WrappedAxisLabelExistenceProperty( true, 0, spChart2ModelContact ) );//x axis
     rList.push_back( new WrappedAxisLabelExistenceProperty( true, 1, spChart2ModelContact ) );//y axis
diff --git a/chart2/source/controller/chartapiwrapper/WrappedAxisAndGridExistenceProperties.hxx b/chart2/source/controller/chartapiwrapper/WrappedAxisAndGridExistenceProperties.hxx
index 1c04139..cbdf242 100644
--- a/chart2/source/controller/chartapiwrapper/WrappedAxisAndGridExistenceProperties.hxx
+++ b/chart2/source/controller/chartapiwrapper/WrappedAxisAndGridExistenceProperties.hxx
@@ -35,21 +35,21 @@ class WrappedAxisAndGridExistenceProperties
 {
 public:
     static void addWrappedProperties( std::vector< WrappedProperty* >& rList
-        , std::shared_ptr< Chart2ModelContact > spChart2ModelContact );
+        , const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact );
 };
 
 class WrappedAxisTitleExistenceProperties
 {
 public:
     static void addWrappedProperties( std::vector< WrappedProperty* >& rList
-        , std::shared_ptr< Chart2ModelContact > spChart2ModelContact );
+        , const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact );
 };
 
 class WrappedAxisLabelExistenceProperties
 {
 public:
    static void addWrappedProperties( std::vector< WrappedProperty* >& rList
-       , std::shared_ptr< Chart2ModelContact > spChart2ModelContact );
+       , const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact );
 };
 
 } //namespace wrapper
diff --git a/chart2/source/controller/chartapiwrapper/WrappedDataCaptionProperties.cxx b/chart2/source/controller/chartapiwrapper/WrappedDataCaptionProperties.cxx
index fdc01a8..d1dd79e 100644
--- a/chart2/source/controller/chartapiwrapper/WrappedDataCaptionProperties.cxx
+++ b/chart2/source/controller/chartapiwrapper/WrappedDataCaptionProperties.cxx
@@ -88,7 +88,7 @@ chart2::DataPointLabel lcl_CaptionToLabel( sal_Int32 nCaption )
 }
 
 void lcl_addWrappedProperties( std::vector< WrappedProperty* >& rList
-                                    , std::shared_ptr< Chart2ModelContact > spChart2ModelContact
+                                    , const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact
                                     , tSeriesOrDiagramPropertyType ePropertyType )
 {
     //if !spChart2ModelContact.get() is then the created properties do belong to a single series or single datapoint
@@ -110,13 +110,13 @@ void WrappedDataCaptionProperties::addProperties( std::vector< Property > & rOut
 }
 
 void WrappedDataCaptionProperties::addWrappedPropertiesForSeries( std::vector< WrappedProperty* >& rList
-                                    , std::shared_ptr< Chart2ModelContact > spChart2ModelContact )
+                                    , const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact )
 {
     lcl_addWrappedProperties( rList, spChart2ModelContact, DATA_SERIES );
 }
 
 void WrappedDataCaptionProperties::addWrappedPropertiesForDiagram( std::vector< WrappedProperty* >& rList
-                                    , std::shared_ptr< Chart2ModelContact > spChart2ModelContact )
+                                    , const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact )
 {
     lcl_addWrappedProperties( rList, spChart2ModelContact, DIAGRAM );
 }
diff --git a/chart2/source/controller/chartapiwrapper/WrappedDataCaptionProperties.hxx b/chart2/source/controller/chartapiwrapper/WrappedDataCaptionProperties.hxx
index ad5222f..acd7741 100644
--- a/chart2/source/controller/chartapiwrapper/WrappedDataCaptionProperties.hxx
+++ b/chart2/source/controller/chartapiwrapper/WrappedDataCaptionProperties.hxx
@@ -35,9 +35,9 @@ class WrappedDataCaptionProperties
 public:
     static void addProperties( ::std::vector< css::beans::Property > & rOutProperties );
     static void addWrappedPropertiesForSeries( std::vector< WrappedProperty* >& rList
-                                    , std::shared_ptr< Chart2ModelContact > spChart2ModelContact );
+                                    , const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact );
     static void addWrappedPropertiesForDiagram( std::vector< WrappedProperty* >& rList
-                                    , std::shared_ptr< Chart2ModelContact > spChart2ModelContact );
+                                    , const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact );
 };
 
 } //namespace wrapper
diff --git a/chart2/source/controller/chartapiwrapper/WrappedScaleProperty.cxx b/chart2/source/controller/chartapiwrapper/WrappedScaleProperty.cxx
index f941f169..54ee48c 100644
--- a/chart2/source/controller/chartapiwrapper/WrappedScaleProperty.cxx
+++ b/chart2/source/controller/chartapiwrapper/WrappedScaleProperty.cxx
@@ -104,7 +104,7 @@ WrappedScaleProperty::~WrappedScaleProperty()
 }
 
 void WrappedScaleProperty::addWrappedProperties( std::vector< WrappedProperty* >& rList
-            , std::shared_ptr< Chart2ModelContact > spChart2ModelContact )
+            , const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact )
 {
     rList.push_back( new WrappedScaleProperty( SCALE_PROP_MAX, spChart2ModelContact ) );
     rList.push_back( new WrappedScaleProperty( SCALE_PROP_MIN, spChart2ModelContact ) );
diff --git a/chart2/source/controller/chartapiwrapper/WrappedScaleProperty.hxx b/chart2/source/controller/chartapiwrapper/WrappedScaleProperty.hxx
index a6c0d89..fdab48a 100644
--- a/chart2/source/controller/chartapiwrapper/WrappedScaleProperty.hxx
+++ b/chart2/source/controller/chartapiwrapper/WrappedScaleProperty.hxx
@@ -57,7 +57,7 @@ public:
     WrappedScaleProperty( tScaleProperty eScaleProperty, std::shared_ptr< Chart2ModelContact > spChart2ModelContact );
     virtual ~WrappedScaleProperty();
 
-    static void addWrappedProperties( std::vector< WrappedProperty* >& rList, std::shared_ptr< Chart2ModelContact > spChart2ModelContact );
+    static void addWrappedProperties( std::vector< WrappedProperty* >& rList, const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact );
 
     virtual void setPropertyValue( const css::uno::Any& rOuterValue, const css::uno::Reference< css::beans::XPropertySet >& xInnerPropertySet ) const
                         throw (css::beans::UnknownPropertyException, css::beans::PropertyVetoException, css::lang::IllegalArgumentException, css::lang::WrappedTargetException, css::uno::RuntimeException) override;
diff --git a/chart2/source/controller/chartapiwrapper/WrappedScaleTextProperties.cxx b/chart2/source/controller/chartapiwrapper/WrappedScaleTextProperties.cxx
index f46191e..3ad490c 100644
--- a/chart2/source/controller/chartapiwrapper/WrappedScaleTextProperties.cxx
+++ b/chart2/source/controller/chartapiwrapper/WrappedScaleTextProperties.cxx
@@ -136,7 +136,7 @@ void WrappedScaleTextProperties::addProperties( ::std::vector< Property > & rOut
 }
 
 void WrappedScaleTextProperties::addWrappedProperties( std::vector< WrappedProperty* >& rList
-                                 , std::shared_ptr< Chart2ModelContact > spChart2ModelContact )
+                                 , const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact )
 {
     rList.push_back( new WrappedScaleTextProperty( spChart2ModelContact ) );
 }
diff --git a/chart2/source/controller/chartapiwrapper/WrappedScaleTextProperties.hxx b/chart2/source/controller/chartapiwrapper/WrappedScaleTextProperties.hxx
index a74c0f6..b3e9ee9 100644
--- a/chart2/source/controller/chartapiwrapper/WrappedScaleTextProperties.hxx
+++ b/chart2/source/controller/chartapiwrapper/WrappedScaleTextProperties.hxx
@@ -36,7 +36,7 @@ class WrappedScaleTextProperties
 public:
     static void addProperties( ::std::vector< css::beans::Property >& rOutProperties );
     static void addWrappedProperties( std::vector< WrappedProperty* >& rList
-                    , std::shared_ptr< Chart2ModelContact > spChart2ModelContact );
+                    , const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact );
 };
 
 } //namespace wrapper
diff --git a/chart2/source/controller/chartapiwrapper/WrappedSceneProperty.cxx b/chart2/source/controller/chartapiwrapper/WrappedSceneProperty.cxx
index 6173725..099139a 100644
--- a/chart2/source/controller/chartapiwrapper/WrappedSceneProperty.cxx
+++ b/chart2/source/controller/chartapiwrapper/WrappedSceneProperty.cxx
@@ -33,7 +33,7 @@ namespace wrapper
 {
 
 void WrappedSceneProperty::addWrappedProperties( std::vector< WrappedProperty* >& rList
-                , std::shared_ptr< Chart2ModelContact > spChart2ModelContact )
+                , const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact )
 {
     rList.push_back( new WrappedD3DTransformMatrixProperty( spChart2ModelContact ) );
 }
diff --git a/chart2/source/controller/chartapiwrapper/WrappedSceneProperty.hxx b/chart2/source/controller/chartapiwrapper/WrappedSceneProperty.hxx
index d1a78ff..e2c9c9b 100644
--- a/chart2/source/controller/chartapiwrapper/WrappedSceneProperty.hxx
+++ b/chart2/source/controller/chartapiwrapper/WrappedSceneProperty.hxx
@@ -34,7 +34,7 @@ class WrappedSceneProperty
 {
 public:
     static void addWrappedProperties( std::vector< WrappedProperty* >& rList
-        , std::shared_ptr< Chart2ModelContact > spChart2ModelContact );
+        , const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact );
 };
 
 class WrappedD3DTransformMatrixProperty : public WrappedProperty
diff --git a/chart2/source/controller/chartapiwrapper/WrappedSplineProperties.cxx b/chart2/source/controller/chartapiwrapper/WrappedSplineProperties.cxx
index 9ca9ce9..f8b1dba 100644
--- a/chart2/source/controller/chartapiwrapper/WrappedSplineProperties.cxx
+++ b/chart2/source/controller/chartapiwrapper/WrappedSplineProperties.cxx
@@ -206,7 +206,7 @@ void WrappedSplineProperties::addProperties( ::std::vector< Property > & rOutPro
 }
 
 void WrappedSplineProperties::addWrappedProperties( std::vector< WrappedProperty* >& rList
-                                    , std::shared_ptr< Chart2ModelContact > spChart2ModelContact )
+                                    , const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact )
 {
     rList.push_back( new WrappedSplineTypeProperty( spChart2ModelContact ) );
     rList.push_back(
diff --git a/chart2/source/controller/chartapiwrapper/WrappedSplineProperties.hxx b/chart2/source/controller/chartapiwrapper/WrappedSplineProperties.hxx
index 0633ff5..01cd3f0 100644
--- a/chart2/source/controller/chartapiwrapper/WrappedSplineProperties.hxx
+++ b/chart2/source/controller/chartapiwrapper/WrappedSplineProperties.hxx
@@ -35,7 +35,7 @@ class WrappedSplineProperties
 public:
     static void addProperties( ::std::vector< css::beans::Property > & rOutProperties );
     static void addWrappedProperties( std::vector< WrappedProperty* >& rList
-                                    , std::shared_ptr< Chart2ModelContact > spChart2ModelContact );
+                                    , const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact );
 };
 
 } //namespace wrapper
diff --git a/chart2/source/controller/chartapiwrapper/WrappedStatisticProperties.cxx b/chart2/source/controller/chartapiwrapper/WrappedStatisticProperties.cxx
index 085ed9f..a73533c 100644
--- a/chart2/source/controller/chartapiwrapper/WrappedStatisticProperties.cxx
+++ b/chart2/source/controller/chartapiwrapper/WrappedStatisticProperties.cxx
@@ -121,7 +121,7 @@ sal_Int32 lcl_getErrorBarStyle( const uno::Reference< beans::XPropertySet >& xEr
 }
 
 uno::Reference< chart2::data::XDataProvider > lcl_getDataProviderFromContact(
-    ::std::shared_ptr< Chart2ModelContact > spChart2ModelContact )
+    const ::std::shared_ptr< Chart2ModelContact >& spChart2ModelContact )
 {
     uno::Reference< chart2::data::XDataProvider > xResult;
     if( spChart2ModelContact.get())
@@ -136,7 +136,7 @@ uno::Reference< chart2::data::XDataProvider > lcl_getDataProviderFromContact(
 
 void lcl_ConvertRangeFromXML(
     OUString & rInOutRange,
-    ::std::shared_ptr< Chart2ModelContact > spChart2ModelContact )
+    const ::std::shared_ptr< Chart2ModelContact >& spChart2ModelContact )
 {
     if( !rInOutRange.isEmpty())
     {
@@ -152,7 +152,7 @@ void lcl_ConvertRangeFromXML(
 
 void lcl_ConvertRangeToXML(
     OUString & rInOutRange,
-    ::std::shared_ptr< Chart2ModelContact > spChart2ModelContact )
+    const ::std::shared_ptr< Chart2ModelContact >& spChart2ModelContact )
 {
     if( !rInOutRange.isEmpty())
     {
@@ -965,7 +965,7 @@ enum
                series
  */
 void lcl_addWrappedProperties( std::vector< WrappedProperty* >& rList
-            , ::std::shared_ptr< Chart2ModelContact > spChart2ModelContact
+            , const ::std::shared_ptr< Chart2ModelContact >& spChart2ModelContact
             , tSeriesOrDiagramPropertyType ePropertyType )
 {
     rList.push_back( new WrappedConstantErrorLowProperty( spChart2ModelContact, ePropertyType ) );
@@ -1082,13 +1082,13 @@ void WrappedStatisticProperties::addProperties( ::std::vector< Property > & rOut
 }
 
 void WrappedStatisticProperties::addWrappedPropertiesForSeries( std::vector< WrappedProperty* >& rList
-                                    , ::std::shared_ptr< Chart2ModelContact > spChart2ModelContact )
+                                    , const ::std::shared_ptr< Chart2ModelContact >& spChart2ModelContact )
 {
     lcl_addWrappedProperties( rList, spChart2ModelContact, DATA_SERIES );
 }
 
 void WrappedStatisticProperties::addWrappedPropertiesForDiagram( std::vector< WrappedProperty* >& rList
-                                    , ::std::shared_ptr< Chart2ModelContact > spChart2ModelContact )
+                                    , const ::std::shared_ptr< Chart2ModelContact >& spChart2ModelContact )
 {
     lcl_addWrappedProperties( rList, spChart2ModelContact, DIAGRAM  );
 }
diff --git a/chart2/source/controller/chartapiwrapper/WrappedStatisticProperties.hxx b/chart2/source/controller/chartapiwrapper/WrappedStatisticProperties.hxx
index 3906779..2baba22 100644
--- a/chart2/source/controller/chartapiwrapper/WrappedStatisticProperties.hxx
+++ b/chart2/source/controller/chartapiwrapper/WrappedStatisticProperties.hxx
@@ -35,9 +35,9 @@ class WrappedStatisticProperties
 public:
     static void addProperties( ::std::vector< css::beans::Property > & rOutProperties );
     static void addWrappedPropertiesForSeries( std::vector< WrappedProperty* >& rList
-                    , ::std::shared_ptr< Chart2ModelContact > spChart2ModelContact );
+                    , const ::std::shared_ptr< Chart2ModelContact >& spChart2ModelContact );
     static void addWrappedPropertiesForDiagram( std::vector< WrappedProperty* >& rList
-                    , ::std::shared_ptr< Chart2ModelContact > spChart2ModelContact );
+                    , const ::std::shared_ptr< Chart2ModelContact >& spChart2ModelContact );
 };
 
 } //namespace wrapper
diff --git a/chart2/source/controller/chartapiwrapper/WrappedStockProperties.cxx b/chart2/source/controller/chartapiwrapper/WrappedStockProperties.cxx
index f0e94d8..124c862 100644
--- a/chart2/source/controller/chartapiwrapper/WrappedStockProperties.cxx
+++ b/chart2/source/controller/chartapiwrapper/WrappedStockProperties.cxx
@@ -278,7 +278,7 @@ void WrappedStockProperties::addProperties( ::std::vector< Property > & rOutProp
 }
 
 void WrappedStockProperties::addWrappedProperties( std::vector< WrappedProperty* >& rList
-                                    , std::shared_ptr< Chart2ModelContact > spChart2ModelContact )
+                                    , const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact )
 {
     rList.push_back( new WrappedVolumeProperty( spChart2ModelContact ) );
     rList.push_back( new WrappedUpDownProperty( spChart2ModelContact ) );
diff --git a/chart2/source/controller/chartapiwrapper/WrappedStockProperties.hxx b/chart2/source/controller/chartapiwrapper/WrappedStockProperties.hxx
index 9a92d0f..faa1ba5 100644
--- a/chart2/source/controller/chartapiwrapper/WrappedStockProperties.hxx
+++ b/chart2/source/controller/chartapiwrapper/WrappedStockProperties.hxx
@@ -35,7 +35,7 @@ class WrappedStockProperties
 public:
     static void addProperties( ::std::vector< css::beans::Property > & rOutProperties );
     static void addWrappedProperties( std::vector< WrappedProperty* >& rList
-            , std::shared_ptr< Chart2ModelContact > spChart2ModelContact );
+            , const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact );
 };
 
 } //namespace wrapper
diff --git a/chart2/source/controller/chartapiwrapper/WrappedSymbolProperties.cxx b/chart2/source/controller/chartapiwrapper/WrappedSymbolProperties.cxx
index a7bf6af..40f68ce 100644
--- a/chart2/source/controller/chartapiwrapper/WrappedSymbolProperties.cxx
+++ b/chart2/source/controller/chartapiwrapper/WrappedSymbolProperties.cxx
@@ -159,7 +159,7 @@ void lcl_setSymbolTypeToSymbol( sal_Int32 nSymbolType, chart2::Symbol& rSymbol )
 }
 
 void lcl_addWrappedProperties( std::vector< WrappedProperty* >& rList
-                                    , std::shared_ptr< Chart2ModelContact > spChart2ModelContact
+                                    , const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact
                                     , tSeriesOrDiagramPropertyType ePropertyType )
 {
     rList.push_back( new WrappedSymbolTypeProperty( spChart2ModelContact, ePropertyType ) );
@@ -202,13 +202,13 @@ void WrappedSymbolProperties::addProperties( ::std::vector< Property > & rOutPro
 }
 
 void WrappedSymbolProperties::addWrappedPropertiesForSeries( std::vector< WrappedProperty* >& rList
-                                    , std::shared_ptr< Chart2ModelContact > spChart2ModelContact )
+                                    , const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact )
 {
     lcl_addWrappedProperties( rList, spChart2ModelContact, DATA_SERIES );
 }
 
 void WrappedSymbolProperties::addWrappedPropertiesForDiagram( std::vector< WrappedProperty* >& rList
-                                    , std::shared_ptr< Chart2ModelContact > spChart2ModelContact )
+                                    , const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact )
 {
     lcl_addWrappedProperties( rList, spChart2ModelContact, DIAGRAM );
 }
diff --git a/chart2/source/controller/chartapiwrapper/WrappedSymbolProperties.hxx b/chart2/source/controller/chartapiwrapper/WrappedSymbolProperties.hxx
index f065e31..44356dd 100644
--- a/chart2/source/controller/chartapiwrapper/WrappedSymbolProperties.hxx
+++ b/chart2/source/controller/chartapiwrapper/WrappedSymbolProperties.hxx
@@ -35,9 +35,9 @@ class WrappedSymbolProperties
 public:
     static void addProperties( ::std::vector< css::beans::Property > & rOutProperties );
     static void addWrappedPropertiesForSeries( std::vector< WrappedProperty* >& rList
-                    , std::shared_ptr< Chart2ModelContact > spChart2ModelContact );
+                    , const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact );
     static void addWrappedPropertiesForDiagram( std::vector< WrappedProperty* >& rList
-                    , std::shared_ptr< Chart2ModelContact > spChart2ModelContact );
+                    , const std::shared_ptr< Chart2ModelContact >& spChart2ModelContact );
 };
 
 } //namespace wrapper
diff --git a/chart2/source/controller/dialogs/tp_RangeChooser.cxx b/chart2/source/controller/dialogs/tp_RangeChooser.cxx
index 5b7ba83..dbfdc38 100644
--- a/chart2/source/controller/dialogs/tp_RangeChooser.cxx
+++ b/chart2/source/controller/dialogs/tp_RangeChooser.cxx
@@ -386,6 +386,7 @@ void RangeChooserTabPage::listeningFinished( const OUString & rNewRange )
 {
     //user has selected a new range
 
+    // rNewRange becomes invalid after removing the listener
     OUString aRange( rNewRange );
 
     m_rDialogModel.startControllerLockTimer();
diff --git a/chart2/source/controller/itemsetwrapper/RegressionCurveItemConverter.cxx b/chart2/source/controller/itemsetwrapper/RegressionCurveItemConverter.cxx
index abd303c..ac66707 100644
--- a/chart2/source/controller/itemsetwrapper/RegressionCurveItemConverter.cxx
+++ b/chart2/source/controller/itemsetwrapper/RegressionCurveItemConverter.cxx
@@ -41,7 +41,7 @@ using namespace ::com::sun::star;
 namespace
 {
 template <class T, class D>
-bool lclConvertToPropertySet(const SfxItemSet& rItemSet, sal_uInt16 nWhichId, uno::Reference<beans::XPropertySet> xProperties, const OUString& aPropertyID)
+bool lclConvertToPropertySet(const SfxItemSet& rItemSet, sal_uInt16 nWhichId, const uno::Reference<beans::XPropertySet>& xProperties, const OUString& aPropertyID)
 {
     OSL_ASSERT(xProperties.is());
     if( xProperties.is() )
@@ -59,7 +59,7 @@ bool lclConvertToPropertySet(const SfxItemSet& rItemSet, sal_uInt16 nWhichId, un
 }
 
 template <class T, class D>
-void lclConvertToItemSet(SfxItemSet& rItemSet, sal_uInt16 nWhichId, uno::Reference<beans::XPropertySet> xProperties, const OUString& aPropertyID)
+void lclConvertToItemSet(SfxItemSet& rItemSet, sal_uInt16 nWhichId, const uno::Reference<beans::XPropertySet>& xProperties, const OUString& aPropertyID)
 {
     OSL_ASSERT(xProperties.is());
     if( xProperties.is() )
@@ -72,7 +72,7 @@ void lclConvertToItemSet(SfxItemSet& rItemSet, sal_uInt16 nWhichId, uno::Referen
     }
 }
 
-void lclConvertToItemSetDouble(SfxItemSet& rItemSet, sal_uInt16 nWhichId, uno::Reference<beans::XPropertySet> xProperties, const OUString& aPropertyID)
+void lclConvertToItemSetDouble(SfxItemSet& rItemSet, sal_uInt16 nWhichId, const uno::Reference<beans::XPropertySet>& xProperties, const OUString& aPropertyID)
 {
     OSL_ASSERT(xProperties.is());
     if( xProperties.is() )
diff --git a/chart2/source/controller/itemsetwrapper/StatisticsItemConverter.cxx b/chart2/source/controller/itemsetwrapper/StatisticsItemConverter.cxx
index 5f749ea..54864931 100644
--- a/chart2/source/controller/itemsetwrapper/StatisticsItemConverter.cxx
+++ b/chart2/source/controller/itemsetwrapper/StatisticsItemConverter.cxx
@@ -174,7 +174,7 @@ uno::Reference< beans::XPropertySet > lcl_getCurveProperties(
 }
 
 template <class T, class D>
-bool lclConvertToPropertySet(const SfxItemSet& rItemSet, sal_uInt16 nWhichId, uno::Reference<beans::XPropertySet> xProperties, const OUString& aPropertyID)
+bool lclConvertToPropertySet(const SfxItemSet& rItemSet, sal_uInt16 nWhichId, const uno::Reference<beans::XPropertySet>& xProperties, const OUString& aPropertyID)
 {
     OSL_ASSERT(xProperties.is());
     if( xProperties.is() )
@@ -192,7 +192,7 @@ bool lclConvertToPropertySet(const SfxItemSet& rItemSet, sal_uInt16 nWhichId, un
 }
 
 template <class T, class D>
-void lclConvertToItemSet(SfxItemSet& rItemSet, sal_uInt16 nWhichId, uno::Reference<beans::XPropertySet> xProperties, const OUString& aPropertyID)
+void lclConvertToItemSet(SfxItemSet& rItemSet, sal_uInt16 nWhichId, const uno::Reference<beans::XPropertySet>& xProperties, const OUString& aPropertyID)
 {
     OSL_ASSERT(xProperties.is());
     if( xProperties.is() )
@@ -205,7 +205,7 @@ void lclConvertToItemSet(SfxItemSet& rItemSet, sal_uInt16 nWhichId, uno::Referen
     }
 }
 
-void lclConvertToItemSetDouble(SfxItemSet& rItemSet, sal_uInt16 nWhichId, uno::Reference<beans::XPropertySet> xProperties, const OUString& aPropertyID)
+void lclConvertToItemSetDouble(SfxItemSet& rItemSet, sal_uInt16 nWhichId, const uno::Reference<beans::XPropertySet>& xProperties, const OUString& aPropertyID)
 {
     OSL_ASSERT(xProperties.is());
     if( xProperties.is() )
diff --git a/chart2/source/controller/main/ChartController.cxx b/chart2/source/controller/main/ChartController.cxx
index 9df3c28..0007569 100644
--- a/chart2/source/controller/main/ChartController.cxx
+++ b/chart2/source/controller/main/ChartController.cxx
@@ -282,7 +282,7 @@ bool ChartController::TheModelRef::is() const
 namespace {
 
 css::uno::Reference<css::chart2::XChartType> getChartType(
-        css::uno::Reference<css::chart2::XChartDocument> xChartDoc)
+        const css::uno::Reference<css::chart2::XChartDocument>& xChartDoc)
 {
     Reference <chart2::XDiagram > xDiagram = xChartDoc->getFirstDiagram();
 
@@ -394,7 +394,7 @@ uno::Sequence< OUString > ChartController::getSupportedServiceNames_Static()
 
 namespace {
 
-uno::Reference<ui::XSidebar> getSidebarFromModel(uno::Reference<frame::XModel> xModel)
+uno::Reference<ui::XSidebar> getSidebarFromModel(const uno::Reference<frame::XModel>& xModel)
 {
     uno::Reference<container::XChild> xChild(xModel, uno::UNO_QUERY);
     if (!xChild.is())
diff --git a/chart2/source/controller/main/DragMethod_RotateDiagram.cxx b/chart2/source/controller/main/DragMethod_RotateDiagram.cxx
index d07ecfd..1398ebe 100644
--- a/chart2/source/controller/main/DragMethod_RotateDiagram.cxx
+++ b/chart2/source/controller/main/DragMethod_RotateDiagram.cxx
@@ -202,7 +202,7 @@ void DragMethod_RotateDiagram::CreateOverlayGeometry(sdr::overlay::OverlayManage
     if(m_aWireframePolyPolygon.count() && m_pScene)
     {
         const sdr::contact::ViewContactOfE3dScene& rVCScene = static_cast< sdr::contact::ViewContactOfE3dScene& >(m_pScene->GetViewContact());
-        const drawinglayer::geometry::ViewInformation3D aViewInfo3D(rVCScene.getViewInformation3D());
+        const drawinglayer::geometry::ViewInformation3D& aViewInfo3D(rVCScene.getViewInformation3D());
         const basegfx::B3DHomMatrix aWorldToView(aViewInfo3D.getDeviceToView() * aViewInfo3D.getProjection() * aViewInfo3D.getOrientation());
         const basegfx::B3DHomMatrix aTransform(aWorldToView * aCurrentTransform);
 
diff --git a/chart2/source/controller/sidebar/ChartAreaPanel.cxx b/chart2/source/controller/sidebar/ChartAreaPanel.cxx
index 09d0b2c..389120b 100644
--- a/chart2/source/controller/sidebar/ChartAreaPanel.cxx
+++ b/chart2/source/controller/sidebar/ChartAreaPanel.cxx
@@ -33,7 +33,7 @@ SvxColorToolBoxControl* getColorToolBoxControl(sfx2::sidebar::SidebarToolBox* pT
     return pToolBoxColorControl;
 }
 
-OUString getCID(css::uno::Reference<css::frame::XModel> xModel)
+OUString getCID(const css::uno::Reference<css::frame::XModel>& xModel)
 {
     css::uno::Reference<css::frame::XController> xController(xModel->getCurrentController());
     css::uno::Reference<css::view::XSelectionSupplier> xSelectionSupplier(xController, css::uno::UNO_QUERY);
@@ -51,7 +51,7 @@ OUString getCID(css::uno::Reference<css::frame::XModel> xModel)
 }
 
 css::uno::Reference<css::beans::XPropertySet> getPropSet(
-        css::uno::Reference<css::frame::XModel> xModel)
+        const css::uno::Reference<css::frame::XModel>& xModel)
 {
     OUString aCID = getCID(xModel);
     css::uno::Reference<css::beans::XPropertySet> xPropSet =
@@ -71,7 +71,7 @@ css::uno::Reference<css::beans::XPropertySet> getPropSet(
     return xPropSet;
 }
 
-ChartController* getController(css::uno::Reference<css::frame::XModel> xModel)
+ChartController* getController(const css::uno::Reference<css::frame::XModel>& xModel)
 {
     css::uno::Reference<css::frame::XController>xController = xModel->getCurrentController();
     if (!xController.is())
@@ -84,20 +84,20 @@ ChartController* getController(css::uno::Reference<css::frame::XModel> xModel)
     return pController;
 }
 
-ViewElementListProvider getViewElementListProvider( css::uno::Reference<css::frame::XModel> xModel)
+ViewElementListProvider getViewElementListProvider( const css::uno::Reference<css::frame::XModel>& xModel)
 {
     ChartController* pController = getController(xModel);
     ViewElementListProvider aProvider = pController->getViewElementListProvider();
     return aProvider;
 }
 
-DrawModelWrapper* getDrawModelWrapper(css::uno::Reference<css::frame::XModel> xModel)
+DrawModelWrapper* getDrawModelWrapper(const css::uno::Reference<css::frame::XModel>& xModel)
 {
     ChartController* pController = getController(xModel);
     return pController->GetDrawModelWrapper();
 }
 
-XGradient getXGradientForName(css::uno::Reference<css::frame::XModel> xModel,
+XGradient getXGradientForName(const css::uno::Reference<css::frame::XModel>& xModel,
         const OUString& rName)
 {
     try
@@ -123,7 +123,7 @@ XGradient getXGradientForName(css::uno::Reference<css::frame::XModel> xModel,
     return XGradient();
 }
 
-XFillFloatTransparenceItem getXTransparencyGradientForName(css::uno::Reference<css::frame::XModel> xModel,
+XFillFloatTransparenceItem getXTransparencyGradientForName(const css::uno::Reference<css::frame::XModel>& xModel,
         const OUString& rName)
 {
     css::uno::Reference<css::lang::XMultiServiceFactory> xFact(xModel, css::uno::UNO_QUERY);
@@ -145,7 +145,7 @@ XFillFloatTransparenceItem getXTransparencyGradientForName(css::uno::Reference<c
     return aItem;
 }
 
-XHatch getXHatchFromName(css::uno::Reference<css::frame::XModel> xModel,
+XHatch getXHatchFromName(const css::uno::Reference<css::frame::XModel>& xModel,
         OUString& rName)
 {
     try
@@ -175,7 +175,7 @@ XHatch getXHatchFromName(css::uno::Reference<css::frame::XModel> xModel,
     return XHatch();
 }
 
-GraphicObject getXBitmapFromName(css::uno::Reference<css::frame::XModel> xModel,
+GraphicObject getXBitmapFromName(const css::uno::Reference<css::frame::XModel>& xModel,
         const OUString& rName)
 {
     try
diff --git a/chart2/source/controller/sidebar/ChartAxisPanel.cxx b/chart2/source/controller/sidebar/ChartAxisPanel.cxx
index 4bcdcb9..0adf173 100644
--- a/chart2/source/controller/sidebar/ChartAxisPanel.cxx
+++ b/chart2/source/controller/sidebar/ChartAxisPanel.cxx
@@ -44,7 +44,7 @@ namespace chart { namespace sidebar {
 
 namespace {
 
-bool isLabelShown(css::uno::Reference<css::frame::XModel> xModel,
+bool isLabelShown(const css::uno::Reference<css::frame::XModel>& xModel,
         const OUString& rCID)
 {
     css::uno::Reference< css::beans::XPropertySet > xAxis(
@@ -62,7 +62,7 @@ bool isLabelShown(css::uno::Reference<css::frame::XModel> xModel,
     return bVisible;
 }
 
-void setLabelShown(css::uno::Reference<css::frame::XModel> xModel,
+void setLabelShown(const css::uno::Reference<css::frame::XModel>& xModel,
         const OUString& rCID, bool bVisible)
 {
     css::uno::Reference< css::beans::XPropertySet > xAxis(
@@ -87,7 +87,7 @@ AxisLabelPosMap aLabelPosMap[] = {
     { 3, css::chart::ChartAxisLabelPosition_OUTSIDE_END }
 };
 
-sal_Int32 getLabelPosition(css::uno::Reference<css::frame::XModel> xModel,
+sal_Int32 getLabelPosition(const css::uno::Reference<css::frame::XModel>& xModel,
         const OUString& rCID)
 {
     css::uno::Reference< css::beans::XPropertySet > xAxis(
@@ -111,7 +111,7 @@ sal_Int32 getLabelPosition(css::uno::Reference<css::frame::XModel> xModel,
     return 0;
 }
 
-void setLabelPosition(css::uno::Reference<css::frame::XModel> xModel,
+void setLabelPosition(const css::uno::Reference<css::frame::XModel>& xModel,
         const OUString& rCID, sal_Int32 nPos)
 {
     css::uno::Reference< css::beans::XPropertySet > xAxis(
@@ -130,7 +130,7 @@ void setLabelPosition(css::uno::Reference<css::frame::XModel> xModel,
     xAxis->setPropertyValue("LabelPosition", css::uno::makeAny(ePos));
 }
 
-bool isReverse(css::uno::Reference<css::frame::XModel> xModel,
+bool isReverse(const css::uno::Reference<css::frame::XModel>& xModel,
         const OUString& rCID)
 {
     css::uno::Reference< css::chart2::XAxis > xAxis(
@@ -144,7 +144,7 @@ bool isReverse(css::uno::Reference<css::frame::XModel> xModel,
     return aData.Orientation == css::chart2::AxisOrientation_REVERSE;
 }
 
-void setReverse(css::uno::Reference<css::frame::XModel> xModel,
+void setReverse(const css::uno::Reference<css::frame::XModel>& xModel,
         const OUString& rCID, bool bReverse)
 {
     css::uno::Reference< css::chart2::XAxis > xAxis(
@@ -162,7 +162,7 @@ void setReverse(css::uno::Reference<css::frame::XModel> xModel,
     xAxis->setScaleData(aData);
 }
 
-OUString getCID(css::uno::Reference<css::frame::XModel> xModel)
+OUString getCID(const css::uno::Reference<css::frame::XModel>& xModel)
 {
     css::uno::Reference<css::frame::XController> xController(xModel->getCurrentController());
     css::uno::Reference<css::view::XSelectionSupplier> xSelectionSupplier(xController, css::uno::UNO_QUERY);
@@ -181,7 +181,7 @@ OUString getCID(css::uno::Reference<css::frame::XModel> xModel)
     return aCID;
 }
 
-void setAxisRotation(css::uno::Reference<css::frame::XModel> xModel,
+void setAxisRotation(const css::uno::Reference<css::frame::XModel>& xModel,
         const OUString& rCID, double nVal)
 {
     css::uno::Reference< css::beans::XPropertySet > xAxis(
@@ -193,7 +193,7 @@ void setAxisRotation(css::uno::Reference<css::frame::XModel> xModel,
     xAxis->setPropertyValue("TextRotation", css::uno::makeAny(nVal));
 }
 
-double getAxisRotation(css::uno::Reference<css::frame::XModel> xModel,
+double getAxisRotation(const css::uno::Reference<css::frame::XModel>& xModel,
         const OUString& rCID)
 {
     css::uno::Reference< css::beans::XPropertySet > xAxis(
diff --git a/chart2/source/controller/sidebar/ChartColorWrapper.cxx b/chart2/source/controller/sidebar/ChartColorWrapper.cxx
index bd5fd67..6172939 100644
--- a/chart2/source/controller/sidebar/ChartColorWrapper.cxx
+++ b/chart2/source/controller/sidebar/ChartColorWrapper.cxx
@@ -19,7 +19,7 @@ namespace chart { namespace sidebar {
 
 namespace {
 
-OUString getCID(css::uno::Reference<css::frame::XModel> xModel)
+OUString getCID(const css::uno::Reference<css::frame::XModel>& xModel)
 {
     css::uno::Reference<css::frame::XController> xController(xModel->getCurrentController());
     css::uno::Reference<css::view::XSelectionSupplier> xSelectionSupplier(xController, css::uno::UNO_QUERY);
@@ -37,7 +37,7 @@ OUString getCID(css::uno::Reference<css::frame::XModel> xModel)
 }
 
 css::uno::Reference<css::beans::XPropertySet> getPropSet(
-        css::uno::Reference<css::frame::XModel> xModel)
+        const css::uno::Reference<css::frame::XModel>& xModel)
 {
     OUString aCID = getCID(xModel);
     css::uno::Reference<css::beans::XPropertySet> xPropSet =
@@ -77,7 +77,7 @@ void ChartColorWrapper::operator()(const OUString& , const Color& rColor)
     xPropSet->setPropertyValue(maPropertyName, css::uno::makeAny(rColor.GetColor()));
 }
 
-void ChartColorWrapper::updateModel(css::uno::Reference<css::frame::XModel> xModel)
+void ChartColorWrapper::updateModel(const css::uno::Reference<css::frame::XModel>& xModel)
 {
     mxModel = xModel;
 }
diff --git a/chart2/source/controller/sidebar/ChartColorWrapper.hxx b/chart2/source/controller/sidebar/ChartColorWrapper.hxx
index 045f947..4fcfb7d 100644
--- a/chart2/source/controller/sidebar/ChartColorWrapper.hxx
+++ b/chart2/source/controller/sidebar/ChartColorWrapper.hxx
@@ -28,7 +28,7 @@ public:
 
     void operator()(const OUString& rCommand, const Color& rColor);
 
-    void updateModel(css::uno::Reference<css::frame::XModel> xModel);
+    void updateModel(const css::uno::Reference<css::frame::XModel>& xModel);
 
     void updateData();
 
diff --git a/chart2/source/controller/sidebar/ChartElementsPanel.cxx b/chart2/source/controller/sidebar/ChartElementsPanel.cxx
index 3c914ce..3287fc0 100644
--- a/chart2/source/controller/sidebar/ChartElementsPanel.cxx
+++ b/chart2/source/controller/sidebar/ChartElementsPanel.cxx
@@ -72,14 +72,14 @@ enum class AxisType
     Y_SECOND
 };
 
-ChartModel* getChartModel(css::uno::Reference<css::frame::XModel> xModel)
+ChartModel* getChartModel(const css::uno::Reference<css::frame::XModel>& xModel)
 {
     ChartModel* pModel = dynamic_cast<ChartModel*>(xModel.get());
 
     return pModel;
 }
 
-bool isLegendVisible(css::uno::Reference<css::frame::XModel> xModel)
+bool isLegendVisible(const css::uno::Reference<css::frame::XModel>& xModel)
 {
     ChartModel* pModel = getChartModel(xModel);
     if (!pModel)
@@ -104,7 +104,7 @@ bool isLegendVisible(css::uno::Reference<css::frame::XModel> xModel)
     return false;
 }
 
-void setLegendVisible(css::uno::Reference<css::frame::XModel> xModel, bool bVisible)
+void setLegendVisible(const css::uno::Reference<css::frame::XModel>& xModel, bool bVisible)
 {
     ChartModel* pModel = getChartModel(xModel);
     if (!pModel)
@@ -116,12 +116,12 @@ void setLegendVisible(css::uno::Reference<css::frame::XModel> xModel, bool bVisi
         LegendHelper::hideLegend(*pModel);
 }
 
-bool isTitleVisisble(css::uno::Reference<css::frame::XModel> xModel, TitleHelper::eTitleType eTitle)
+bool isTitleVisisble(const css::uno::Reference<css::frame::XModel>& xModel, TitleHelper::eTitleType eTitle)
 {
     return TitleHelper::getTitle(eTitle, xModel).is();
 }
 
-bool isGridVisible(css::uno::Reference<css::frame::XModel> xModel, GridType eType)
+bool isGridVisible(const css::uno::Reference<css::frame::XModel>& xModel, GridType eType)
 {
     Reference< chart2::XDiagram > xDiagram(ChartModelHelper::findDiagram(xModel));
     if(xDiagram.is())
@@ -139,7 +139,7 @@ bool isGridVisible(css::uno::Reference<css::frame::XModel> xModel, GridType eTyp
     return false;
 }
 
-void setGridVisible(css::uno::Reference<css::frame::XModel> xModel, GridType eType, bool bVisible)
+void setGridVisible(const css::uno::Reference<css::frame::XModel>& xModel, GridType eType, bool bVisible)
 {
     Reference< chart2::XDiagram > xDiagram(ChartModelHelper::findDiagram(xModel));
     if(xDiagram.is())
@@ -159,7 +159,7 @@ void setGridVisible(css::uno::Reference<css::frame::XModel> xModel, GridType eTy
     }
 }
 
-bool isAxisVisible(css::uno::Reference<css::frame::XModel> xModel, AxisType eType)
+bool isAxisVisible(const css::uno::Reference<css::frame::XModel>& xModel, AxisType eType)
 {
     Reference< chart2::XDiagram > xDiagram(ChartModelHelper::findDiagram(xModel));
     if(xDiagram.is())
@@ -178,7 +178,7 @@ bool isAxisVisible(css::uno::Reference<css::frame::XModel> xModel, AxisType eTyp
     return false;
 }
 
-void setAxisVisible(css::uno::Reference<css::frame::XModel> xModel, AxisType eType, bool bVisible)
+void setAxisVisible(const css::uno::Reference<css::frame::XModel>& xModel, AxisType eType, bool bVisible)
 {
     Reference< chart2::XDiagram > xDiagram(ChartModelHelper::findDiagram(xModel));
     if(xDiagram.is())
@@ -198,7 +198,7 @@ void setAxisVisible(css::uno::Reference<css::frame::XModel> xModel, AxisType eTy
     }
 }
 
-sal_Int32 getLegendPos(css::uno::Reference<css::frame::XModel> xModel)
+sal_Int32 getLegendPos(const css::uno::Reference<css::frame::XModel>& xModel)
 {
     ChartModel* pModel = getChartModel(xModel);
     if (!pModel)
@@ -225,7 +225,7 @@ sal_Int32 getLegendPos(css::uno::Reference<css::frame::XModel> xModel)
     }
 }
 
-void setLegendPos(css::uno::Reference<css::frame::XModel> xModel, sal_Int32 nPos)
+void setLegendPos(const css::uno::Reference<css::frame::XModel>& xModel, sal_Int32 nPos)
 {
     ChartModel* pModel = getChartModel(xModel);
     if (!pModel)
@@ -383,7 +383,7 @@ void ChartElementsPanel::Initialize()
 
 namespace {
 
-css::uno::Reference<css::chart2::XChartType> getChartType(css::uno::Reference<css::frame::XModel> xModel)
+css::uno::Reference<css::chart2::XChartType> getChartType(const css::uno::Reference<css::frame::XModel>& xModel)
 {
     css::uno::Reference<css::chart2::XChartDocument> xChartDoc(xModel, css::uno::UNO_QUERY_THROW);
     css::uno::Reference<chart2::XDiagram > xDiagram = xChartDoc->getFirstDiagram();
diff --git a/chart2/source/controller/sidebar/ChartErrorBarPanel.cxx b/chart2/source/controller/sidebar/ChartErrorBarPanel.cxx
index 03ed6f9..e0f69a0 100644
--- a/chart2/source/controller/sidebar/ChartErrorBarPanel.cxx
+++ b/chart2/source/controller/sidebar/ChartErrorBarPanel.cxx
@@ -52,12 +52,12 @@ enum class ErrorBarDirection
 };
 
 css::uno::Reference<css::beans::XPropertySet> getErrorBarPropSet(
-        css::uno::Reference<css::frame::XModel> xModel, const OUString& rCID)
+        const css::uno::Reference<css::frame::XModel>& xModel, const OUString& rCID)
 {
     return ObjectIdentifier::getObjectPropertySet(rCID, xModel);
 }
 
-bool showPositiveError(css::uno::Reference<css::frame::XModel> xModel,
+bool showPositiveError(const css::uno::Reference<css::frame::XModel>& xModel,
         const OUString& rCID)
 {
     css::uno::Reference<css::beans::XPropertySet> xPropSet =
@@ -76,7 +76,7 @@ bool showPositiveError(css::uno::Reference<css::frame::XModel> xModel,
     return bShow;
 }
 
-bool showNegativeError(css::uno::Reference<css::frame::XModel> xModel,
+bool showNegativeError(const css::uno::Reference<css::frame::XModel>& xModel,
         const OUString& rCID)
 {
     css::uno::Reference<css::beans::XPropertySet> xPropSet =
@@ -95,7 +95,7 @@ bool showNegativeError(css::uno::Reference<css::frame::XModel> xModel,
     return bShow;
 }
 
-void setShowPositiveError(css::uno::Reference<css::frame::XModel> xModel,
+void setShowPositiveError(const css::uno::Reference<css::frame::XModel>& xModel,
         const OUString& rCID, bool bShow)
 {
     css::uno::Reference<css::beans::XPropertySet> xPropSet =
@@ -107,7 +107,7 @@ void setShowPositiveError(css::uno::Reference<css::frame::XModel> xModel,
     xPropSet->setPropertyValue("ShowPositiveError", css::uno::makeAny(bShow));
 }
 
-void setShowNegativeError(css::uno::Reference<css::frame::XModel> xModel,
+void setShowNegativeError(const css::uno::Reference<css::frame::XModel>& xModel,
         const OUString& rCID, bool bShow)
 {
     css::uno::Reference<css::beans::XPropertySet> xPropSet =
@@ -135,7 +135,7 @@ ErrorBarTypeMap aErrorBarType[] = {
     { 6, css::chart::ErrorBarStyle::ERROR_MARGIN },
 };
 
-sal_Int32 getTypePos(css::uno::Reference<css::frame::XModel> xModel,
+sal_Int32 getTypePos(const css::uno::Reference<css::frame::XModel>& xModel,
         const OUString& rCID)
 {
     css::uno::Reference<css::beans::XPropertySet> xPropSet =
@@ -161,7 +161,7 @@ sal_Int32 getTypePos(css::uno::Reference<css::frame::XModel> xModel,
     return 0;
 }
 
-void setTypePos(css::uno::Reference<css::frame::XModel> xModel,
+void setTypePos(const css::uno::Reference<css::frame::XModel>& xModel,
         const OUString& rCID, sal_Int32 nPos)
 {
     css::uno::Reference<css::beans::XPropertySet> xPropSet =
@@ -180,7 +180,7 @@ void setTypePos(css::uno::Reference<css::frame::XModel> xModel,
     xPropSet->setPropertyValue("ErrorBarStyle", css::uno::makeAny(nApi));
 }
 
-double getValue(css::uno::Reference<css::frame::XModel> xModel,
+double getValue(const css::uno::Reference<css::frame::XModel>& xModel,
         const OUString& rCID, ErrorBarDirection eDir)
 {
     css::uno::Reference<css::beans::XPropertySet> xPropSet =
@@ -204,7 +204,7 @@ double getValue(css::uno::Reference<css::frame::XModel> xModel,
     return nVal;
 }
 
-void setValue(css::uno::Reference<css::frame::XModel> xModel,
+void setValue(const css::uno::Reference<css::frame::XModel>& xModel,
         const OUString& rCID, double nVal, ErrorBarDirection eDir)
 {
     css::uno::Reference<css::beans::XPropertySet> xPropSet =
@@ -220,7 +220,7 @@ void setValue(css::uno::Reference<css::frame::XModel> xModel,
     xPropSet->setPropertyValue(aName, css::uno::makeAny(nVal));
 }
 
-OUString getCID(css::uno::Reference<css::frame::XModel> xModel)
+OUString getCID(const css::uno::Reference<css::frame::XModel>& xModel)
 {
     css::uno::Reference<css::frame::XController> xController(xModel->getCurrentController());
     css::uno::Reference<css::view::XSelectionSupplier> xSelectionSupplier(xController, css::uno::UNO_QUERY);
diff --git a/chart2/source/controller/sidebar/ChartLinePanel.cxx b/chart2/source/controller/sidebar/ChartLinePanel.cxx
index 70c817e..6ed4862 100644
--- a/chart2/source/controller/sidebar/ChartLinePanel.cxx
+++ b/chart2/source/controller/sidebar/ChartLinePanel.cxx
@@ -35,7 +35,7 @@ SvxColorToolBoxControl* getColorToolBoxControl(sfx2::sidebar::SidebarToolBox* pT
     return pToolBoxColorControl;
 }
 
-OUString getCID(css::uno::Reference<css::frame::XModel> xModel)
+OUString getCID(const css::uno::Reference<css::frame::XModel>& xModel)
 {
     css::uno::Reference<css::frame::XController> xController(xModel->getCurrentController());
     css::uno::Reference<css::view::XSelectionSupplier> xSelectionSupplier(xController, css::uno::UNO_QUERY);
@@ -53,7 +53,7 @@ OUString getCID(css::uno::Reference<css::frame::XModel> xModel)
 }
 
 css::uno::Reference<css::beans::XPropertySet> getPropSet(
-        css::uno::Reference<css::frame::XModel> xModel)
+        const css::uno::Reference<css::frame::XModel>& xModel)
 {
     OUString aCID = getCID(xModel);
     css::uno::Reference<css::beans::XPropertySet> xPropSet =
@@ -74,7 +74,7 @@ css::uno::Reference<css::beans::XPropertySet> getPropSet(
 }
 
 css::uno::Any getLineDash(
-        css::uno::Reference<css::frame::XModel> xModel, const OUString& rDashName)
+        const css::uno::Reference<css::frame::XModel>& xModel, const OUString& rDashName)
 {
     css::uno::Reference<css::lang::XMultiServiceFactory> xFact(xModel, css::uno::UNO_QUERY);
     css::uno::Reference<css::container::XNameAccess> xNameAccess(

... etc. - the rest is truncated


More information about the Libreoffice-commits mailing list