diff options
Diffstat (limited to 'filter/source/xmlfilteradaptor/XmlFilterAdaptor.cxx')
-rw-r--r-- | filter/source/xmlfilteradaptor/XmlFilterAdaptor.cxx | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/filter/source/xmlfilteradaptor/XmlFilterAdaptor.cxx b/filter/source/xmlfilteradaptor/XmlFilterAdaptor.cxx index 88d829dead0b..bf1b0b2ea427 100644 --- a/filter/source/xmlfilteradaptor/XmlFilterAdaptor.cxx +++ b/filter/source/xmlfilteradaptor/XmlFilterAdaptor.cxx @@ -96,12 +96,25 @@ bool SAL_CALL XmlFilterAdaptor::importImpl( const Sequence< css::beans::Property PropertyMapEntry aImportInfoMap[] = { { OUString("BaseURI"), 0, ::cppu::UnoType<OUString>::get(), PropertyAttribute::MAYBEVOID, 0}, + { OUString("DefaultDocumentSettings"), 0, + ::cppu::UnoType<Sequence<PropertyValue>>::get(), PropertyAttribute::MAYBEVOID, 0 }, { OUString(), 0, css::uno::Type(), 0, 0 } }; Reference< XPropertySet > xInfoSet( GenericPropertySet_CreateInstance( new PropertySetInfo( aImportInfoMap ) ) ); xInfoSet->setPropertyValue( "BaseURI", makeAny( aBaseURI )); + + OUString aFilterName; + auto It = aMediaMap.find(OUString("FilterName")); + if (It != aMediaMap.end() && (It->second >>= aFilterName) + && aFilterName == "OpenDocument Text Flat XML") + { + PropertyValue EmptyDbFieldHidesPara("EmptyDbFieldHidesPara", 0, Any(false), + PropertyState::PropertyState_DIRECT_VALUE); + Sequence<PropertyValue> aSettings{ EmptyDbFieldHidesPara }; + xInfoSet->setPropertyValue("DefaultDocumentSettings", makeAny(aSettings)); + } aAnys[0] <<= xInfoSet; |