summaryrefslogtreecommitdiff
path: root/drawinglayer
diff options
context:
space:
mode:
authorArtur Dorda <artur.dorda+libo@gmail.com>2012-06-09 14:39:11 +0200
committerMarkus Mohrhard <markus.mohrhard@googlemail.com>2012-07-12 03:10:07 +0200
commiteb364a23a6579a2b8740071784858a873b4d48db (patch)
tree48c377da676e4f3f3377114df7aba6fa541ea45d /drawinglayer
parentc000eeed997cbf37f1a5f92741a891aa8756404c (diff)
Restructurization of a dumpPolyPolygonBezierCoords() method, more elegant now
Change-Id: I3cda1a3554837e4e667a42ac292db24d6a8edf37
Diffstat (limited to 'drawinglayer')
-rw-r--r--drawinglayer/source/dumper/XShapeDumper.cxx21
1 files changed, 3 insertions, 18 deletions
diff --git a/drawinglayer/source/dumper/XShapeDumper.cxx b/drawinglayer/source/dumper/XShapeDumper.cxx
index 78b8da85bdb1..182cb6298cc4 100644
--- a/drawinglayer/source/dumper/XShapeDumper.cxx
+++ b/drawinglayer/source/dumper/XShapeDumper.cxx
@@ -437,25 +437,10 @@ namespace {
void XShapeDumper::dumpPolyPolygonBezierCoords(drawing::PolyPolygonBezierCoords aPolyPolygonBezierCoords, xmlTextWriterPtr xmlWriter)
{
- uno::Sequence<uno::Sequence< awt::Point > > pointSequenceSequence = aPolyPolygonBezierCoords.Coordinates;
- sal_Int32 nPointsSequence = pointSequenceSequence.getLength();
- for (sal_Int32 i = 0; i < nPointsSequence; ++i)
- {
- uno::Sequence< awt::Point > pointSequence = pointSequenceSequence[i];
- sal_Int32 nPoints = pointSequence.getLength();
-
- xmlTextWriterStartElement(xmlWriter, BAD_CAST( "pointSequence" ));
-
- for(sal_Int32 j = 0; j < nPoints; ++j)
- {
- xmlTextWriterStartElement(xmlWriter, BAD_CAST( "point" ));
- xmlTextWriterWriteFormatAttribute(xmlWriter, BAD_CAST("positionX"), "%" SAL_PRIdINT32, pointSequence[j].X);
- xmlTextWriterWriteFormatAttribute(xmlWriter, BAD_CAST("positionY"), "%" SAL_PRIdINT32, pointSequence[j].Y);
- xmlTextWriterEndElement( xmlWriter );
- }
- xmlTextWriterEndElement( xmlWriter );
- }
+ // dumps first field - Coordinates
+ dumpPointSequenceSequence(aPolyPolygonBezierCoords.Coordinates, xmlWriter);
+ // dumps second field - Flags
uno::Sequence<uno::Sequence< drawing::PolygonFlags > > polygonFlagsSequenceSequence = aPolyPolygonBezierCoords.Flags;
sal_Int32 nFlagsSequence = polygonFlagsSequenceSequence.getLength();
for (sal_Int32 i = 0; i < nFlagsSequence; ++i)