[Libreoffice-commits] core.git: vcl/inc vcl/source

Stephan Bergmann (via logerrit) logerrit at kemper.freedesktop.org
Wed Nov 18 15:24:33 UTC 2020


 vcl/inc/graphic/Manager.hxx    |    3 +--
 vcl/source/graphic/Manager.cxx |   17 ++++++++---------
 2 files changed, 9 insertions(+), 11 deletions(-)

New commits:
commit 5ec0eb98ce870b5da5ef1711b93b09edf36170bd
Author:     Stephan Bergmann <sbergman at redhat.com>
AuthorDate: Wed Nov 18 11:13:40 2020 +0100
Commit:     Stephan Bergmann <sbergman at redhat.com>
CommitDate: Wed Nov 18 16:23:44 2020 +0100

    Remove unused Manager::registerGraphic rsContext parameter
    
    unused ever since the code was introduced in
    a2b53fece14f745853bcfe1a300c3dceb580e148 "vcl: Add a internal (memory) manager
    for Graphic objects"
    
    Change-Id: I0e16983e7f34cded77435ae12d8adf0c3eee5f11
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106048
    Tested-by: Jenkins
    Reviewed-by: Stephan Bergmann <sbergman at redhat.com>

diff --git a/vcl/inc/graphic/Manager.hxx b/vcl/inc/graphic/Manager.hxx
index 51b68d95c4c4..bff72780cbd7 100644
--- a/vcl/inc/graphic/Manager.hxx
+++ b/vcl/inc/graphic/Manager.hxx
@@ -40,8 +40,7 @@ private:
 
     Manager();
 
-    void registerGraphic(const std::shared_ptr<ImpGraphic>& rImpGraphic,
-                         std::u16string_view rsContext);
+    void registerGraphic(const std::shared_ptr<ImpGraphic>& rImpGraphic);
 
     DECL_LINK(SwapOutTimerHandler, Timer*, void);
 
diff --git a/vcl/source/graphic/Manager.cxx b/vcl/source/graphic/Manager.cxx
index 6bcd709480e8..88e1f6e622df 100644
--- a/vcl/source/graphic/Manager.cxx
+++ b/vcl/source/graphic/Manager.cxx
@@ -124,8 +124,7 @@ IMPL_LINK(Manager, SwapOutTimerHandler, Timer*, pTimer, void)
     pTimer->Start();
 }
 
-void Manager::registerGraphic(const std::shared_ptr<ImpGraphic>& pImpGraphic,
-                              std::u16string_view /*rsContext*/)
+void Manager::registerGraphic(const std::shared_ptr<ImpGraphic>& pImpGraphic)
 {
     std::scoped_lock<std::recursive_mutex> aGuard(maMutex);
 
@@ -167,28 +166,28 @@ void Manager::unregisterGraphic(ImpGraphic* pImpGraphic)
 std::shared_ptr<ImpGraphic> Manager::copy(std::shared_ptr<ImpGraphic> const& rImpGraphicPtr)
 {
     auto pReturn = std::make_shared<ImpGraphic>(*rImpGraphicPtr);
-    registerGraphic(pReturn, u"Copy");
+    registerGraphic(pReturn);
     return pReturn;
 }
 
 std::shared_ptr<ImpGraphic> Manager::newInstance()
 {
     auto pReturn = std::make_shared<ImpGraphic>();
-    registerGraphic(pReturn, u"Empty");
+    registerGraphic(pReturn);
     return pReturn;
 }
 
 std::shared_ptr<ImpGraphic> Manager::newInstance(const BitmapEx& rBitmapEx)
 {
     auto pReturn = std::make_shared<ImpGraphic>(rBitmapEx);
-    registerGraphic(pReturn, u"BitmapEx");
+    registerGraphic(pReturn);
     return pReturn;
 }
 
 std::shared_ptr<ImpGraphic> Manager::newInstance(const Animation& rAnimation)
 {
     auto pReturn = std::make_shared<ImpGraphic>(rAnimation);
-    registerGraphic(pReturn, u"Animation");
+    registerGraphic(pReturn);
     return pReturn;
 }
 
@@ -196,21 +195,21 @@ std::shared_ptr<ImpGraphic>
 Manager::newInstance(const std::shared_ptr<VectorGraphicData>& rVectorGraphicDataPtr)
 {
     auto pReturn = std::make_shared<ImpGraphic>(rVectorGraphicDataPtr);
-    registerGraphic(pReturn, u"VectorGraphic");
+    registerGraphic(pReturn);
     return pReturn;
 }
 
 std::shared_ptr<ImpGraphic> Manager::newInstance(const GDIMetaFile& rMetaFile)
 {
     auto pReturn = std::make_shared<ImpGraphic>(rMetaFile);
-    registerGraphic(pReturn, u"Metafile");
+    registerGraphic(pReturn);
     return pReturn;
 }
 
 std::shared_ptr<ImpGraphic> Manager::newInstance(const GraphicExternalLink& rGraphicLink)
 {
     auto pReturn = std::make_shared<ImpGraphic>(rGraphicLink);
-    registerGraphic(pReturn, u"GraphicExternalLink");
+    registerGraphic(pReturn);
     return pReturn;
 }
 


More information about the Libreoffice-commits mailing list