[Libreoffice-commits] core.git: oox/source

Tamás Zolnai tamas.zolnai at collabora.com
Wed Sep 6 10:48:36 UTC 2017


 oox/source/export/drawingml.cxx |    8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

New commits:
commit f3f98b8e1f9eb0804e18bea055fb02917aca42a5
Author: Tamás Zolnai <tamas.zolnai at collabora.com>
Date:   Wed Sep 6 11:56:16 2017 +0200

    tdf#111838: Revert "Decrease duplicated code"
    
    This reverts commit 787732fac0aef255bdc51479fdaddf15532d118e.
    
    Change-Id: Idd36f0d434c5ec867e0e1bbbfa70d8a4644d53c6
    Reviewed-on: https://gerrit.libreoffice.org/41976
    Reviewed-by: Michael Stahl <mstahl at redhat.com>
    Reviewed-by: Tamás Zolnai <tamas.zolnai at collabora.com>
    Tested-by: Tamás Zolnai <tamas.zolnai at collabora.com>

diff --git a/oox/source/export/drawingml.cxx b/oox/source/export/drawingml.cxx
index f0d3ea78431f..94dcd54ed063 100644
--- a/oox/source/export/drawingml.cxx
+++ b/oox/source/export/drawingml.cxx
@@ -3034,7 +3034,6 @@ void DrawingML::WriteShapeEffect( const OUString& sName, const Sequence< Propert
 
     if( nEffectToken > 0 )
     {
-        mpFS->startElementNS(XML_a, XML_effectLst, FSEND);
         mpFS->startElement( nEffectToken, xOuterShdwAttrList );
 
         if( bContainsColor )
@@ -3046,7 +3045,6 @@ void DrawingML::WriteShapeEffect( const OUString& sName, const Sequence< Propert
         }
 
         mpFS->endElement( nEffectToken );
-        mpFS->endElementNS(XML_a, XML_effectLst);
     }
 }
 
@@ -3090,17 +3088,23 @@ void DrawingML::WriteShapeEffects( const Reference< XPropertySet >& rXPropSet )
             aShadowGrabBag[2].Name = "RgbClrTransparency";
             aShadowGrabBag[2].Value = rXPropSet->getPropertyValue( "ShadowTransparence" );
 
+            mpFS->startElementNS(XML_a, XML_effectLst, FSEND);
             WriteShapeEffect( "outerShdw", aShadowGrabBag );
+            mpFS->endElementNS(XML_a, XML_effectLst);
         }
         return;
     }
 
+    mpFS->startElementNS(XML_a, XML_effectLst, FSEND);
+
     for( sal_Int32 i=0; i < aEffects.getLength(); ++i )
     {
         Sequence< PropertyValue > aEffectProps;
         aEffects[i].Value >>= aEffectProps;
         WriteShapeEffect( aEffects[i].Name, aEffectProps );
     }
+
+    mpFS->endElementNS(XML_a, XML_effectLst);
 }
 
 void DrawingML::WriteShape3DEffects( const Reference< XPropertySet >& xPropSet )


More information about the Libreoffice-commits mailing list