diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-12-23 09:17:30 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-12-23 12:36:24 +0100 |
commit | a8c1c0ae1617c68d49deb33e9236a2c1b7cac14d (patch) | |
tree | dec7ceaca24da8340a911502fd42dd19efb882ff /include/vcl | |
parent | 38bf5f69663f64434a3a0a74e02c1a23f876b677 (diff) |
loplugin:passstuffbyref improved returns in vcl
Change-Id: I0b103df2e7ce59093869f547225c95865d33da27
Reviewed-on: https://gerrit.libreoffice.org/46916
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'include/vcl')
-rw-r--r-- | include/vcl/alpha.hxx | 2 | ||||
-rw-r--r-- | include/vcl/bitmapex.hxx | 4 | ||||
-rw-r--r-- | include/vcl/button.hxx | 2 | ||||
-rw-r--r-- | include/vcl/errinf.hxx | 2 | ||||
-rw-r--r-- | include/vcl/listctrl.hxx | 2 | ||||
-rw-r--r-- | include/vcl/svapp.hxx | 2 | ||||
-rw-r--r-- | include/vcl/toolbox.hxx | 2 |
7 files changed, 8 insertions, 8 deletions
diff --git a/include/vcl/alpha.hxx b/include/vcl/alpha.hxx index e21bcc3b0732..e3fd8ee43ec5 100644 --- a/include/vcl/alpha.hxx +++ b/include/vcl/alpha.hxx @@ -55,7 +55,7 @@ public: BitmapChecksum GetChecksum() const { return Bitmap::GetChecksum(); } - Bitmap GetBitmap() const; + Bitmap const & GetBitmap() const; bool Erase( sal_uInt8 cTransparency ); bool Replace( const Bitmap& rMask, sal_uInt8 rReplaceTransparency ); diff --git a/include/vcl/bitmapex.hxx b/include/vcl/bitmapex.hxx index c7a7bc7e2e59..a850572357e9 100644 --- a/include/vcl/bitmapex.hxx +++ b/include/vcl/bitmapex.hxx @@ -427,8 +427,8 @@ public: const Size &rSize ); public: - SAL_DLLPRIVATE std::shared_ptr<ImpBitmap> ImplGetBitmapImpBitmap() const { return aBitmap.ImplGetImpBitmap(); } - SAL_DLLPRIVATE std::shared_ptr<ImpBitmap> ImplGetMaskImpBitmap() const { return aMask.ImplGetImpBitmap(); } + SAL_DLLPRIVATE std::shared_ptr<ImpBitmap> const & ImplGetBitmapImpBitmap() const { return aBitmap.ImplGetImpBitmap(); } + SAL_DLLPRIVATE std::shared_ptr<ImpBitmap> const & ImplGetMaskImpBitmap() const { return aMask.ImplGetImpBitmap(); } private: diff --git a/include/vcl/button.hxx b/include/vcl/button.hxx index 3a4159d35392..29bcfdc10b65 100644 --- a/include/vcl/button.hxx +++ b/include/vcl/button.hxx @@ -77,7 +77,7 @@ public: /// Setup handler for UNO commands so that commands like .uno:Something are handled automagically by this button. void SetCommandHandler(const OUString& aCommand); - const OUString GetCommand() const { return maCommand; } + OUString const & GetCommand() const { return maCommand; } static OUString GetStandardText( StandardButtonType eButton ); diff --git a/include/vcl/errinf.hxx b/include/vcl/errinf.hxx index 4a3990b237ef..bc8c01a13e05 100644 --- a/include/vcl/errinf.hxx +++ b/include/vcl/errinf.hxx @@ -145,7 +145,7 @@ public: nUserId(nArgUserId) {} virtual ~ErrorInfo(); - ErrCode GetErrorCode() const { return nUserId; } + ErrCode const & GetErrorCode() const { return nUserId; } static ErrorInfo* GetErrorInfo(ErrCode); diff --git a/include/vcl/listctrl.hxx b/include/vcl/listctrl.hxx index 6659ccafb3ff..d640ad2c7ee6 100644 --- a/include/vcl/listctrl.hxx +++ b/include/vcl/listctrl.hxx @@ -44,7 +44,7 @@ public: virtual void dispose() override; void addEntry(VclPtr<vcl::Window> xEntry, sal_uInt32 nPos = std::numeric_limits<sal_uInt16>::max()); - std::vector<VclPtr<vcl::Window>> getEntries() const; + std::vector<VclPtr<vcl::Window>> const & getEntries() const; void deleteEntry(sal_uInt32 nPos); virtual Size GetOptimalSize() const override; diff --git a/include/vcl/svapp.hxx b/include/vcl/svapp.hxx index dd10349a41b2..0c81eeda5d8c 100644 --- a/include/vcl/svapp.hxx +++ b/include/vcl/svapp.hxx @@ -188,7 +188,7 @@ public: @returns The event's data string. */ - OUString GetStringData() const + OUString const & GetStringData() const { assert( aEvent == Type::Accept || aEvent == Type::Help diff --git a/include/vcl/toolbox.hxx b/include/vcl/toolbox.hxx index df9120f305d2..f49bcae6fd9a 100644 --- a/include/vcl/toolbox.hxx +++ b/include/vcl/toolbox.hxx @@ -355,7 +355,7 @@ public: sal_uInt16 GetItemId( const OUString& rCommand ) const; tools::Rectangle GetItemRect( sal_uInt16 nItemId ); tools::Rectangle GetItemPosRect( ImplToolItems::size_type nPos ); - tools::Rectangle GetOverflowRect() const; + tools::Rectangle const & GetOverflowRect() const; /// Returns size of the bitmap / text that is inside this toolbox item. Size GetItemContentSize( sal_uInt16 nItemId ); |