summaryrefslogtreecommitdiff
path: root/reportdesign/source/filter/xml/xmlfilter.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'reportdesign/source/filter/xml/xmlfilter.cxx')
-rw-r--r--reportdesign/source/filter/xml/xmlfilter.cxx7
1 files changed, 4 insertions, 3 deletions
diff --git a/reportdesign/source/filter/xml/xmlfilter.cxx b/reportdesign/source/filter/xml/xmlfilter.cxx
index 00e76c32c952..8b941251523e 100644
--- a/reportdesign/source/filter/xml/xmlfilter.cxx
+++ b/reportdesign/source/filter/xml/xmlfilter.cxx
@@ -43,10 +43,12 @@
#include <xmloff/nmspmap.hxx>
#include <xmloff/XMLFontStylesContext.hxx>
#include <rtl/logfile.hxx>
+#include <com/sun/star/xml/dom/SAXDocumentBuilder.hpp>
#include <com/sun/star/xml/sax/InputSource.hpp>
#include <com/sun/star/xml/sax/XParser.hpp>
#include <com/sun/star/beans/PropertyAttribute.hpp>
+#include <comphelper/componentcontext.hxx>
#include <comphelper/genericpropertyset.hxx>
#include <comphelper/mediadescriptor.hxx>
#include <xmloff/ProgressBarHelper.hxx>
@@ -1084,9 +1086,8 @@ SvXMLImportContext* ORptFilter::CreateMetaContext(const ::rtl::OUString& rLocalN
if ( (getImportFlags() & IMPORT_META) )
{
uno::Reference<xml::sax::XDocumentHandler> xDocBuilder(
- getServiceFactory()->createInstance(::rtl::OUString(
- RTL_CONSTASCII_USTRINGPARAM("com.sun.star.xml.dom.SAXDocumentBuilder"))),
- uno::UNO_QUERY_THROW);
+ xml::dom::SAXDocumentBuilder::create(comphelper::ComponentContext(getServiceFactory()).getUNOContext()),
+ uno::UNO_QUERY_THROW);
uno::Reference<document::XDocumentPropertiesSupplier> xDPS(GetModel(), uno::UNO_QUERY_THROW);
pContext = new SvXMLMetaDocumentContext(*this,XML_NAMESPACE_OFFICE, rLocalName,xDPS->getDocumentProperties(), xDocBuilder);
}