diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2024-11-06 13:39:33 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2024-11-06 15:45:24 +0100 |
commit | a6c3f0b62a53692efcc4056fdaade9263e200756 (patch) | |
tree | 6fde89683d83cb263dd5e90b8634cfc3c9eb1f28 /include/svx | |
parent | d5b55513cdc05e8d622897201e233eb0ad5147b7 (diff) |
loplugin:passstuffbyref in svx
Change-Id: Ic5fd72cb64208c278ffc129591cd3d1131efdc08
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/176137
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'include/svx')
-rw-r--r-- | include/svx/PaletteManager.hxx | 2 | ||||
-rw-r--r-- | include/svx/annotation/Annotation.hxx | 12 | ||||
-rw-r--r-- | include/svx/colorbox.hxx | 2 | ||||
-rw-r--r-- | include/svx/hdft.hxx | 4 | ||||
-rw-r--r-- | include/svx/numvset.hxx | 2 | ||||
-rw-r--r-- | include/svx/svdoole2.hxx | 2 | ||||
-rw-r--r-- | include/svx/svdotable.hxx | 2 | ||||
-rw-r--r-- | include/svx/svxdlg.hxx | 2 |
8 files changed, 14 insertions, 14 deletions
diff --git a/include/svx/PaletteManager.hxx b/include/svx/PaletteManager.hxx index 5882a7c465b7..5dd053f5a227 100644 --- a/include/svx/PaletteManager.hxx +++ b/include/svx/PaletteManager.hxx @@ -68,7 +68,7 @@ public: sal_Int32 GetPalette() const; sal_Int32 GetPaletteCount() const { return mnNumOfPalettes; } OUString GetPaletteName(); - OUString GetSelectedPalettePath(); + const OUString & GetSelectedPalettePath(); tools::Long GetColorCount() const; tools::Long GetRecentColorCount() const; diff --git a/include/svx/annotation/Annotation.hxx b/include/svx/annotation/Annotation.hxx index ba2021a70ec6..3e442dc90d73 100644 --- a/include/svx/annotation/Annotation.hxx +++ b/include/svx/annotation/Annotation.hxx @@ -135,19 +135,19 @@ public: } // Changes without triggering notification broadcast - css::geometry::RealPoint2D GetPosition() const { return m_Position; } + const css::geometry::RealPoint2D& GetPosition() const { return m_Position; } void SetPosition(const css::geometry::RealPoint2D& rValue) { m_Position = rValue; } - css::geometry::RealSize2D GetSize() const { return m_Size; } + const css::geometry::RealSize2D& GetSize() const { return m_Size; } void SetSize(const css::geometry::RealSize2D& rValue) { m_Size = rValue; } - OUString GetAuthor() const { return m_Author; } + const OUString& GetAuthor() const { return m_Author; } void SetAuthor(const OUString& rValue) { m_Author = rValue; } - OUString GetInitials() const { return m_Initials; } + const OUString& GetInitials() const { return m_Initials; } void SetInitials(const OUString& rValue) { m_Initials = rValue; } - css::util::DateTime GetDateTime() const { return m_DateTime; } + const css::util::DateTime& GetDateTime() const { return m_DateTime; } void SetDateTime(const css::util::DateTime& rValue) { m_DateTime = rValue; } virtual css::uno::Reference<css::text::XText> SAL_CALL getTextRange() override; @@ -160,7 +160,7 @@ public: OUString GetText(); void SetText(OUString const& rText); - rtl::Reference<sdr::annotation::TextApiObject> getTextApiObject() { return m_TextRange; } + const rtl::Reference<sdr::annotation::TextApiObject>& getTextApiObject() { return m_TextRange; } SdrModel* GetModel() const; SdrPage const* getPage() const { return mpPage; } diff --git a/include/svx/colorbox.hxx b/include/svx/colorbox.hxx index fe134531d39a..04d1c740f2ff 100644 --- a/include/svx/colorbox.hxx +++ b/include/svx/colorbox.hxx @@ -63,7 +63,7 @@ public: void SetSlotId(sal_uInt16 nSlotId, bool bShowNoneButton = false); Color const& GetSelectEntryColor() const { return m_aSelectedColor.m_aColor; } - NamedColor GetSelectedEntry() const { return m_aSelectedColor; } + const NamedColor& GetSelectedEntry() const { return m_aSelectedColor; } const NamedColor& GetSelectedEntryThemedColor() const { return m_aSelectedColor; } void SelectEntry(const NamedColor& rColor); diff --git a/include/svx/hdft.hxx b/include/svx/hdft.hxx index 6890e23fc78b..091137eed358 100644 --- a/include/svx/hdft.hxx +++ b/include/svx/hdft.hxx @@ -97,7 +97,7 @@ class SVX_DLLPUBLIC SvxHeaderPage final : public SvxHFPage public: static std::unique_ptr<SfxTabPage> Create( weld::Container* pPage, weld::DialogController* pController, const SfxItemSet* rSet ); // returns the Which values to the range - static WhichRangesContainer GetRanges() { return pRanges; } + static const WhichRangesContainer & GetRanges() { return pRanges; } SVX_DLLPRIVATE SvxHeaderPage(weld::Container* pPage, weld::DialogController* pController, const SfxItemSet& rSet); }; @@ -105,7 +105,7 @@ class SVX_DLLPUBLIC SvxFooterPage final : public SvxHFPage { public: static std::unique_ptr<SfxTabPage> Create( weld::Container* pPage, weld::DialogController* pController, const SfxItemSet* rSet ); - static WhichRangesContainer GetRanges() { return pRanges; } + static const WhichRangesContainer & GetRanges() { return pRanges; } SVX_DLLPRIVATE SvxFooterPage(weld::Container* pPage, weld::DialogController* pController, const SfxItemSet& rSet); }; diff --git a/include/svx/numvset.hxx b/include/svx/numvset.hxx index 7b96ffa6ee01..d54ad8f17a19 100644 --- a/include/svx/numvset.hxx +++ b/include/svx/numvset.hxx @@ -86,7 +86,7 @@ public: css::uno::Reference<css::text::XNumberingFormatter> const & xFormatter, const css::lang::Locale& rLocale); - std::vector<std::pair<OUString, OUString>> GetCustomBullets() { return maCustomBullets; } + const std::vector<std::pair<OUString, OUString>> & GetCustomBullets() { return maCustomBullets; } void SetCustomBullets(const std::vector<std::pair<OUString, OUString>>& rCustomBullets); virtual FactoryFunction GetUITestFactory() const override; diff --git a/include/svx/svdoole2.hxx b/include/svx/svdoole2.hxx index 1f89c237c1e8..aa56e05f3e0c 100644 --- a/include/svx/svdoole2.hxx +++ b/include/svx/svdoole2.hxx @@ -172,7 +172,7 @@ public: void SetGraphicToObj( const css::uno::Reference< css::io::XInputStream >& xGrStream, const OUString& aMediaType ); - css::uno::Reference< css::frame::XModel > GetParentXModel() const; + const css::uno::Reference< css::frame::XModel > & GetParentXModel() const; bool CalculateNewScaling( Fraction& aScaleWidth, Fraction& aScaleHeight, Size& aObjAreaSize ); bool AddOwnLightClient(); diff --git a/include/svx/svdotable.hxx b/include/svx/svdotable.hxx index e22ef60a48b7..54688c17e499 100644 --- a/include/svx/svdotable.hxx +++ b/include/svx/svdotable.hxx @@ -118,7 +118,7 @@ public: css::uno::Reference< css::table::XTable > getTable() const; /// Get the concrete UNO class for the table - rtl::Reference< sdr::table::TableModel > getUnoTable() const; + const rtl::Reference< sdr::table::TableModel > & getUnoTable() const; bool isValid( const sdr::table::CellPos& rPos ) const; static CellPos getFirstCell(); diff --git a/include/svx/svxdlg.hxx b/include/svx/svxdlg.hxx index b92adec13b3d..a2ef0c03a47e 100644 --- a/include/svx/svxdlg.hxx +++ b/include/svx/svxdlg.hxx @@ -55,7 +55,7 @@ class SdrObject; class SvxSpellWrapper; struct FmSearchContext; -typedef WhichRangesContainer (*DialogGetRanges)(); +typedef const WhichRangesContainer & (*DialogGetRanges)(); typedef ::std::vector< OUString > TargetList; |