summaryrefslogtreecommitdiff
path: root/filter/source/config/cache
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2012-06-01 15:15:25 +0200
committerStephan Bergmann <sbergman@redhat.com>2012-06-06 10:53:34 +0200
commit0fcd1a73f0e1ec564f3c6da1ccd890183d3c18db (patch)
tree3895ecd6f804b8f3ef3a8f03f1739e17918feeef /filter/source/config/cache
parent8a95074eaefd01621dc55db8567b19c8e6157f95 (diff)
fdo#46808, Adapt UNO services to new style, Part 7, updating ::create
Update code to use factory method URLTransformer::create Change-Id: I3fd2e838497bcfd8fc949615c0e7d60a6ea47118 Signed-off-by: Stephan Bergmann <sbergman@redhat.com>, added some tweaks.
Diffstat (limited to 'filter/source/config/cache')
-rw-r--r--filter/source/config/cache/constant.hxx1
-rw-r--r--filter/source/config/cache/typedetection.cxx6
2 files changed, 4 insertions, 3 deletions
diff --git a/filter/source/config/cache/constant.hxx b/filter/source/config/cache/constant.hxx
index a6e28b55554a..5fda7bbd01c9 100644
--- a/filter/source/config/cache/constant.hxx
+++ b/filter/source/config/cache/constant.hxx
@@ -179,7 +179,6 @@
*/
#define SERVICE_CONFIGURATIONUPDATEACCESS _FILTER_CONFIG_FROM_ASCII_("com.sun.star.configuration.ConfigurationUpdateAccess" )
#define SERVICE_CONFIGURATIONACCESS _FILTER_CONFIG_FROM_ASCII_("com.sun.star.configuration.ConfigurationAccess" )
-#define SERVICE_URLTRANSFORMER _FILTER_CONFIG_FROM_ASCII_("com.sun.star.util.URLTransformer" )
#define SERVICE_FILTERCONFIGREFRESH _FILTER_CONFIG_FROM_ASCII_("com.sun.star.document.FilterConfigRefresh" )
/** @short some configuration paths.
diff --git a/filter/source/config/cache/typedetection.cxx b/filter/source/config/cache/typedetection.cxx
index 49e5e24b9f9d..8e3747cb7aa6 100644
--- a/filter/source/config/cache/typedetection.cxx
+++ b/filter/source/config/cache/typedetection.cxx
@@ -32,6 +32,7 @@
//_______________________________________________
// includes
#include <com/sun/star/document/XExtendedFilterDetection.hpp>
+#include <com/sun/star/util/URLTransformer.hpp>
#include <com/sun/star/util/XURLTransformer.hpp>
#include <com/sun/star/io/XInputStream.hpp>
@@ -42,6 +43,7 @@
#include <framework/interaction.hxx>
#include <tools/urlobj.hxx>
#include <unotools/localfilehelper.hxx>
+#include <comphelper/componentcontext.hxx>
//_______________________________________________
// namespace
@@ -77,7 +79,7 @@ TypeDetection::~TypeDetection()
css::util::URL aURL;
aURL.Complete = sURL;
- css::uno::Reference< css::util::XURLTransformer > xParser(m_xSMGR->createInstance(SERVICE_URLTRANSFORMER), css::uno::UNO_QUERY);
+ css::uno::Reference< css::util::XURLTransformer > xParser(css::util::URLTransformer::create(comphelper::ComponentContext(m_xSMGR).getUNOContext()));
xParser->parseStrict(aURL);
// set std types as minimum requirement first!
@@ -261,7 +263,7 @@ struct EqualByName : public std::binary_function<FlatDetectionInfo, FlatDetectio
css::util::URL aURL;
aURL.Complete = sURL;
- css::uno::Reference< css::util::XURLTransformer > xParser(m_xSMGR->createInstance(SERVICE_URLTRANSFORMER), css::uno::UNO_QUERY);
+ css::uno::Reference< css::util::XURLTransformer > xParser(css::util::URLTransformer::create(comphelper::ComponentContext(m_xSMGR).getUNOContext()));
xParser->parseStrict(aURL);
rtl::OUString aSelectedFilter = stlDescriptor.getUnpackedValueOrDefault(