From b552f521f6bbf917ae41ccfcddeb498c75c824e3 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Tue, 11 Dec 2012 11:27:08 +0200 Subject: fdo#46808, Adapt ui::UIElementFactoryManager UNO service to new style Required creating a new merged interface. Change-Id: I12be54e7e4c0614a31a04715342aa244d1687c42 --- framework/source/layoutmanager/layoutmanager.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'framework/source/layoutmanager') diff --git a/framework/source/layoutmanager/layoutmanager.cxx b/framework/source/layoutmanager/layoutmanager.cxx index 18f1f81ec386..a91642888977 100644 --- a/framework/source/layoutmanager/layoutmanager.cxx +++ b/framework/source/layoutmanager/layoutmanager.cxx @@ -51,6 +51,7 @@ #include #include #include +#include #include #include #include @@ -131,8 +132,7 @@ LayoutManager::LayoutManager( const Reference< XMultiServiceFactory >& xServiceM , m_bMenuBarCloser( false ) , m_pInplaceMenuBar( NULL ) , m_xModuleManager( ModuleManager::create( comphelper::getComponentContext(xServiceManager) )) - , m_xUIElementFactoryManager( Reference< ui::XUIElementFactory >( - xServiceManager->createInstance( SERVICENAME_UIELEMENTFACTORYMANAGER ), UNO_QUERY )) + , m_xUIElementFactoryManager( ui::UIElementFactoryManager::create(comphelper::getComponentContext(xServiceManager)) ) , m_xPersistentWindowStateSupplier( ui::WindowStateConfiguration::create( comphelper::getComponentContext(xServiceManager) ) ) , m_pGlobalSettings( 0 ) , m_aStatusBarAlias( "private:resource/statusbar/statusbar" ) @@ -155,7 +155,7 @@ LayoutManager::LayoutManager( const Reference< XMultiServiceFactory >& xServiceM m_aStatusBarElement.m_aType = rtl::OUString( "statusbar" ); m_aStatusBarElement.m_aName = m_aStatusBarAlias; - m_pToolbarManager = new ToolbarLayoutManager( comphelper::getComponentContext(xServiceManager), m_xUIElementFactoryManager, this ); + m_pToolbarManager = new ToolbarLayoutManager( comphelper::getComponentContext(xServiceManager), Reference(m_xUIElementFactoryManager, UNO_QUERY_THROW), this ); m_xToolbarManager = uno::Reference< ui::XUIConfigurationListener >( static_cast< OWeakObject* >( m_pToolbarManager ), uno::UNO_QUERY ); Application::AddEventListener( LINK( this, LayoutManager, SettingsChanged ) ); -- cgit