diff options
author | Noel Grandin <noel@peralex.com> | 2012-10-10 10:13:18 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2012-10-22 17:01:11 +0200 |
commit | fb741b5e1e6aeaee74cf14af4f1cc152f0ab0952 (patch) | |
tree | 24864ba5addb12799a508ce4718868026519f057 /starmath/source | |
parent | 9cabab002b1180650236f3d1f5fd32dfdd4bf79a (diff) |
fdo#46808, Adapt xml::sax::XWriter UNO service to new style
Create a merged XWriter interface for the service.
The xml.sax.Writer service already existed, it just did not have
an IDL file.
Change-Id: I4e6d3f3c68f9282a55fc7aa19778f97632fd8ad5
Diffstat (limited to 'starmath/source')
-rw-r--r-- | starmath/source/mathmlexport.cxx | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/starmath/source/mathmlexport.cxx b/starmath/source/mathmlexport.cxx index 1ecaff1db896..33628915c80a 100644 --- a/starmath/source/mathmlexport.cxx +++ b/starmath/source/mathmlexport.cxx @@ -31,6 +31,7 @@ #include <com/sun/star/xml/sax/InputSource.hpp> #include <com/sun/star/xml/sax/XDTDHandler.hpp> #include <com/sun/star/xml/sax/XParser.hpp> +#include <com/sun/star/xml/sax/Writer.hpp> #include <com/sun/star/io/XActiveDataSource.hpp> #include <com/sun/star/io/XActiveDataControl.hpp> #include <com/sun/star/document/XDocumentProperties.hpp> @@ -51,6 +52,7 @@ #include <unotools/saveopt.hxx> #include <svl/stritem.hxx> #include <svl/itemprop.hxx> +#include <comphelper/componentcontext.hxx> #include <comphelper/processfactory.hxx> #include <unotools/streamwrap.hxx> #include <sax/tools/converter.hxx> @@ -265,9 +267,8 @@ sal_Bool SmXMLExportWrapper::WriteThroughComponent( OSL_ENSURE(NULL != pComponentName, "Need component name!"); // get component - Reference< io::XActiveDataSource > xSaxWriter( - rFactory->createInstance( "com.sun.star.xml.sax.Writer" ), - UNO_QUERY ); + Reference< xml::sax::XWriter > xSaxWriter = xml::sax::Writer::create( + comphelper::getComponentContext(rFactory) ); OSL_ENSURE( xSaxWriter.is(), "can't instantiate XML writer" ); if (!xSaxWriter.is()) return sal_False; |