diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-12-28 19:48:26 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-12-29 08:02:04 +0100 |
commit | e0eb09405b2f4d95532d37bc37054a51e5a0177b (patch) | |
tree | b88291ecf58898a0b42ac124fcecf95d7229e7a3 /svx | |
parent | 31f71635a136daf36d554e0c20db9ae0d1686c23 (diff) |
loplugin:passstuffbyref improved return in svx
Change-Id: I33bdbd416709ce46afb3c17aeab0d2e19a68ab30
Reviewed-on: https://gerrit.libreoffice.org/47150
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'svx')
-rw-r--r-- | svx/inc/galobj.hxx | 2 | ||||
-rw-r--r-- | svx/source/customshapes/EnhancedCustomShapeFunctionParser.cxx | 2 | ||||
-rw-r--r-- | svx/source/dialog/dlgctl3d.cxx | 2 | ||||
-rw-r--r-- | svx/source/dialog/framelinkarray.cxx | 4 | ||||
-rw-r--r-- | svx/source/form/dataaccessdescriptor.cxx | 2 | ||||
-rw-r--r-- | svx/source/gallery2/galobj.cxx | 2 | ||||
-rw-r--r-- | svx/source/sdr/attribute/sdrformtextattribute.cxx | 2 | ||||
-rw-r--r-- | svx/source/svdraw/sdrpagewindow.cxx | 4 | ||||
-rw-r--r-- | svx/source/svdraw/svdograf.cxx | 2 | ||||
-rw-r--r-- | svx/source/svdraw/svdomedia.cxx | 2 | ||||
-rw-r--r-- | svx/source/svdraw/svdoole2.cxx | 4 | ||||
-rw-r--r-- | svx/source/svdraw/svdotextdecomposition.cxx | 4 | ||||
-rw-r--r-- | svx/source/tbxctrls/tbcontrl.cxx | 2 | ||||
-rw-r--r-- | svx/source/unodraw/unoshape.cxx | 2 |
14 files changed, 18 insertions, 18 deletions
diff --git a/svx/inc/galobj.hxx b/svx/inc/galobj.hxx index aa0af5922553..5089d7439356 100644 --- a/svx/inc/galobj.hxx +++ b/svx/inc/galobj.hxx @@ -74,7 +74,7 @@ public: bool IsValid() const { return bIsValid; } bool IsThumbBitmap() const { return bIsThumbBmp; } - const OUString GetTitle() const; + OUString const & GetTitle() const; void SetTitle( const OUString& rTitle ); friend SvStream& WriteSgaObject( SvStream& rOut, const SgaObject& rObj ); diff --git a/svx/source/customshapes/EnhancedCustomShapeFunctionParser.cxx b/svx/source/customshapes/EnhancedCustomShapeFunctionParser.cxx index 4d2e3ffbbcfd..43de790937e3 100644 --- a/svx/source/customshapes/EnhancedCustomShapeFunctionParser.cxx +++ b/svx/source/customshapes/EnhancedCustomShapeFunctionParser.cxx @@ -1118,7 +1118,7 @@ const ParserContextSharedPtr& getParserContext() namespace EnhancedCustomShape { -std::shared_ptr<ExpressionNode> FunctionParser::parseFunction( const OUString& rFunction, const EnhancedCustomShape2d& rCustoShape ) +std::shared_ptr<ExpressionNode> const & FunctionParser::parseFunction( const OUString& rFunction, const EnhancedCustomShape2d& rCustoShape ) { // TODO(Q1): Check if a combination of the RTL_UNICODETOTEXT_FLAGS_* // gives better conversion robustness here (we might want to map space diff --git a/svx/source/dialog/dlgctl3d.cxx b/svx/source/dialog/dlgctl3d.cxx index 8deb3bbc8e6c..ce75eacf7991 100644 --- a/svx/source/dialog/dlgctl3d.cxx +++ b/svx/source/dialog/dlgctl3d.cxx @@ -230,7 +230,7 @@ void Svx3DPreviewControl::SetObjectType(SvxPreviewObjectType nType) } } -SfxItemSet Svx3DPreviewControl::Get3DAttributes() const +SfxItemSet const & Svx3DPreviewControl::Get3DAttributes() const { return mp3DObj->GetMergedItemSet(); } diff --git a/svx/source/dialog/framelinkarray.cxx b/svx/source/dialog/framelinkarray.cxx index c9273c41344f..560eefd775ce 100644 --- a/svx/source/dialog/framelinkarray.cxx +++ b/svx/source/dialog/framelinkarray.cxx @@ -76,7 +76,7 @@ public: void MirrorSelfX(); - basegfx::B2DHomMatrix CreateCoordinateSystem(const Array& rArray) const; + basegfx::B2DHomMatrix const & CreateCoordinateSystem(const Array& rArray) const; size_t GetCellIndex(const Array& rArray) const; }; @@ -93,7 +93,7 @@ size_t Cell::GetCellIndex(const Array& rArray) const return maCellIndex; } -basegfx::B2DHomMatrix Cell::CreateCoordinateSystem(const Array& rArray) const +basegfx::B2DHomMatrix const & Cell::CreateCoordinateSystem(const Array& rArray) const { if(!maCoordinateSystem.isIdentity()) { diff --git a/svx/source/form/dataaccessdescriptor.cxx b/svx/source/form/dataaccessdescriptor.cxx index e2c675c5b3ab..974c40334b9a 100644 --- a/svx/source/form/dataaccessdescriptor.cxx +++ b/svx/source/form/dataaccessdescriptor.cxx @@ -353,7 +353,7 @@ namespace svx m_pImpl->buildFrom(_rValues); } - Sequence< PropertyValue > ODataAccessDescriptor::createPropertyValueSequence() + Sequence< PropertyValue > const & ODataAccessDescriptor::createPropertyValueSequence() { m_pImpl->updateSequence(); return m_pImpl->m_aAsSequence; diff --git a/svx/source/gallery2/galobj.cxx b/svx/source/gallery2/galobj.cxx index a6ff2402b531..4bf26f7a13de 100644 --- a/svx/source/gallery2/galobj.cxx +++ b/svx/source/gallery2/galobj.cxx @@ -217,7 +217,7 @@ void SgaObject::ReadData(SvStream& rIn, sal_uInt16& rReadVersion ) aURL = INetURLObject(aTmpStr); } -const OUString SgaObject::GetTitle() const +OUString const & SgaObject::GetTitle() const { return aTitle; } diff --git a/svx/source/sdr/attribute/sdrformtextattribute.cxx b/svx/source/sdr/attribute/sdrformtextattribute.cxx index 1a2ff5325698..e0801737d599 100644 --- a/svx/source/sdr/attribute/sdrformtextattribute.cxx +++ b/svx/source/sdr/attribute/sdrformtextattribute.cxx @@ -347,7 +347,7 @@ namespace drawinglayer return mpSdrFormTextAttribute->getFormTextShadow(); } - Color SdrFormTextAttribute::getFormTextShdwColor() const + Color const & SdrFormTextAttribute::getFormTextShdwColor() const { return mpSdrFormTextAttribute->getFormTextShdwColor(); } diff --git a/svx/source/svdraw/sdrpagewindow.cxx b/svx/source/svdraw/sdrpagewindow.cxx index 9998c2fa5770..7c4ae6dc8c7a 100644 --- a/svx/source/svdraw/sdrpagewindow.cxx +++ b/svx/source/svdraw/sdrpagewindow.cxx @@ -65,7 +65,7 @@ struct SdrPageWindow::Impl }; -uno::Reference<awt::XControlContainer> SdrPageWindow::GetControlContainer( bool _bCreateIfNecessary ) const +uno::Reference<awt::XControlContainer> const & SdrPageWindow::GetControlContainer( bool _bCreateIfNecessary ) const { if (!mpImpl->mxControlContainer.is() && _bCreateIfNecessary) { @@ -162,7 +162,7 @@ const SdrPaintWindow* SdrPageWindow::GetOriginalPaintWindow() const } // OVERLAY MANAGER -rtl::Reference< sdr::overlay::OverlayManager > SdrPageWindow::GetOverlayManager() const +rtl::Reference< sdr::overlay::OverlayManager > const & SdrPageWindow::GetOverlayManager() const { return GetPaintWindow().GetOverlayManager(); } diff --git a/svx/source/svdraw/svdograf.cxx b/svx/source/svdraw/svdograf.cxx index 510426088b3f..30bd0a2d8692 100644 --- a/svx/source/svdraw/svdograf.cxx +++ b/svx/source/svdraw/svdograf.cxx @@ -578,7 +578,7 @@ void SdrGrafObj::SetGrafStreamURL( const OUString& rGraphicStreamURL ) } } -OUString SdrGrafObj::GetGrafStreamURL() const +OUString const & SdrGrafObj::GetGrafStreamURL() const { return pGraphic->GetUserData(); } diff --git a/svx/source/svdraw/svdomedia.cxx b/svx/source/svdraw/svdomedia.cxx index 785a3a0f73fb..974cf3b56300 100644 --- a/svx/source/svdraw/svdomedia.cxx +++ b/svx/source/svdraw/svdomedia.cxx @@ -158,7 +158,7 @@ SdrMediaObj& SdrMediaObj::operator=(const SdrMediaObj& rObj) return *this; } -const uno::Reference< graphic::XGraphic > SdrMediaObj::getSnapshot() const +uno::Reference< graphic::XGraphic > const & SdrMediaObj::getSnapshot() const { #if HAVE_FEATURE_AVMEDIA if( !m_xImpl->m_xCachedSnapshot.is() ) diff --git a/svx/source/svdraw/svdoole2.cxx b/svx/source/svdraw/svdoole2.cxx index a43c341193db..6ccff1fae000 100644 --- a/svx/source/svdraw/svdoole2.cxx +++ b/svx/source/svdraw/svdoole2.cxx @@ -1820,13 +1820,13 @@ void SdrOle2Obj::GetObjRef_Impl() GetSdrGlobalData().GetOLEObjCache().InsertObj(this); } -uno::Reference < embed::XEmbeddedObject > SdrOle2Obj::GetObjRef() const +uno::Reference < embed::XEmbeddedObject > const & SdrOle2Obj::GetObjRef() const { const_cast<SdrOle2Obj*>(this)->GetObjRef_Impl(); return mpImpl->mxObjRef.GetObject(); } -uno::Reference < embed::XEmbeddedObject > SdrOle2Obj::GetObjRef_NoInit() const +uno::Reference < embed::XEmbeddedObject > const & SdrOle2Obj::GetObjRef_NoInit() const { return mpImpl->mxObjRef.GetObject(); } diff --git a/svx/source/svdraw/svdotextdecomposition.cxx b/svx/source/svdraw/svdotextdecomposition.cxx index 940bdaad2205..7155bd15ab31 100644 --- a/svx/source/svdraw/svdotextdecomposition.cxx +++ b/svx/source/svdraw/svdotextdecomposition.cxx @@ -149,7 +149,7 @@ namespace mrOutliner.SetDrawBulletHdl(Link<DrawBulletInfo*,void>()); } - drawinglayer::primitive2d::Primitive2DContainer getPrimitive2DSequence(); + drawinglayer::primitive2d::Primitive2DContainer const & getPrimitive2DSequence(); }; bool impTextBreakupHandler::impIsUnderlineAbove(const vcl::Font& rFont) @@ -643,7 +643,7 @@ namespace } } - drawinglayer::primitive2d::Primitive2DContainer impTextBreakupHandler::getPrimitive2DSequence() + drawinglayer::primitive2d::Primitive2DContainer const & impTextBreakupHandler::getPrimitive2DSequence() { if(!maTextPortionPrimitives.empty()) { diff --git a/svx/source/tbxctrls/tbcontrl.cxx b/svx/source/tbxctrls/tbcontrl.cxx index d28befe5296a..8d6a3d9d1467 100644 --- a/svx/source/tbxctrls/tbcontrl.cxx +++ b/svx/source/tbxctrls/tbcontrl.cxx @@ -3423,7 +3423,7 @@ void SvxColorListBox::dispose() MenuButton::dispose(); } -VclPtr<SvxColorWindow> SvxColorListBox::getColorWindow() const +VclPtr<SvxColorWindow> const & SvxColorListBox::getColorWindow() const { if (!m_xColorWindow || m_xColorWindow->isDisposed()) const_cast<SvxColorListBox*>(this)->createColorWindow(); diff --git a/svx/source/unodraw/unoshape.cxx b/svx/source/unodraw/unoshape.cxx index fd9851588e3d..f61d4e384976 100644 --- a/svx/source/unodraw/unoshape.cxx +++ b/svx/source/unodraw/unoshape.cxx @@ -1367,7 +1367,7 @@ Reference< beans::XPropertySetInfo > SAL_CALL } } -Reference< beans::XPropertySetInfo > +Reference< beans::XPropertySetInfo > const & SvxShape::_getPropertySetInfo() { return mpPropSet->getPropertySetInfo(); |