Kaydet (Commit) 64595f59 authored tarafından Michael Meeks's avatar Michael Meeks

fdo#61256 - the Get.*Export methods also create and register styles

unwind problem introduced by cleanup in:
fd226710
üst 38d0e65f
......@@ -448,6 +448,8 @@ void SAL_CALL SdXMLExport::setSourceDocument( const Reference< lang::XComponent
// construct PropertySetMapper
UniReference < XMLPropertySetMapper > xMapper = new XMLShapePropertySetMapper( aFactoryRef);
// get or create text paragraph export
GetTextParagraphExport();
mpPropertySetMapper = new XMLShapeExportPropertyMapper( xMapper, *this );
// set lock to avoid deletion
mpPropertySetMapper->acquire();
......
......@@ -1014,6 +1014,7 @@ SvXMLExportPropertyMapper* XMLShapeExport::CreateShapePropMapper(
{
UniReference< XMLPropertyHandlerFactory > xFactory = new XMLSdPropHdlFactory( rExport.GetModel(), rExport );
UniReference < XMLPropertySetMapper > xMapper = new XMLShapePropertySetMapper( xFactory );
rExport.GetTextParagraphExport(); // get or create text paragraph export
SvXMLExportPropertyMapper* pResult =
new XMLShapeExportPropertyMapper( xMapper, rExport );
// chain text attributes
......@@ -1257,6 +1258,7 @@ const rtl::Reference< XMLTableExport >& XMLShapeExport::GetShapeTableExport()
{
rtl::Reference< XMLPropertyHandlerFactory > xFactory( new XMLSdPropHdlFactory( mrExport.GetModel(), mrExport ) );
UniReference < XMLPropertySetMapper > xMapper( new XMLShapePropertySetMapper( xFactory.get() ) );
mrExport.GetTextParagraphExport(); // get or create text paragraph export
rtl::Reference< SvXMLExportPropertyMapper > xPropertySetMapper( new XMLShapeExportPropertyMapper( xMapper, mrExport ) );
mxShapeTableExport = new XMLTableExport( mrExport, xPropertySetMapper, xFactory );
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment