summaryrefslogtreecommitdiff
path: root/sfx2/source/sidebar/ContextChangeBroadcaster.cxx
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2013-05-31 09:54:28 +0200
committerNoel Grandin <noel@peralex.com>2013-06-03 10:00:01 +0200
commite6c13f2846c684410e060701cbf1deb9bcaec890 (patch)
tree7c18df0ad2de8297cff389c091714b3eedd92621 /sfx2/source/sidebar/ContextChangeBroadcaster.cxx
parent1f79707438d84ba639a2c601ae9d25c4647d37f6 (diff)
fdo#46808, Convert XMultiServiceFactory to XComponentContext
Change-Id: Ice5ec3a056f7f2f5184523bda1c709ccac876736
Diffstat (limited to 'sfx2/source/sidebar/ContextChangeBroadcaster.cxx')
-rw-r--r--sfx2/source/sidebar/ContextChangeBroadcaster.cxx8
1 files changed, 3 insertions, 5 deletions
diff --git a/sfx2/source/sidebar/ContextChangeBroadcaster.cxx b/sfx2/source/sidebar/ContextChangeBroadcaster.cxx
index 7d5dd3a86e3b..d004ce94400c 100644
--- a/sfx2/source/sidebar/ContextChangeBroadcaster.cxx
+++ b/sfx2/source/sidebar/ContextChangeBroadcaster.cxx
@@ -19,7 +19,7 @@
#include "sfx2/sidebar/EnumContext.hxx"
#include <com/sun/star/ui/ContextChangeEventObject.hpp>
#include <com/sun/star/ui/ContextChangeEventMultiplexer.hpp>
-#include <com/sun/star/frame/XModuleManager.hpp>
+#include <com/sun/star/frame/ModuleManager.hpp>
#include <comphelper/componentcontext.hxx>
#include <comphelper/processfactory.hxx>
@@ -115,10 +115,8 @@ OUString ContextChangeBroadcaster::GetModuleName (const cssu::Reference<css::fra
return OUString();
try
{
- const ::comphelper::ComponentContext aContext (::comphelper::getProcessServiceFactory());
- const Reference<frame::XModuleManager> xModuleManager (
- aContext.createComponent("com.sun.star.frame.ModuleManager" ),
- UNO_QUERY_THROW );
+ const Reference<XComponentContext> xContext (::comphelper::getProcessComponentContext() );
+ const Reference<frame::XModuleManager> xModuleManager = frame::ModuleManager::create( xContext );
return xModuleManager->identify(rxFrame);
}
catch (const Exception&)