summaryrefslogtreecommitdiff
path: root/sfx2/source/appl
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2013-02-25 16:09:10 +0200
committerNoel Grandin <noel@peralex.com>2013-03-04 14:22:34 +0200
commitdc00ad1e823e3b36619cd04c7e4d169362e199b3 (patch)
tree5650e5891532dde51346d8bf5e7703569712f025 /sfx2/source/appl
parent244c7cdede13980c29850b7b68e9da16cdc61879 (diff)
fdo#46808, Use service constructor for task::InteractionHandler
a lot of code was loading the service using it's implementation name, which is why this got missed earlier. Change-Id: I0b150bc9383a1a3a09ab905c4ddb7f914e69638d
Diffstat (limited to 'sfx2/source/appl')
-rw-r--r--sfx2/source/appl/appopen.cxx8
1 files changed, 4 insertions, 4 deletions
diff --git a/sfx2/source/appl/appopen.cxx b/sfx2/source/appl/appopen.cxx
index 821b0b61f7ca..cce73e64be4c 100644
--- a/sfx2/source/appl/appopen.cxx
+++ b/sfx2/source/appl/appopen.cxx
@@ -36,6 +36,7 @@
#include <com/sun/star/document/MacroExecMode.hpp>
#include <com/sun/star/document/UpdateDocMode.hpp>
#include <com/sun/star/task/ErrorCodeRequest.hpp>
+#include <com/sun/star/task/InteractionHandler.hpp>
#include <com/sun/star/beans/XPropertySet.hpp>
#include <com/sun/star/embed/ElementModes.hpp>
#include <com/sun/star/container/XNameAccess.hpp>
@@ -696,7 +697,7 @@ void SfxApplication::OpenDocExec_Impl( SfxRequest& rReq )
// intercept all incoming interactions and provide useful informations
// later if the following transaction was finished.
- ::framework::PreventDuplicateInteraction* pHandler = new ::framework::PreventDuplicateInteraction(::comphelper::getProcessServiceFactory());
+ ::framework::PreventDuplicateInteraction* pHandler = new ::framework::PreventDuplicateInteraction(::comphelper::getProcessComponentContext());
css::uno::Reference< css::task::XInteractionHandler > xHandler (static_cast< css::task::XInteractionHandler* >(pHandler), css::uno::UNO_QUERY);
css::uno::Reference< css::task::XInteractionHandler > xWrappedHandler;
@@ -1032,9 +1033,8 @@ void SfxApplication::OpenDocExec_Impl( SfxRequest& rReq )
if (!pInteractionItem)
{
- Reference < ::com::sun::star::task::XInteractionHandler > xHdl( ::comphelper::getProcessServiceFactory()->createInstance(::rtl::OUString("com.sun.star.comp.uui.UUIInteractionHandler")), UNO_QUERY );
- if (xHdl.is())
- rReq.AppendItem( SfxUnoAnyItem(SID_INTERACTIONHANDLER,::com::sun::star::uno::makeAny(xHdl)) );
+ Reference < task::XInteractionHandler2 > xHdl = task::InteractionHandler::createWithParent( ::comphelper::getProcessComponentContext(), 0 );
+ rReq.AppendItem( SfxUnoAnyItem(SID_INTERACTIONHANDLER,::com::sun::star::uno::makeAny(xHdl)) );
}
if (!pMacroExecItem)
rReq.AppendItem( SfxUInt16Item(SID_MACROEXECMODE,::com::sun::star::document::MacroExecMode::USE_CONFIG) );