diff options
Diffstat (limited to 'dbaccess')
-rw-r--r-- | dbaccess/source/core/dataaccess/documenteventexecutor.cxx | 4 | ||||
-rw-r--r-- | dbaccess/source/filter/xml/dbloader2.cxx | 14 | ||||
-rw-r--r-- | dbaccess/source/ui/browser/genericcontroller.cxx | 4 |
3 files changed, 12 insertions, 10 deletions
diff --git a/dbaccess/source/core/dataaccess/documenteventexecutor.cxx b/dbaccess/source/core/dataaccess/documenteventexecutor.cxx index df1a60f5a34b..413bc6eef8a2 100644 --- a/dbaccess/source/core/dataaccess/documenteventexecutor.cxx +++ b/dbaccess/source/core/dataaccess/documenteventexecutor.cxx @@ -30,6 +30,7 @@ /** === begin UNO includes === **/ #include <com/sun/star/document/XDocumentEventBroadcaster.hpp> +#include <com/sun/star/util/URLTransformer.hpp> #include <com/sun/star/util/XURLTransformer.hpp> #include <com/sun/star/frame/XModel.hpp> #include <com/sun/star/frame/XDispatchProvider.hpp> @@ -62,6 +63,7 @@ namespace dbaccess using ::com::sun::star::document::XEventsSupplier; using ::com::sun::star::container::XNameAccess; using ::com::sun::star::frame::XModel; + using ::com::sun::star::util::URLTransformer; using ::com::sun::star::util::XURLTransformer; using ::com::sun::star::frame::XDispatchProvider; using ::com::sun::star::frame::XDispatch; @@ -144,7 +146,7 @@ namespace dbaccess try { - _rContext.createComponent( "com.sun.star.util.URLTransformer", m_pData->xURLTransformer ); + m_pData->xURLTransformer = URLTransformer::create(_rContext.getUNOContext()); } catch( const Exception& ) { diff --git a/dbaccess/source/filter/xml/dbloader2.cxx b/dbaccess/source/filter/xml/dbloader2.cxx index df140ed3e71d..8291bcbf161a 100644 --- a/dbaccess/source/filter/xml/dbloader2.cxx +++ b/dbaccess/source/filter/xml/dbloader2.cxx @@ -53,6 +53,7 @@ #include <com/sun/star/sdb/XDocumentDataSource.hpp> #include <com/sun/star/task/XJobExecutor.hpp> #include <com/sun/star/ui/dialogs/XExecutableDialog.hpp> +#include <com/sun/star/util/URLTransformer.hpp> #include <com/sun/star/util/XURLTransformer.hpp> #include <com/sun/star/view/XSelectionSupplier.hpp> #include <com/sun/star/sdb/application/DatabaseObjectContainer.hpp> @@ -340,14 +341,11 @@ namespace bool bDoesAllow = sal_False; try { - Reference< XURLTransformer > xTransformer; - if ( _rContext.createComponent( "com.sun.star.util.URLTransformer", xTransformer ) ) - { - URL aURL; - aURL.Complete = _rURL; - xTransformer->parseStrict( aURL ); - bDoesAllow = aURL.Arguments == "Interactive"; - } + Reference< XURLTransformer > xTransformer( URLTransformer::create(_rContext.getUNOContext()) ); + URL aURL; + aURL.Complete = _rURL; + xTransformer->parseStrict( aURL ); + bDoesAllow = aURL.Arguments == "Interactive"; } catch( const Exception& ) { diff --git a/dbaccess/source/ui/browser/genericcontroller.cxx b/dbaccess/source/ui/browser/genericcontroller.cxx index 4283d7eed180..7652b5847a2e 100644 --- a/dbaccess/source/ui/browser/genericcontroller.cxx +++ b/dbaccess/source/ui/browser/genericcontroller.cxx @@ -37,6 +37,7 @@ #include <osl/diagnose.h> #include "dbustrings.hrc" #include <vcl/stdtext.hxx> +#include <comphelper/componentcontext.hxx> #include <cppuhelper/typeprovider.hxx> #include <framework/titlehelper.hxx> #include <comphelper/sequence.hxx> @@ -46,6 +47,7 @@ #include <com/sun/star/sdb/XCompletedConnection.hpp> #include <com/sun/star/beans/XPropertySet.hpp> #include <com/sun/star/task/XInteractionHandler.hpp> +#include <com/sun/star/util/URLTransformer.hpp> #include <com/sun/star/util/XCloseable.hpp> #include "UITools.hxx" #include "commontypes.hxx" @@ -206,7 +208,7 @@ OGenericUnoController::OGenericUnoController(const Reference< XMultiServiceFacto try { - m_xUrlTransformer = Reference< XURLTransformer > (_rM->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.util.URLTransformer"))), UNO_QUERY); + m_xUrlTransformer = URLTransformer::create(comphelper::ComponentContext(_rM).getUNOContext()); } catch(Exception&) { |