diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2014-03-17 16:14:27 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2014-03-17 16:52:34 +0100 |
commit | ab3acb7ef79fcae8776b8d1ce0e81da5698ef516 (patch) | |
tree | 0dad3a5d6c6897887cc8ff5c6837d83b7e89a070 /framework/source/dispatch/dispatchprovider.cxx | |
parent | 803a8a04e980d24bf6c336e4416615a49614367f (diff) |
Consolidate framework::{Read,Write}Guard
...now that it is obvious that they both do the same
Change-Id: I6878acca4750ef4204fe32a695b6d9e1c5140115
Diffstat (limited to 'framework/source/dispatch/dispatchprovider.cxx')
-rw-r--r-- | framework/source/dispatch/dispatchprovider.cxx | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/framework/source/dispatch/dispatchprovider.cxx b/framework/source/dispatch/dispatchprovider.cxx index 2f855dfd5e10..7fc0208d9ea2 100644 --- a/framework/source/dispatch/dispatchprovider.cxx +++ b/framework/source/dispatch/dispatchprovider.cxx @@ -27,8 +27,7 @@ #include <pattern/window.hxx> #include <threadhelp/transactionguard.hxx> -#include <threadhelp/readguard.hxx> -#include <threadhelp/writeguard.hxx> +#include <threadhelp/guard.hxx> #include <dispatchcommands.h> #include <protocols.h> #include <services.h> @@ -107,7 +106,7 @@ css::uno::Reference< css::frame::XDispatch > SAL_CALL DispatchProvider::queryDis css::uno::Reference< css::frame::XDispatch > xDispatcher; /* SAFE { */ - ReadGuard aReadLock( m_aLock ); + Guard aReadLock( m_aLock ); css::uno::Reference< css::frame::XFrame > xOwner( m_xFrame.get(), css::uno::UNO_QUERY ); aReadLock.unlock(); /* } SAFE */ @@ -492,7 +491,7 @@ css::uno::Reference< css::frame::XDispatch > DispatchProvider::implts_searchProt if (m_aProtocolHandlerCache.search(aURL,&aHandler)) { /* SAFE { */ - ReadGuard aReadLock( m_aLock ); + Guard aReadLock( m_aLock ); // create it css::uno::Reference< css::frame::XDispatchProvider > xHandler; @@ -568,7 +567,7 @@ css::uno::Reference< css::frame::XDispatch > DispatchProvider::implts_getOrCreat css::uno::Reference< css::frame::XDispatch > xDispatchHelper; /* SAFE { */ - ReadGuard aReadLock( m_aLock ); + Guard aReadLock( m_aLock ); css::uno::Reference< css::uno::XComponentContext > xContext = m_xContext; aReadLock.unlock(); /* } SAFE */ @@ -580,7 +579,7 @@ css::uno::Reference< css::frame::XDispatch > DispatchProvider::implts_getOrCreat // Attention: Such menue dispatcher must be a singleton for this frame - means our owner frame. // Otherwhise he can make some trouble. /* SAFE { */ - WriteGuard aWriteLock( m_aLock ); + Guard aWriteLock( m_aLock ); if ( ! m_xMenuDispatcher.is() ) { MenuDispatcher* pDispatcher = new MenuDispatcher( xContext, xOwner ); |