[Libreoffice-commits] core.git: 3 commits - drawinglayer/source sd/qa

Korrawit Pruegsanusak detective.conan.1412 at gmail.com
Sat Dec 7 23:19:44 PST 2013


 dev/null                                           |binary
 drawinglayer/source/dumper/EnhancedShapeDumper.cxx |    2 
 drawinglayer/source/dumper/EnhancedShapeDumper.hxx |    2 
 drawinglayer/source/dumper/XShapeDumper.cxx        |    5 
 sd/qa/unit/data/fdo47434.pptx                      |binary
 sd/qa/unit/data/pptx/xml/fdo47434_page0.xml        |  247 ---------------------
 sd/qa/unit/data/xml/fdo47434_0.xml                 |  247 +++++++++++++++++++++
 sd/qa/unit/data/xml/shapes-test_page7.xml          |    2 
 sd/qa/unit/import-tests.cxx                        |    2 
 9 files changed, 256 insertions(+), 251 deletions(-)

New commits:
commit a9562d5e3c91b04214013bf296de3156f891e167
Author: Korrawit Pruegsanusak <detective.conan.1412 at gmail.com>
Date:   Sun Dec 8 14:15:39 2013 +0700

    XShapeDumper: empty name should not be dumped
    
    Change-Id: Ic1ab8840c9e543cebf322de922b01739684789ad

diff --git a/drawinglayer/source/dumper/XShapeDumper.cxx b/drawinglayer/source/dumper/XShapeDumper.cxx
index 75b7bd3..089640b 100644
--- a/drawinglayer/source/dumper/XShapeDumper.cxx
+++ b/drawinglayer/source/dumper/XShapeDumper.cxx
@@ -1007,8 +1007,8 @@ void dumpMoveProtectAsAttribute(sal_Bool bMoveProtect, xmlTextWriterPtr xmlWrite
 
 void dumpNameAsAttribute(OUString sName, xmlTextWriterPtr xmlWriter)
 {
-    xmlTextWriterWriteFormatAttribute(xmlWriter, BAD_CAST("name"), "%s",
-        OUStringToOString(sName, RTL_TEXTENCODING_UTF8).getStr());
+    if(!sName.isEmpty())
+        xmlTextWriterWriteFormatAttribute(xmlWriter, BAD_CAST("name"), "%s", OUStringToOString(sName, RTL_TEXTENCODING_UTF8).getStr());
 }
 
 void dumpSizeProtectAsAttribute(sal_Bool bSizeProtect, xmlTextWriterPtr xmlWriter)
diff --git a/sd/qa/unit/data/xml/shapes-test_page7.xml b/sd/qa/unit/data/xml/shapes-test_page7.xml
index 0a31e99..367b054 100644
--- a/sd/qa/unit/data/xml/shapes-test_page7.xml
+++ b/sd/qa/unit/data/xml/shapes-test_page7.xml
@@ -1,6 +1,6 @@
 <?xml version="1.0"?>
 <XShapes>
- <XShape positionX="1361" positionY="9000" sizeX="24639" sizeY="7858" type="com.sun.star.presentation.GraphicObjectShape" fontHeight="18.000000" fontColor="ffffffff" textAutoGrowHeight="true" textAutoGrowWidth="false" textContourFrame="false" textFitToSize="NONE" textHorizontalAdjust="CENTER" textVerticalAdjust="CENTER" textLeftDistance="250" textRightDistance="250" textUpperDistance="125" textLowerDistance="125" textMaximumFrameHeight="0" textMaximumFrameWidth="0" textMinimumFrameHeight="0" textMinimumFrameWidth="0" textAnimationAmount="0" textAnimationCount="0" textAnimationDelay="0" textAnimationDirection="LEFT" textAnimationKind="NONE" textAnimationStartInside="false" textAnimationStopInside="false" textWritingMode="LR_TB" shadow="false" shadowColor="808080" shadowTransparence="0" shadowXDistance="200" shadowYDistance="200" zOrder="0" layerID="0" layerName="layout" visible="true" printable="true" moveProtect="false" name="" sizeProtect="false">
+ <XShape positionX="1361" positionY="9000" sizeX="24639" sizeY="7858" type="com.sun.star.presentation.GraphicObjectShape" fontHeight="18.000000" fontColor="ffffffff" textAutoGrowHeight="true" textAutoGrowWidth="false" textContourFrame="false" textFitToSize="NONE" textHorizontalAdjust="CENTER" textVerticalAdjust="CENTER" textLeftDistance="250" textRightDistance="250" textUpperDistance="125" textLowerDistance="125" textMaximumFrameHeight="0" textMaximumFrameWidth="0" textMinimumFrameHeight="0" textMinimumFrameWidth="0" textAnimationAmount="0" textAnimationCount="0" textAnimationDelay="0" textAnimationDirection="LEFT" textAnimationKind="NONE" textAnimationStartInside="false" textAnimationStopInside="false" textWritingMode="LR_TB" shadow="false" shadowColor="808080" shadowTransparence="0" shadowXDistance="200" shadowYDistance="200" zOrder="0" layerID="0" layerName="layout" visible="true" printable="true" moveProtect="false" sizeProtect="false">
   <Transformation>
    <Line1 column1="24640.000000" column2="0.000000" column3="1361.000000"/>
    <Line2 column1="0.000000" column2="7859.000000" column3="9000.000000"/>
commit 4db9ae4479dc6470d0f5c0c5b9b0be6d6dd59de9
Author: Korrawit Pruegsanusak <detective.conan.1412 at gmail.com>
Date:   Sun Dec 8 14:13:14 2013 +0700

    sd/qa/unit: move and rename some files for consistency

diff --git a/sd/qa/unit/data/pptx/fdo47434-all.pptx b/sd/qa/unit/data/fdo47434.pptx
similarity index 100%
rename from sd/qa/unit/data/pptx/fdo47434-all.pptx
rename to sd/qa/unit/data/fdo47434.pptx
diff --git a/sd/qa/unit/data/pptx/xml/fdo47434_page0.xml b/sd/qa/unit/data/xml/fdo47434_0.xml
similarity index 100%
rename from sd/qa/unit/data/pptx/xml/fdo47434_page0.xml
rename to sd/qa/unit/data/xml/fdo47434_0.xml
diff --git a/sd/qa/unit/import-tests.cxx b/sd/qa/unit/import-tests.cxx
index bd65a30..63b8056 100644
--- a/sd/qa/unit/import-tests.cxx
+++ b/sd/qa/unit/import-tests.cxx
@@ -99,7 +99,7 @@ void SdFiltersTest::testDocumentLayout()
     struct { const char *pInput, *pDump; sal_Int32 nExportType; } aFilesToCompare[] =
     {
         { "odp/shapes-test.odp", "xml/shapes-test_page", -1 },
-        { "pptx/fdo47434-all.pptx", "pptx/xml/fdo47434_page", -1 },
+        { "fdo47434.pptx", "xml/fdo47434_", -1 },
         { "n758621.ppt", "xml/n758621_", -1 },
         { "fdo64586.ppt", "xml/fdo64586_", -1 },
         { "n819614.pptx", "xml/n819614_", -1 },
commit 4c57554ff125f987ea64695661dd0967e57185fd
Author: Korrawit Pruegsanusak <detective.conan.1412 at gmail.com>
Date:   Sun Dec 8 14:03:57 2013 +0700

    add vim modelines for drawinglayer/source/dumper/*

diff --git a/drawinglayer/source/dumper/EnhancedShapeDumper.cxx b/drawinglayer/source/dumper/EnhancedShapeDumper.cxx
index 8a18088..3136f59 100644
--- a/drawinglayer/source/dumper/EnhancedShapeDumper.cxx
+++ b/drawinglayer/source/dumper/EnhancedShapeDumper.cxx
@@ -1089,3 +1089,5 @@ void EnhancedShapeDumper::dumpScaleXAsAttribute(sal_Bool bScaleX)
     else
         xmlTextWriterWriteFormatAttribute( xmlWriter, BAD_CAST("scaleX"), "%s", "false");
 }
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/drawinglayer/source/dumper/EnhancedShapeDumper.hxx b/drawinglayer/source/dumper/EnhancedShapeDumper.hxx
index 5c4eba9..bb5564a 100644
--- a/drawinglayer/source/dumper/EnhancedShapeDumper.hxx
+++ b/drawinglayer/source/dumper/EnhancedShapeDumper.hxx
@@ -128,3 +128,5 @@ private:
     xmlTextWriterPtr xmlWriter;
 };
 #endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/drawinglayer/source/dumper/XShapeDumper.cxx b/drawinglayer/source/dumper/XShapeDumper.cxx
index a2de8c4..75b7bd3 100644
--- a/drawinglayer/source/dumper/XShapeDumper.cxx
+++ b/drawinglayer/source/dumper/XShapeDumper.cxx
@@ -1952,3 +1952,4 @@ OUString XShapeDumper::dump(uno::Reference<drawing::XShapes> xPageShapes)
     return OStringToOUString(aString.makeStringAndClear(), RTL_TEXTENCODING_UTF8);
 }
 
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */


More information about the Libreoffice-commits mailing list