[Libreoffice-commits] core.git: include/svl sc/inc sc/source svl/source sw/inc sw/source

Noel (via logerrit) logerrit at kemper.freedesktop.org
Fri Feb 26 12:11:31 UTC 2021


 include/svl/style.hxx             |    2 +-
 sc/inc/stlpool.hxx                |    2 +-
 sc/source/core/data/stlpool.cxx   |    2 +-
 svl/source/items/style.cxx        |    2 +-
 sw/inc/docstyle.hxx               |    2 +-
 sw/source/uibase/app/docstyle.cxx |    2 +-
 6 files changed, 6 insertions(+), 6 deletions(-)

New commits:
commit f77250f3159ec58f8d7d2770496fac64536b4f6f
Author:     Noel <noel.grandin at collabora.co.uk>
AuthorDate: Thu Feb 25 15:14:18 2021 +0200
Commit:     Noel Grandin <noel.grandin at collabora.co.uk>
CommitDate: Fri Feb 26 13:10:49 2021 +0100

    loplugin:refcounting in svl
    
    Change-Id: I0009464121faf6dd36793b031d892f492b56187c
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111544
    Tested-by: Jenkins
    Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>

diff --git a/include/svl/style.hxx b/include/svl/style.hxx
index bd1b0adb0790..735e3607242d 100644
--- a/include/svl/style.hxx
+++ b/include/svl/style.hxx
@@ -238,7 +238,7 @@ protected:
 
     void                        ChangeParent(std::u16string_view rOld, const OUString& rNew, SfxStyleFamily eFamily, bool bVirtual = true);
     virtual rtl::Reference<SfxStyleSheetBase> Create( const OUString&, SfxStyleFamily, SfxStyleSearchBits );
-    virtual SfxStyleSheetBase*  Create( const SfxStyleSheetBase& );
+    virtual rtl::Reference<SfxStyleSheetBase>  Create( const SfxStyleSheetBase& );
 
     virtual                     ~SfxStyleSheetBasePool() override;
 
diff --git a/sc/inc/stlpool.hxx b/sc/inc/stlpool.hxx
index b4a5c312d6ea..e6d816096d9d 100644
--- a/sc/inc/stlpool.hxx
+++ b/sc/inc/stlpool.hxx
@@ -66,7 +66,7 @@ private:
     virtual rtl::Reference<SfxStyleSheetBase> Create( const OUString&  rName,
                                        SfxStyleFamily   eFamily,
                                        SfxStyleSearchBits     nMask) override;
-    virtual SfxStyleSheetBase* Create( const SfxStyleSheetBase& rStyle ) override;
+    virtual rtl::Reference<SfxStyleSheetBase> Create( const SfxStyleSheetBase& rStyle ) override;
 
     SfxStyleSheetBase*  pActualStyleSheet;
     ScDocument*         pDoc;
diff --git a/sc/source/core/data/stlpool.cxx b/sc/source/core/data/stlpool.cxx
index 3654799790da..b4074c1773b5 100644
--- a/sc/source/core/data/stlpool.cxx
+++ b/sc/source/core/data/stlpool.cxx
@@ -107,7 +107,7 @@ rtl::Reference<SfxStyleSheetBase> ScStyleSheetPool::Create( const OUString&   rN
     return pSheet;
 }
 
-SfxStyleSheetBase* ScStyleSheetPool::Create( const SfxStyleSheetBase& rStyle )
+rtl::Reference<SfxStyleSheetBase> ScStyleSheetPool::Create( const SfxStyleSheetBase& rStyle )
 {
     OSL_ENSURE( rStyle.isScStyleSheet(), "Invalid StyleSheet-class! :-/" );
     return new ScStyleSheet( static_cast<const ScStyleSheet&>(rStyle) );
diff --git a/svl/source/items/style.cxx b/svl/source/items/style.cxx
index 5b430259de2a..a053044b7de9 100644
--- a/svl/source/items/style.cxx
+++ b/svl/source/items/style.cxx
@@ -615,7 +615,7 @@ rtl::Reference<SfxStyleSheetBase> SfxStyleSheetBasePool::Create
     return new SfxStyleSheetBase( rName, this, eFam, mask );
 }
 
-SfxStyleSheetBase* SfxStyleSheetBasePool::Create( const SfxStyleSheetBase& r )
+rtl::Reference<SfxStyleSheetBase> SfxStyleSheetBasePool::Create( const SfxStyleSheetBase& r )
 {
     return new SfxStyleSheetBase( r );
 }
diff --git a/sw/inc/docstyle.hxx b/sw/inc/docstyle.hxx
index 90ad2f61ff7c..3ac7b308315d 100644
--- a/sw/inc/docstyle.hxx
+++ b/sw/inc/docstyle.hxx
@@ -198,7 +198,7 @@ class SwDocStyleSheetPool : public SfxStyleSheetBasePool
     bool                bOrganizer : 1;     ///< Organizer
 
     virtual rtl::Reference<SfxStyleSheetBase> Create( const OUString&, SfxStyleFamily, SfxStyleSearchBits nMask) override;
-    virtual SfxStyleSheetBase* Create( const SfxStyleSheetBase& ) override;
+    virtual rtl::Reference<SfxStyleSheetBase> Create( const SfxStyleSheetBase& ) override;
 
     using SfxStyleSheetBasePool::Find;
 
diff --git a/sw/source/uibase/app/docstyle.cxx b/sw/source/uibase/app/docstyle.cxx
index 102afc1a3253..e173eddfbc3d 100644
--- a/sw/source/uibase/app/docstyle.cxx
+++ b/sw/source/uibase/app/docstyle.cxx
@@ -2428,7 +2428,7 @@ SfxStyleSheetBase&   SwDocStyleSheetPool::Make( const OUString&   rName,
     return *mxStyleSheet;
 }
 
-SfxStyleSheetBase*   SwDocStyleSheetPool::Create( const SfxStyleSheetBase& /*rOrg*/)
+rtl::Reference<SfxStyleSheetBase> SwDocStyleSheetPool::Create( const SfxStyleSheetBase& /*rOrg*/)
 {
     OSL_ENSURE(false , "Create in SW-Stylesheet-Pool not possible" );
     return nullptr;


More information about the Libreoffice-commits mailing list