diff options
author | Noel Grandin <noel@peralex.com> | 2016-04-14 09:23:37 +0200 |
---|---|---|
committer | Noel Grandin <noelgrandin@gmail.com> | 2016-04-14 08:23:20 +0000 |
commit | d8644c8edb405abd9d71e62e43e898c1d2a28fd2 (patch) | |
tree | 1d9f5e17b3f1a53cad84f2a3a1fe0875ec54d20b /include | |
parent | 6656693836a382e6dac3a8c7ae794517b5f92bcc (diff) |
loplugin:passstuffbyref in vcl
Change-Id: I17a4dc73c3fc81b0bfebdf442021af65f8f6166c
Reviewed-on: https://gerrit.libreoffice.org/24075
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/vcl/FilterConfigItem.hxx | 2 | ||||
-rw-r--r-- | include/vcl/bitmap.hxx | 2 | ||||
-rw-r--r-- | include/vcl/builder.hxx | 2 | ||||
-rw-r--r-- | include/vcl/dockwin.hxx | 2 | ||||
-rw-r--r-- | include/vcl/field.hxx | 8 | ||||
-rw-r--r-- | include/vcl/graph.hxx | 2 | ||||
-rw-r--r-- | include/vcl/longcurr.hxx | 12 | ||||
-rw-r--r-- | include/vcl/pdfextoutdevdata.hxx | 2 | ||||
-rw-r--r-- | include/vcl/syswin.hxx | 2 | ||||
-rw-r--r-- | include/vcl/texteng.hxx | 2 | ||||
-rw-r--r-- | include/vcl/vclevent.hxx | 2 | ||||
-rw-r--r-- | include/vcl/window.hxx | 6 |
12 files changed, 22 insertions, 22 deletions
diff --git a/include/vcl/FilterConfigItem.hxx b/include/vcl/FilterConfigItem.hxx index f12eec5b9016..61bf5e366fd5 100644 --- a/include/vcl/FilterConfigItem.hxx +++ b/include/vcl/FilterConfigItem.hxx @@ -79,7 +79,7 @@ public: void WriteBool( const OUString& rKey, bool bValue ); void WriteInt32( const OUString& rKey, sal_Int32 nValue ); - css::uno::Sequence< css::beans::PropertyValue > GetFilterData() const { return aFilterData;} + const css::uno::Sequence< css::beans::PropertyValue >& GetFilterData() const { return aFilterData;} // GetStatusIndicator is returning the "StatusIndicator" property of the FilterData sequence css::uno::Reference< css::task::XStatusIndicator > GetStatusIndicator() const; diff --git a/include/vcl/bitmap.hxx b/include/vcl/bitmap.hxx index e534d200e085..31811b9c4fd0 100644 --- a/include/vcl/bitmap.hxx +++ b/include/vcl/bitmap.hxx @@ -717,7 +717,7 @@ public: public: SAL_DLLPRIVATE void ImplMakeUnique(); - std::shared_ptr<ImpBitmap> ImplGetImpBitmap() const { return mxImpBmp;} + const std::shared_ptr<ImpBitmap>& ImplGetImpBitmap() const { return mxImpBmp; } SAL_DLLPRIVATE void ImplSetImpBitmap( const std::shared_ptr<ImpBitmap>& xImpBmp ); SAL_DLLPRIVATE void ImplAssignWithSize( const Bitmap& rBitmap ); diff --git a/include/vcl/builder.hxx b/include/vcl/builder.hxx index 1af5bc5628d2..928e51229677 100644 --- a/include/vcl/builder.hxx +++ b/include/vcl/builder.hxx @@ -106,7 +106,7 @@ public: static void reorderWithinParent(std::vector< vcl::Window*>& rChilds, bool bIsButtonBox); static void reorderWithinParent(vcl::Window &rWindow, sal_uInt16 nNewPosition); - css::uno::Reference<css::frame::XFrame> getFrame() { return m_xFrame; } + const css::uno::Reference<css::frame::XFrame>& getFrame() { return m_xFrame; } private: VclBuilder(const VclBuilder&) = delete; diff --git a/include/vcl/dockwin.hxx b/include/vcl/dockwin.hxx index e126c3ea407c..48413b4c9584 100644 --- a/include/vcl/dockwin.hxx +++ b/include/vcl/dockwin.hxx @@ -135,7 +135,7 @@ public: void ToggleFloatingMode(); void SetDragArea( const Rectangle& rRect ); - Rectangle GetDragArea() const { return maDragArea;} + const Rectangle& GetDragArea() const { return maDragArea;} void Lock(); void Unlock(); diff --git a/include/vcl/field.hxx b/include/vcl/field.hxx index 62db9fb204ac..75f82070f78d 100644 --- a/include/vcl/field.hxx +++ b/include/vcl/field.hxx @@ -586,9 +586,9 @@ public: virtual void Last() override; void SetFirst( const Date& rNewFirst ) { maFirst = rNewFirst; } - Date GetFirst() const { return maFirst; } + const Date& GetFirst() const { return maFirst; } void SetLast( const Date& rNewLast ) { maLast = rNewLast; } - Date GetLast() const { return maLast; } + const Date& GetLast() const { return maLast; } virtual void dispose() override; }; @@ -617,9 +617,9 @@ public: virtual void Last() override; void SetFirst( const tools::Time& rNewFirst ) { maFirst = rNewFirst; } - tools::Time GetFirst() const { return maFirst; } + const tools::Time& GetFirst() const { return maFirst; } void SetLast( const tools::Time& rNewLast ) { maLast = rNewLast; } - tools::Time GetLast() const { return maLast; } + const tools::Time& GetLast() const { return maLast; } void SetExtFormat( ExtTimeFieldFormat eFormat ); virtual void dispose() override; diff --git a/include/vcl/graph.hxx b/include/vcl/graph.hxx index 6f71d24924f9..da73cc6a070d 100644 --- a/include/vcl/graph.hxx +++ b/include/vcl/graph.hxx @@ -99,7 +99,7 @@ public: } // data read access - const Size getSizePixel() const { return maSizePixel; } + const Size& getSizePixel() const { return maSizePixel; } bool getUnlimitedSize() const { return mbUnlimitedSize; } bool getAntiAliase() const { return mbAntiAliase; } bool getSnapHorVerLines() const { return mbSnapHorVerLines; } diff --git a/include/vcl/longcurr.hxx b/include/vcl/longcurr.hxx index 8b40478d904b..48eca605c0f4 100644 --- a/include/vcl/longcurr.hxx +++ b/include/vcl/longcurr.hxx @@ -58,12 +58,12 @@ public: OUString GetCurrencySymbol() const; void SetMin(const BigInt& rNewMin); - BigInt GetMin() const { return mnMin; } + const BigInt& GetMin() const { return mnMin; } void SetMax(const BigInt& rNewMax); - BigInt GetMax() const { return mnMax; } + const BigInt& GetMax() const { return mnMax; } void SetDecimalDigits( sal_uInt16 nDigits ); - sal_uInt16 GetDecimalDigits() const { return mnDecimalDigits;} + sal_uInt16 GetDecimalDigits() const { return mnDecimalDigits;} void SetValue(const BigInt& rNewValue); void SetUserValue( BigInt nNewValue ); BigInt GetValue() const; @@ -92,11 +92,11 @@ public: void Last() override; void SetFirst(const BigInt& rNewFirst ) { mnFirst = rNewFirst; } - BigInt GetFirst() const { return mnFirst; } + const BigInt& GetFirst() const { return mnFirst; } void SetLast(const BigInt& rNewLast ) { mnLast = rNewLast; } - BigInt GetLast() const { return mnLast; } + const BigInt& GetLast() const { return mnLast; } void SetSpinSize(const BigInt& rNewSize) { mnSpinSize = rNewSize; } - BigInt GetSpinSize() const { return mnSpinSize; } + const BigInt& GetSpinSize() const { return mnSpinSize; } }; diff --git a/include/vcl/pdfextoutdevdata.hxx b/include/vcl/pdfextoutdevdata.hxx index 9ba411e5acde..08ea93780ded 100644 --- a/include/vcl/pdfextoutdevdata.hxx +++ b/include/vcl/pdfextoutdevdata.hxx @@ -152,7 +152,7 @@ public: std::vector< PDFExtOutDevBookmarkEntry >& GetBookmarks() { return maBookmarks;} - Graphic GetCurrentGraphic() const; + const Graphic& GetCurrentGraphic() const; /** Start a new group of render output diff --git a/include/vcl/syswin.hxx b/include/vcl/syswin.hxx index e6b637b28589..49f7c89e1d9e 100644 --- a/include/vcl/syswin.hxx +++ b/include/vcl/syswin.hxx @@ -214,7 +214,7 @@ public: bool IsRollUp() const { return mbRollUp; } void SetRollUpOutputSizePixel( const Size& rSize ) { maRollUpOutSize = rSize; } - Size GetRollUpOutputSizePixel() const { return maRollUpOutSize; } + const Size& GetRollUpOutputSizePixel() const { return maRollUpOutSize; } void SetMinOutputSizePixel( const Size& rSize ); const Size& GetMinOutputSizePixel() const { return maMinOutSize; } diff --git a/include/vcl/texteng.hxx b/include/vcl/texteng.hxx index 988bd3c35988..c440659e6426 100644 --- a/include/vcl/texteng.hxx +++ b/include/vcl/texteng.hxx @@ -314,7 +314,7 @@ public: static bool DoesKeyChangeText( const KeyEvent& rKeyEvent ); static bool IsSimpleCharInput( const KeyEvent& rKeyEvent ); - Color GetTextColor() const { return maTextColor; } + const Color& GetTextColor() const { return maTextColor; } }; #endif // INCLUDED_VCL_TEXTENG_HXX diff --git a/include/vcl/vclevent.hxx b/include/vcl/vclevent.hxx index 4d15991c011b..83bcd5721009 100644 --- a/include/vcl/vclevent.hxx +++ b/include/vcl/vclevent.hxx @@ -238,7 +238,7 @@ class VCL_DLLPUBLIC VclAccessibleEvent: public VclSimpleEvent public: VclAccessibleEvent( sal_uLong n, const css::uno::Reference< css::accessibility::XAccessible >& rxAccessible ); virtual ~VclAccessibleEvent(); - css::uno::Reference< css::accessibility::XAccessible > GetAccessible() const { return mxAccessible;} + const css::uno::Reference< css::accessibility::XAccessible >& GetAccessible() const { return mxAccessible;} private: css::uno::Reference< css::accessibility::XAccessible > mxAccessible; diff --git a/include/vcl/window.hxx b/include/vcl/window.hxx index 4c22c617e831..11dc971e0fc9 100644 --- a/include/vcl/window.hxx +++ b/include/vcl/window.hxx @@ -931,13 +931,13 @@ public: void SetControlForeground(); void SetControlForeground(const Color& rColor); - Color GetControlForeground() const; + const Color& GetControlForeground() const; bool IsControlForeground() const; void ApplyControlForeground(vcl::RenderContext& rRenderContext, const Color& rDefaultColor); void SetControlBackground(); void SetControlBackground( const Color& rColor ); - Color GetControlBackground() const; + const Color& GetControlBackground() const; bool IsControlBackground() const; void ApplyControlBackground(vcl::RenderContext& rRenderContext, const Color& rDefaultColor); @@ -1516,7 +1516,7 @@ public: */ void add_mnemonic_label(FixedText *pLabel); void remove_mnemonic_label(FixedText *pLabel); - std::vector<VclPtr<FixedText> > list_mnemonic_labels() const; + const std::vector<VclPtr<FixedText> >& list_mnemonic_labels() const; /* * Move this widget to be the nNewPosition'd child of its parent |