[Libreoffice-commits] core.git: include/xmloff xmloff/source

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Wed Jan 23 09:44:50 UTC 2019


 include/xmloff/XMLTextListAutoStylePool.hxx     |    2 +-
 xmloff/source/text/XMLPropertyBackpatcher.cxx   |    9 ---------
 xmloff/source/text/XMLPropertyBackpatcher.hxx   |    6 ------
 xmloff/source/text/XMLTextListAutoStylePool.cxx |    2 +-
 4 files changed, 2 insertions(+), 17 deletions(-)

New commits:
commit ebd164d8a70657216d653a71cb31d872a147777e
Author:     Noel Grandin <noel.grandin at collabora.co.uk>
AuthorDate: Wed Jan 23 09:09:02 2019 +0200
Commit:     Noel Grandin <noel.grandin at collabora.co.uk>
CommitDate: Wed Jan 23 10:44:16 2019 +0100

    loplugin:constparams in xmloff
    
    Change-Id: I8874c9204b8bf8f422fb5bb826a340b787589360
    Reviewed-on: https://gerrit.libreoffice.org/66768
    Tested-by: Jenkins
    Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>

diff --git a/include/xmloff/XMLTextListAutoStylePool.hxx b/include/xmloff/XMLTextListAutoStylePool.hxx
index dc3690802b2a..9f40ac48de60 100644
--- a/include/xmloff/XMLTextListAutoStylePool.hxx
+++ b/include/xmloff/XMLTextListAutoStylePool.hxx
@@ -52,7 +52,7 @@ class XMLOFF_DLLPUBLIC XMLTextListAutoStylePool
         the NumRules don't have names */
     css::uno::Reference< css::ucb::XAnyCompare > mxNumRuleCompare;
 
-    SAL_DLLPRIVATE sal_uInt32 Find( XMLTextListAutoStylePoolEntry_Impl* pEntry )
+    SAL_DLLPRIVATE sal_uInt32 Find( const XMLTextListAutoStylePoolEntry_Impl* pEntry )
         const;
 public:
 
diff --git a/xmloff/source/text/XMLPropertyBackpatcher.cxx b/xmloff/source/text/XMLPropertyBackpatcher.cxx
index a9f245d7229e..e5f18a7b25c3 100644
--- a/xmloff/source/text/XMLPropertyBackpatcher.cxx
+++ b/xmloff/source/text/XMLPropertyBackpatcher.cxx
@@ -80,15 +80,6 @@ void XMLPropertyBackpatcher<A>::SetProperty(
     const Reference<XPropertySet> & xPropSet,
     const OUString& sName)
 {
-    Reference<XPropertySet> xNonConstPropSet(xPropSet);
-    SetProperty(xNonConstPropSet, sName);
-}
-
-template<class A>
-void XMLPropertyBackpatcher<A>::SetProperty(
-    Reference<XPropertySet> & xPropSet,
-    const OUString& sName)
-{
     if (aIDMap.count(sName))
     {
         // we know this ID -> set property
diff --git a/xmloff/source/text/XMLPropertyBackpatcher.hxx b/xmloff/source/text/XMLPropertyBackpatcher.hxx
index 029f25e66e4a..9cdda65f11d6 100644
--- a/xmloff/source/text/XMLPropertyBackpatcher.hxx
+++ b/xmloff/source/text/XMLPropertyBackpatcher.hxx
@@ -88,15 +88,9 @@ public:
     /// Set property with the proper value for this name. If the value
     /// is not yet known, store the XPropertySet in the backpatch list.
     /// Use this whenever the value should be set, even if it is not yet known.
-    /// const version
     void SetProperty(
         const css::uno::Reference<css::beans::XPropertySet> & xPropSet,
         const OUString& sName);
-
-    /// non-const version of SetProperty
-    void SetProperty(
-        css::uno::Reference<css::beans::XPropertySet> & xPropSet,
-        const OUString& sName);
 };
 
 #endif
diff --git a/xmloff/source/text/XMLTextListAutoStylePool.cxx b/xmloff/source/text/XMLTextListAutoStylePool.cxx
index 3736a201ca74..d77ad5e8e7c3 100644
--- a/xmloff/source/text/XMLTextListAutoStylePool.cxx
+++ b/xmloff/source/text/XMLTextListAutoStylePool.cxx
@@ -164,7 +164,7 @@ void XMLTextListAutoStylePool::RegisterName( const OUString& rName )
     m_aNames.insert(rName);
 }
 
-sal_uInt32 XMLTextListAutoStylePool::Find( XMLTextListAutoStylePoolEntry_Impl* pEntry ) const
+sal_uInt32 XMLTextListAutoStylePool::Find( const XMLTextListAutoStylePoolEntry_Impl* pEntry ) const
 {
     if( !pEntry->IsNamed() && mxNumRuleCompare.is() )
     {


More information about the Libreoffice-commits mailing list