diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2012-09-19 13:15:15 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2012-09-19 13:16:38 +0200 |
commit | 03a9f139bd9ea1a4f9096fc982e6b326def58532 (patch) | |
tree | bfb7a08bb4831a1a46b48c3bb49afa77ca436349 /svtools | |
parent | e8a169c93d7e2443a2e56afe7e99cd0721a2c27b (diff) |
ComponentContext::getUnoContext -> getComponentContext simplification
...and some further clean-up.
Change-Id: If5dce53e382b56390c502d0d0d93fc06cbfe33ea
Diffstat (limited to 'svtools')
-rw-r--r-- | svtools/source/misc/acceleratorexecute.cxx | 8 | ||||
-rw-r--r-- | svtools/source/misc/imageresourceaccess.cxx | 4 | ||||
-rw-r--r-- | svtools/source/uno/framestatuslistener.cxx | 10 | ||||
-rw-r--r-- | svtools/source/uno/generictoolboxcontroller.cxx | 4 | ||||
-rw-r--r-- | svtools/source/uno/popupmenucontrollerbase.cxx | 4 | ||||
-rw-r--r-- | svtools/source/uno/statusbarcontroller.cxx | 4 | ||||
-rw-r--r-- | svtools/source/uno/toolboxcontroller.cxx | 6 |
7 files changed, 20 insertions, 20 deletions
diff --git a/svtools/source/misc/acceleratorexecute.cxx b/svtools/source/misc/acceleratorexecute.cxx index 8351bf147454..bbaa4247029c 100644 --- a/svtools/source/misc/acceleratorexecute.cxx +++ b/svtools/source/misc/acceleratorexecute.cxx @@ -40,7 +40,7 @@ #include <com/sun/star/lang/DisposedException.hpp> #include <com/sun/star/util/URLTransformer.hpp> #include <toolkit/helper/vclunohelper.hxx> -#include <comphelper/componentcontext.hxx> +#include <comphelper/processfactory.hxx> #include <vcl/window.hxx> #include <vcl/svapp.hxx> @@ -389,7 +389,7 @@ css::uno::Reference< css::ui::XAcceleratorConfiguration > AcceleratorExecute::st const css::uno::Reference< css::frame::XFrame >& xFrame) { css::uno::Reference< css::frame::XModuleManager2 > xModuleDetection( - css::frame::ModuleManager::create(comphelper::ComponentContext(xSMGR).getUNOContext())); + css::frame::ModuleManager::create(comphelper::getComponentContext(xSMGR))); ::rtl::OUString sModule; try @@ -402,7 +402,7 @@ css::uno::Reference< css::ui::XAcceleratorConfiguration > AcceleratorExecute::st { return css::uno::Reference< css::ui::XAcceleratorConfiguration >(); } css::uno::Reference< css::ui::XModuleUIConfigurationManagerSupplier > xUISupplier( - css::ui::ModuleUIConfigurationManagerSupplier::create(comphelper::ComponentContext(xSMGR).getUNOContext()) ); + css::ui::ModuleUIConfigurationManagerSupplier::create(comphelper::getComponentContext(xSMGR)) ); css::uno::Reference< css::ui::XAcceleratorConfiguration > xAccCfg; try @@ -442,7 +442,7 @@ css::uno::Reference< css::util::XURLTransformer > AcceleratorExecute::impl_ts_ge // <- SAFE ---------------------------------- css::uno::Reference< css::util::XURLTransformer > xParser( - css::util::URLTransformer::create( ::comphelper::ComponentContext(xSMGR).getUNOContext() ) ); + css::util::URLTransformer::create( ::comphelper::getComponentContext(xSMGR) ) ); // SAFE -> ---------------------------------- aLock.reset(); diff --git a/svtools/source/misc/imageresourceaccess.cxx b/svtools/source/misc/imageresourceaccess.cxx index b34eea012426..65494581997e 100644 --- a/svtools/source/misc/imageresourceaccess.cxx +++ b/svtools/source/misc/imageresourceaccess.cxx @@ -38,7 +38,7 @@ #include <tools/stream.hxx> #include <unotools/streamwrap.hxx> #include <cppuhelper/implbase2.hxx> -#include <comphelper/componentcontext.hxx> +#include <comphelper/processfactory.hxx> //........................................................................ namespace svt @@ -154,7 +154,7 @@ namespace svt try { // get a GraphicProvider - Reference< XGraphicProvider > xProvider = ::com::sun::star::graphic::GraphicProvider::create(comphelper::ComponentContext(_rxORB).getUNOContext()); + Reference< XGraphicProvider > xProvider = ::com::sun::star::graphic::GraphicProvider::create(comphelper::getComponentContext(_rxORB)); // let it create a graphic from the given URL Sequence< PropertyValue > aMediaProperties( 1 ); diff --git a/svtools/source/uno/framestatuslistener.cxx b/svtools/source/uno/framestatuslistener.cxx index 909170dd4da5..dfae43732116 100644 --- a/svtools/source/uno/framestatuslistener.cxx +++ b/svtools/source/uno/framestatuslistener.cxx @@ -32,7 +32,7 @@ #include <com/sun/star/util/URLTransformer.hpp> #include <osl/mutex.hxx> #include <vcl/svapp.hxx> -#include <comphelper/componentcontext.hxx> +#include <comphelper/processfactory.hxx> using namespace ::cppu; using namespace ::com::sun::star::awt; @@ -105,7 +105,7 @@ throw (::com::sun::star::uno::RuntimeException) try { Reference< XDispatch > xDispatch( pIter->second ); - Reference< XURLTransformer > xURLTransformer( com::sun::star::util::URLTransformer::create( ::comphelper::ComponentContext(m_xServiceManager).getUNOContext() ) ); + Reference< XURLTransformer > xURLTransformer( com::sun::star::util::URLTransformer::create( ::comphelper::getComponentContext(m_xServiceManager) ) ); com::sun::star::util::URL aTargetURL; aTargetURL.Complete = pIter->first; xURLTransformer->parseStrict( aTargetURL ); @@ -192,7 +192,7 @@ void FrameStatusListener::addStatusListener( const rtl::OUString& aCommandURL ) Reference< XDispatchProvider > xDispatchProvider( m_xFrame, UNO_QUERY ); if ( m_xServiceManager.is() && xDispatchProvider.is() ) { - Reference< XURLTransformer > xURLTransformer( com::sun::star::util::URLTransformer::create( ::comphelper::ComponentContext(m_xServiceManager).getUNOContext() ) ); + Reference< XURLTransformer > xURLTransformer( com::sun::star::util::URLTransformer::create( ::comphelper::getComponentContext(m_xServiceManager) ) ); aTargetURL.Complete = aCommandURL; xURLTransformer->parseStrict( aTargetURL ); xDispatch = xDispatchProvider->queryDispatch( aTargetURL, ::rtl::OUString(), 0 ); @@ -250,7 +250,7 @@ void FrameStatusListener::bindListener() URLToDispatchMap::iterator pIter = m_aListenerMap.begin(); while ( pIter != m_aListenerMap.end() ) { - Reference< XURLTransformer > xURLTransformer( com::sun::star::util::URLTransformer::create( ::comphelper::ComponentContext(m_xServiceManager).getUNOContext() ) ); + Reference< XURLTransformer > xURLTransformer( com::sun::star::util::URLTransformer::create( ::comphelper::getComponentContext(m_xServiceManager) ) ); com::sun::star::util::URL aTargetURL; aTargetURL.Complete = pIter->first; xURLTransformer->parseStrict( aTargetURL ); @@ -319,7 +319,7 @@ void FrameStatusListener::unbindListener() URLToDispatchMap::iterator pIter = m_aListenerMap.begin(); while ( pIter != m_aListenerMap.end() ) { - Reference< XURLTransformer > xURLTransformer( com::sun::star::util::URLTransformer::create( ::comphelper::ComponentContext(m_xServiceManager).getUNOContext() ) ); + Reference< XURLTransformer > xURLTransformer( com::sun::star::util::URLTransformer::create( ::comphelper::getComponentContext(m_xServiceManager) ) ); com::sun::star::util::URL aTargetURL; aTargetURL.Complete = pIter->first; xURLTransformer->parseStrict( aTargetURL ); diff --git a/svtools/source/uno/generictoolboxcontroller.cxx b/svtools/source/uno/generictoolboxcontroller.cxx index 91c99a70d3ee..d6a1dae2ca74 100644 --- a/svtools/source/uno/generictoolboxcontroller.cxx +++ b/svtools/source/uno/generictoolboxcontroller.cxx @@ -36,7 +36,7 @@ #include <com/sun/star/frame/status/ItemStatus.hpp> #include <com/sun/star/frame/status/ItemState.hpp> -#include <comphelper/componentcontext.hxx> +#include <comphelper/processfactory.hxx> #include <osl/mutex.hxx> #include <vcl/svapp.hxx> @@ -108,7 +108,7 @@ throw ( RuntimeException ) m_xServiceManager.is() && !m_aCommandURL.isEmpty() ) { - xURLTransformer = com::sun::star::util::URLTransformer::create( ::comphelper::ComponentContext(m_xServiceManager).getUNOContext() ); + xURLTransformer = com::sun::star::util::URLTransformer::create( ::comphelper::getComponentContext(m_xServiceManager) ); aCommandURL = m_aCommandURL; URLToDispatchMap::iterator pIter = m_aListenerMap.find( m_aCommandURL ); diff --git a/svtools/source/uno/popupmenucontrollerbase.cxx b/svtools/source/uno/popupmenucontrollerbase.cxx index 7f0c90211993..3b5607b3b4be 100644 --- a/svtools/source/uno/popupmenucontrollerbase.cxx +++ b/svtools/source/uno/popupmenucontrollerbase.cxx @@ -41,7 +41,7 @@ #include <rtl/ustrbuf.hxx> #include <rtl/logfile.hxx> #include <osl/mutex.hxx> -#include <comphelper/componentcontext.hxx> +#include <comphelper/processfactory.hxx> //_________________________________________________________________________________________________________________ // Defines @@ -77,7 +77,7 @@ PopupMenuControllerBase::PopupMenuControllerBase( const Reference< XMultiService m_xServiceManager( xServiceManager ) { if ( m_xServiceManager.is() ) - m_xURLTransformer.set( util::URLTransformer::create( ::comphelper::ComponentContext(m_xServiceManager).getUNOContext() ) ); + m_xURLTransformer.set( util::URLTransformer::create( ::comphelper::getComponentContext(m_xServiceManager) ) ); } PopupMenuControllerBase::~PopupMenuControllerBase() diff --git a/svtools/source/uno/statusbarcontroller.cxx b/svtools/source/uno/statusbarcontroller.cxx index 55f383e87786..88ca99e49c9c 100644 --- a/svtools/source/uno/statusbarcontroller.cxx +++ b/svtools/source/uno/statusbarcontroller.cxx @@ -40,7 +40,7 @@ #include <svtools/imgdef.hxx> #include <svtools/miscopt.hxx> #include <toolkit/unohlp.hxx> -#include <comphelper/componentcontext.hxx> +#include <comphelper/processfactory.hxx> using namespace ::cppu; using namespace ::com::sun::star::awt; @@ -94,7 +94,7 @@ Reference< XURLTransformer > StatusbarController::getURLTransformer() const SolarMutexGuard aSolarMutexGuard; if ( !m_xURLTransformer.is() && m_xServiceManager.is() ) { - m_xURLTransformer = com::sun::star::util::URLTransformer::create( ::comphelper::ComponentContext(m_xServiceManager).getUNOContext() ); + m_xURLTransformer = com::sun::star::util::URLTransformer::create( ::comphelper::getComponentContext(m_xServiceManager) ); } return m_xURLTransformer; diff --git a/svtools/source/uno/toolboxcontroller.cxx b/svtools/source/uno/toolboxcontroller.cxx index 10b9e85862a4..a296f6ccea74 100644 --- a/svtools/source/uno/toolboxcontroller.cxx +++ b/svtools/source/uno/toolboxcontroller.cxx @@ -40,7 +40,7 @@ #include <svtools/miscopt.hxx> #include <toolkit/unohlp.hxx> #include <vcl/toolbox.hxx> -#include <comphelper/componentcontext.hxx> +#include <comphelper/processfactory.hxx> const int TOOLBARCONTROLLER_PROPHANDLE_SUPPORTSVISIBLE = 1; const char TOOLBARCONTROLLER_PROPNAME_SUPPORTSVISIBLE[] = "SupportsVisible"; @@ -107,7 +107,7 @@ ToolboxController::ToolboxController( { m_pImpl->m_xUrlTransformer.set( ::com::sun::star::util::URLTransformer::create( - ::comphelper::ComponentContext(m_xServiceManager).getUNOContext() ) ); + ::comphelper::getComponentContext(m_xServiceManager) ) ); } catch(const Exception&) { @@ -245,7 +245,7 @@ throw ( Exception, RuntimeException ) if ( !m_pImpl->m_xUrlTransformer.is() && m_xServiceManager.is() ) m_pImpl->m_xUrlTransformer.set( ::com::sun::star::util::URLTransformer::create( - ::comphelper::ComponentContext(m_xServiceManager).getUNOContext() ) ); + ::comphelper::getComponentContext(m_xServiceManager) ) ); } catch(const Exception&) { |