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

Chris Sherlock (via logerrit) logerrit at kemper.freedesktop.org
Fri Aug 27 11:29:58 UTC 2021


 include/vcl/outdev.hxx            |    5 -----
 vcl/source/outdev/outdevstate.cxx |    7 +------
 2 files changed, 1 insertion(+), 11 deletions(-)

New commits:
commit 6146409978e1a2834c85acff33485f69164ae735
Author:     Chris Sherlock <chris.sherlock79 at gmail.com>
AuthorDate: Wed May 12 18:25:33 2021 +1000
Commit:     Tomaž Vajngerl <quikee at gmail.com>
CommitDate: Fri Aug 27 13:29:25 2021 +0200

    vcl: remove unnecessary OutputDevice::GetGCStackDepth()
    
    Change-Id: I067299d028a0f25314a4312462ee8e7d0e1f92bb
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115464
    Tested-by: Jenkins
    Reviewed-by: Tomaž Vajngerl <quikee at gmail.com>

diff --git a/include/vcl/outdev.hxx b/include/vcl/outdev.hxx
index 7d4a7e533356..011fc5445e0c 100644
--- a/include/vcl/outdev.hxx
+++ b/include/vcl/outdev.hxx
@@ -463,11 +463,6 @@ public:
 
     void                        Push( PushFlags nFlags = PushFlags::ALL );
     void                        Pop();
-
-    // returns the current stack depth; that is the number of Push() calls minus the number of Pop() calls
-    // this should not normally be used since Push and Pop must always be used symmetrically
-    // however this may be e.g. a help when debugging code in which this somehow is not the case
-    sal_uInt32                  GetGCStackDepth() const;
     void                        ClearStack();
 
     void                        EnableOutput( bool bEnable = true );
diff --git a/vcl/source/outdev/outdevstate.cxx b/vcl/source/outdev/outdevstate.cxx
index 41ee775a84e6..108d57dff9e2 100644
--- a/vcl/source/outdev/outdevstate.cxx
+++ b/vcl/source/outdev/outdevstate.cxx
@@ -194,14 +194,9 @@ void OutputDevice::Pop()
     mpMetaFile = pOldMetaFile;
 }
 
-sal_uInt32 OutputDevice::GetGCStackDepth() const
-{
-    return maOutDevStateStack.size();
-}
-
 void OutputDevice::ClearStack()
 {
-    sal_uInt32 nCount = GetGCStackDepth();
+    sal_uInt32 nCount = maOutDevStateStack.size();
     while( nCount-- )
         Pop();
 }


More information about the Libreoffice-commits mailing list