diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2012-09-19 13:15:15 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2012-09-19 13:16:38 +0200 |
commit | 03a9f139bd9ea1a4f9096fc982e6b326def58532 (patch) | |
tree | bfb7a08bb4831a1a46b48c3bb49afa77ca436349 /filter | |
parent | e8a169c93d7e2443a2e56afe7e99cd0721a2c27b (diff) |
ComponentContext::getUnoContext -> getComponentContext simplification
...and some further clean-up.
Change-Id: If5dce53e382b56390c502d0d0d93fc06cbfe33ea
Diffstat (limited to 'filter')
-rw-r--r-- | filter/source/config/cache/typedetection.cxx | 6 | ||||
-rw-r--r-- | filter/source/graphicfilter/icgm/actimpr.cxx | 3 | ||||
-rw-r--r-- | filter/source/svg/svgreader.cxx | 3 | ||||
-rw-r--r-- | filter/source/xsltfilter/OleHandler.cxx | 4 | ||||
-rw-r--r-- | filter/source/xsltfilter/XSLTFilter.cxx | 8 |
5 files changed, 11 insertions, 13 deletions
diff --git a/filter/source/config/cache/typedetection.cxx b/filter/source/config/cache/typedetection.cxx index 51badc95ab7d..5f3251985eee 100644 --- a/filter/source/config/cache/typedetection.cxx +++ b/filter/source/config/cache/typedetection.cxx @@ -41,7 +41,7 @@ #include <framework/interaction.hxx> #include <tools/urlobj.hxx> #include <unotools/localfilehelper.hxx> -#include <comphelper/componentcontext.hxx> +#include <comphelper/processfactory.hxx> namespace filter{ @@ -75,7 +75,7 @@ TypeDetection::~TypeDetection() css::util::URL aURL; aURL.Complete = sURL; - css::uno::Reference< css::util::XURLTransformer > xParser(css::util::URLTransformer::create(comphelper::ComponentContext(m_xSMGR).getUNOContext())); + css::uno::Reference< css::util::XURLTransformer > xParser(css::util::URLTransformer::create(comphelper::getComponentContext(m_xSMGR))); xParser->parseStrict(aURL); // set std types as minimum requirement first! @@ -259,7 +259,7 @@ struct EqualByName : public std::binary_function<FlatDetectionInfo, FlatDetectio css::util::URL aURL; aURL.Complete = sURL; - css::uno::Reference< css::util::XURLTransformer > xParser(css::util::URLTransformer::create(comphelper::ComponentContext(m_xSMGR).getUNOContext())); + css::uno::Reference< css::util::XURLTransformer > xParser(css::util::URLTransformer::create(comphelper::getComponentContext(m_xSMGR))); xParser->parseStrict(aURL); rtl::OUString aSelectedFilter = stlDescriptor.getUnpackedValueOrDefault( diff --git a/filter/source/graphicfilter/icgm/actimpr.cxx b/filter/source/graphicfilter/icgm/actimpr.cxx index 7d541272bbed..bde6c5e33d21 100644 --- a/filter/source/graphicfilter/icgm/actimpr.cxx +++ b/filter/source/graphicfilter/icgm/actimpr.cxx @@ -48,7 +48,6 @@ #include <com/sun/star/text/XTextRange.hpp> #include <com/sun/star/style/HorizontalAlignment.hpp> -#include <comphelper/componentcontext.hxx> #include <comphelper/processfactory.hxx> #include <toolkit/helper/vclunohelper.hxx> @@ -451,7 +450,7 @@ void CGMImpressOutAct::EndGroup() if( aAny >>= aXShapeGrouper ) { uno::Reference< drawing::XShapes > aXShapes( - drawing::ShapeCollection::create(comphelper::ComponentContext(maXServiceManagerSC).getUNOContext()) ); + drawing::ShapeCollection::create(comphelper::getComponentContext(maXServiceManagerSC)) ); for ( sal_uInt32 i = mnFirstIndex; i < mnCurrentCount; i++ ) { uno::Reference< drawing::XShape > aXShape = *(uno::Reference< drawing::XShape > *)maXShapes->getByIndex( i ).getValue(); diff --git a/filter/source/svg/svgreader.cxx b/filter/source/svg/svgreader.cxx index 21d55ef2b81d..147f3f3b71c9 100644 --- a/filter/source/svg/svgreader.cxx +++ b/filter/source/svg/svgreader.cxx @@ -49,7 +49,6 @@ #include <com/sun/star/xml/dom/DocumentBuilder.hpp> #include <com/sun/star/xml/dom/NodeType.hpp> -#include <comphelper/componentcontext.hxx> #include <comphelper/processfactory.hxx> #include <basegfx/polygon/b2dpolygoncutandtouch.hxx> #include <basegfx/polygon/b2dpolypolygoncutter.hxx> @@ -1904,7 +1903,7 @@ SVGReader::SVGReader(const uno::Reference<lang::XMultiServiceFactory>& xServ sal_Bool SVGReader::parseAndConvert() { - uno::Reference<xml::dom::XDocumentBuilder> xDomBuilder(xml::dom::DocumentBuilder::create(comphelper::ComponentContext(m_xServiceFactory).getUNOContext())); + uno::Reference<xml::dom::XDocumentBuilder> xDomBuilder(xml::dom::DocumentBuilder::create(comphelper::getComponentContext(m_xServiceFactory))); uno::Reference<xml::dom::XDocument> xDom( xDomBuilder->parse(m_xInputStream), diff --git a/filter/source/xsltfilter/OleHandler.cxx b/filter/source/xsltfilter/OleHandler.cxx index 715058ca507e..e76b57efb9de 100644 --- a/filter/source/xsltfilter/OleHandler.cxx +++ b/filter/source/xsltfilter/OleHandler.cxx @@ -48,8 +48,8 @@ #include <package/Inflater.hxx> #include <package/Deflater.hxx> -#include <comphelper/componentcontext.hxx> #include <cppuhelper/factory.hxx> +#include <comphelper/processfactory.hxx> #include <cppuhelper/servicefactory.hxx> #include <com/sun/star/uno/Any.hxx> #include <com/sun/star/uno/XInterface.hpp> @@ -73,7 +73,7 @@ namespace XSLT { Reference<XStream> SAL_CALL OleHandler::createTempFile() { Reference<XStream> tempFile( - TempFile::create(comphelper::ComponentContext(m_msf).getUNOContext()), + TempFile::create(comphelper::getComponentContext(m_msf)), UNO_QUERY); OSL_ASSERT(tempFile.is()); return tempFile; diff --git a/filter/source/xsltfilter/XSLTFilter.cxx b/filter/source/xsltfilter/XSLTFilter.cxx index 4ebabc7846c4..a5b28d571c9b 100644 --- a/filter/source/xsltfilter/XSLTFilter.cxx +++ b/filter/source/xsltfilter/XSLTFilter.cxx @@ -41,8 +41,8 @@ #include <rtl/strbuf.hxx> #include <tools/urlobj.hxx> -#include <comphelper/componentcontext.hxx> #include <comphelper/interaction.hxx> +#include <comphelper/processfactory.hxx> #include <com/sun/star/lang/XComponent.hpp> #include <com/sun/star/lang/EventObject.hpp> @@ -247,7 +247,7 @@ m_rServiceFactory(r), m_bTerminated(sal_False), m_bError(sal_False) XSLTFilter::rel2abs(const OUString& s) { - css::uno::Reference< css::uno::XComponentContext > xContext( comphelper::ComponentContext(m_rServiceFactory).getUNOContext() ); + css::uno::Reference< css::uno::XComponentContext > xContext( comphelper::getComponentContext(m_rServiceFactory) ); css::uno::Reference<XStringSubstitution> subs(css::util::PathSubstitution::create(xContext)); OUString aWorkingDir(subs->getSubstituteVariableValue(OUString( "$(progurl)"))); @@ -344,7 +344,7 @@ m_rServiceFactory(r), m_bTerminated(sal_False), m_bError(sal_False) // create pipe css::uno::Reference<XOutputStream> pipeout( - Pipe::create(comphelper::ComponentContext(m_rServiceFactory).getUNOContext()), + Pipe::create(comphelper::getComponentContext(m_rServiceFactory)), UNO_QUERY); css::uno::Reference<XInputStream> pipein(pipeout, UNO_QUERY); @@ -497,7 +497,7 @@ m_rServiceFactory(r), m_bTerminated(sal_False), m_bError(sal_False) // create pipe css::uno::Reference<XOutputStream> pipeout( - Pipe::create(comphelper::ComponentContext(m_rServiceFactory).getUNOContext()), + Pipe::create(comphelper::getComponentContext(m_rServiceFactory)), UNO_QUERY); css::uno::Reference<XInputStream> pipein(pipeout, UNO_QUERY); |