summaryrefslogtreecommitdiff
path: root/vbahelper
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2012-12-11 08:16:08 +0200
committerNoel Grandin <noel@peralex.com>2012-12-13 05:20:58 +0200
commitc1e42d60c572d23c61a703cd66495eab1cea4e05 (patch)
tree431e056f9e19802e87df477996a298771bafa237 /vbahelper
parent9779ae8bdeffe1c296803dffefa0d69b0fb8f975 (diff)
fdo#46808, use service constructor for ui::WindowStateConfiguration
Change-Id: I0b7f773a7db47049d7df4138d07e7fc38c657a65
Diffstat (limited to 'vbahelper')
-rw-r--r--vbahelper/source/vbahelper/vbacommandbarhelper.cxx5
1 files changed, 2 insertions, 3 deletions
diff --git a/vbahelper/source/vbahelper/vbacommandbarhelper.cxx b/vbahelper/source/vbahelper/vbacommandbarhelper.cxx
index 9595def041dd..5bfd4d213ab7 100644
--- a/vbahelper/source/vbahelper/vbacommandbarhelper.cxx
+++ b/vbahelper/source/vbahelper/vbacommandbarhelper.cxx
@@ -24,6 +24,7 @@
#include <com/sun/star/ui/XUIConfigurationPersistence.hpp>
#include <com/sun/star/ui/XUIElement.hpp>
#include <com/sun/star/ui/UIElementType.hpp>
+#include <com/sun/star/ui/WindowStateConfiguration.hpp>
#include <comphelper/processfactory.hxx>
#include <vbahelper/vbahelper.hxx>
#include <rtl/ustrbuf.hxx>
@@ -109,14 +110,12 @@ void VbaCommandBarHelper::Init( ) throw (css::uno::RuntimeException)
throw uno::RuntimeException( "Not implemented" , uno::Reference< uno::XInterface >() );
}
- uno::Reference< lang::XMultiServiceFactory > xServiceManager( mxContext->getServiceManager(), uno::UNO_QUERY_THROW );
-
css::uno::Reference< css::ui::XModuleUIConfigurationManagerSupplier > xUICfgMgrSupp(
css::ui::ModuleUIConfigurationManagerSupplier::create(mxContext) );
m_xAppCfgMgr.set( xUICfgMgrSupp->getUIConfigurationManager( maModuleId ), uno::UNO_QUERY_THROW );
- css::uno::Reference< css::container::XNameAccess > xNameAccess( xServiceManager->createInstance( "com.sun.star.ui.WindowStateConfiguration" ), uno::UNO_QUERY_THROW );
+ css::uno::Reference< css::container::XNameAccess > xNameAccess = css::ui::WindowStateConfiguration::create( mxContext );
m_xWindowState.set( xNameAccess->getByName( maModuleId ), uno::UNO_QUERY_THROW );
}