[Libreoffice-commits] .: svx/source

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Tue Oct 23 12:55:27 PDT 2012


 svx/source/svdraw/svdoashp.cxx |    8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

New commits:
commit 1d77d4eada214e14938336070b248c18705939ff
Author: Ivan Timofeev <timofeev.i.s at gmail.com>
Date:   Tue Oct 23 23:54:08 2012 +0400

    typo, wrong object was returned
    
    Change-Id: Ibcb45d7f0ad3f9469c61809528d7542a80d406b7

diff --git a/svx/source/svdraw/svdoashp.cxx b/svx/source/svdraw/svdoashp.cxx
index 7020d6b..e3b69ad 100644
--- a/svx/source/svdraw/svdoashp.cxx
+++ b/svx/source/svdraw/svdoashp.cxx
@@ -100,7 +100,7 @@ using namespace ::com::sun::star::drawing;
 // A simple one item cache really helps here ...
 namespace {
     static const SdrObjCustomShape *g_pLastCacheShape;
-    static Reference< XCustomShapeEngine > g_xLastCacheShape;
+    static Reference< XCustomShapeEngine > g_xLastCacheShapeEngine;
 }
 
 static void lcl_ShapeSegmentFromBinary( EnhancedCustomShapeSegment& rSegInfo, sal_uInt16 nSDat )
@@ -411,7 +411,7 @@ Reference< XCustomShapeEngine > SdrObjCustomShape::GetCustomShapeEngine( const S
 
     // We get dozens of back-to-back calls for the same shape
     if( pCustomShape == g_pLastCacheShape )
-        return xCustomShapeEngine;
+        return g_xLastCacheShapeEngine;
 
     String aEngine(((SdrCustomShapeEngineItem&)pCustomShape->GetMergedItem( SDRATTR_CUSTOMSHAPE_ENGINE )).GetValue());
     if ( !aEngine.Len() )
@@ -436,7 +436,7 @@ Reference< XCustomShapeEngine > SdrObjCustomShape::GetCustomShapeEngine( const S
     }
 
     g_pLastCacheShape = pCustomShape;
-    g_xLastCacheShape = xCustomShapeEngine;
+    g_xLastCacheShapeEngine = xCustomShapeEngine;
 
     return xCustomShapeEngine;
 }
@@ -868,7 +868,7 @@ SdrObjCustomShape::~SdrObjCustomShape()
     if (this == g_pLastCacheShape)
     {
         g_pLastCacheShape = NULL;
-        g_xLastCacheShape.clear();
+        g_xLastCacheShapeEngine.clear();
     }
     // delete buffered display geometry
     InvalidateRenderGeometry();


More information about the Libreoffice-commits mailing list