summaryrefslogtreecommitdiff
path: root/framework/source/uielement/uicommanddescription.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'framework/source/uielement/uicommanddescription.cxx')
-rw-r--r--framework/source/uielement/uicommanddescription.cxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/framework/source/uielement/uicommanddescription.cxx b/framework/source/uielement/uicommanddescription.cxx
index 4715e1c1a453..102f9217a051 100644
--- a/framework/source/uielement/uicommanddescription.cxx
+++ b/framework/source/uielement/uicommanddescription.cxx
@@ -36,6 +36,7 @@
#include <com/sun/star/beans/PropertyValue.hpp>
#include <com/sun/star/beans/XPropertySet.hpp>
+#include <com/sun/star/frame/ModuleManager.hpp>
#include <com/sun/star/container/XNameAccess.hpp>
#include <com/sun/star/container/XNameContainer.hpp>
#include <com/sun/star/container/XContainer.hpp>
@@ -662,7 +663,7 @@ UICommandDescription::~UICommandDescription()
}
void UICommandDescription::impl_fillElements(const sal_Char* _pName)
{
- m_xModuleManager.set( m_xServiceManager->createInstance( SERVICENAME_MODULEMANAGER ),UNO_QUERY );
+ m_xModuleManager.set( ModuleManager::create( comphelper::getComponentContext(m_xServiceManager) ) );
Reference< XNameAccess > xNameAccess( m_xModuleManager, UNO_QUERY_THROW );
Sequence< rtl::OUString > aElementNames = xNameAccess->getElementNames();
Sequence< PropertyValue > aSeq;