summaryrefslogtreecommitdiff
path: root/reportdesign
diff options
context:
space:
mode:
authorLionel Elie Mamane <lionel@mamane.lu>2014-12-19 21:38:35 +0100
committerLionel Elie Mamane <lionel@mamane.lu>2014-12-19 23:33:33 +0100
commit66c7dbbf7dfba8cfab63f8d1df72ace87e5bf7ca (patch)
tree817845a86fd2960e070be26dd02ec3779688c587 /reportdesign
parent1cdb723b27d7359097891c7c370264c9974079db (diff)
Don't assume that the ZOrder property of shapes is an enumeration
...at least when we can easily not assume it. shapes = shapes of the same XShapes an enumeration = it is the sequence 0, 1, 2, 3, ..., XShapes->getCount()-1 We replace the ZOrder property by the index of the XShape in the XShapes (the same XShapes that is passed to seekShapes()... when that is easy to find. Else, use ZOrder and hope for the best. ZOrders are not always an enumeration. For example, in documents (forms) created by the Base forms wizard, it is not the case. The wrong assumptions was leading to the following bugs in the Base form wizard: - Only the first two controls in the form were successfully saved. The others were just dropped. - Whereas the labels had the proper style (background and text colour) applied while creating the document, these were not saved successfully Change-Id: I15b9a3ef3b16eafa9698332e35d82d51d51627f8
Diffstat (limited to 'reportdesign')
-rw-r--r--reportdesign/source/filter/xml/xmlExport.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/reportdesign/source/filter/xml/xmlExport.cxx b/reportdesign/source/filter/xml/xmlExport.cxx
index 27fca7f39cff..227b9d84e983 100644
--- a/reportdesign/source/filter/xml/xmlExport.cxx
+++ b/reportdesign/source/filter/xml/xmlExport.cxx
@@ -674,7 +674,7 @@ void ORptExport::exportReportComponentAutoStyles(const Reference<XSection>& _xPr
rtl::Reference< XMLShapeExport > xShapeExport = GetShapeExport();
xShapeExport->seekShapes(_xProp.get());
SolarMutexGuard aGuard;
- xShapeExport->collectShapeAutoStyles(xShape.get());
+ xShapeExport->collectShapeAutoStyles(xShape.get(), i);
}
else
{
@@ -1501,7 +1501,7 @@ void ORptExport::exportShapes(const Reference< XSection>& _xSection,bool _bAddPa
}
AddAttribute( XML_NAMESPACE_TEXT, XML_ANCHOR_TYPE, XML_PARAGRAPH );
- xShapeExport->exportShape(xShape.get(),SEF_DEFAULT|SEF_EXPORT_NO_WS,&aRefPoint);
+ xShapeExport->exportShape(xShape.get(), i, SEF_DEFAULT|SEF_EXPORT_NO_WS,&aRefPoint);
}
}
}