diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2012-09-05 14:55:34 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2012-09-05 14:56:19 +0200 |
commit | 24391f605703bda1bcfa99ef06e5a73c6b52d267 (patch) | |
tree | 3a4cf9732c8a8c82b56cdc038e5dfda857cdc518 /sfx2/source/appl/sfxhelp.cxx | |
parent | 1c7a54e3a14ad932e68b9281420e6c469e5dd2e5 (diff) |
Some clean up of previous commit
Change-Id: I14097acf09e9663af7d7abc5f0c9d481880ecc51
Diffstat (limited to 'sfx2/source/appl/sfxhelp.cxx')
-rw-r--r-- | sfx2/source/appl/sfxhelp.cxx | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/sfx2/source/appl/sfxhelp.cxx b/sfx2/source/appl/sfxhelp.cxx index 217538300969..f2d86c2520fa 100644 --- a/sfx2/source/appl/sfxhelp.cxx +++ b/sfx2/source/appl/sfxhelp.cxx @@ -34,7 +34,6 @@ #include <com/sun/star/util/XURLTransformer.hpp> #include <com/sun/star/frame/XDispatch.hpp> #include <com/sun/star/frame/XDispatchProvider.hpp> -#include <com/sun/star/container/XNameAccess.hpp> #include <com/sun/star/beans/XPropertySet.hpp> #include <com/sun/star/frame/FrameSearchFlag.hpp> #include <toolkit/helper/vclunohelper.hxx> @@ -415,13 +414,13 @@ SfxHelp::~SfxHelp() { ::rtl::OUString sIdentifier; Reference < XFrame > xCurrentFrame; - Reference < XModuleManager > xModuleManager( ModuleManager::create(::comphelper::getProcessComponentContext()), UNO_QUERY ); + Reference < XModuleManager2 > xModuleManager( ModuleManager::create(::comphelper::getProcessComponentContext()) ); Reference < XDesktop > xDesktop( ::comphelper::getProcessServiceFactory()->createInstance( DEFINE_CONST_UNICODE("com.sun.star.frame.Desktop") ), UNO_QUERY ); if ( xDesktop.is() ) xCurrentFrame = xDesktop->getCurrentFrame(); - if ( xCurrentFrame.is() && xModuleManager.is() ) + if ( xCurrentFrame.is() ) { try { @@ -450,12 +449,10 @@ String SfxHelp::GetHelpModuleName_Impl() { try { - Reference < XModuleManager > xModuleManager( - ModuleManager::create(::comphelper::getProcessComponentContext()), UNO_QUERY ); + Reference < XModuleManager2 > xModuleManager( + ModuleManager::create(::comphelper::getProcessComponentContext()) ); Sequence< PropertyValue > lProps; - Reference< ::com::sun::star::container::XNameAccess > xCont( xModuleManager, UNO_QUERY); - if ( xCont.is() ) - xCont->getByName( aModuleIdentifier ) >>= lProps; + xModuleManager->getByName( aModuleIdentifier ) >>= lProps; for ( sal_Int32 i = 0; i < lProps.getLength(); ++i ) { if ( lProps[i].Name == "ooSetupFactoryShortName" ) |