diff --git a/framework/inc/dispatch/oxt_handler.hxx b/framework/inc/dispatch/oxt_handler.hxx index 7ce5f92e8655..c3676c033ced 100644 --- a/framework/inc/dispatch/oxt_handler.hxx +++ b/framework/inc/dispatch/oxt_handler.hxx @@ -20,7 +20,6 @@ #ifndef INCLUDED_FRAMEWORK_INC_DISPATCH_OXT_HANDLER_HXX #define INCLUDED_FRAMEWORK_INC_DISPATCH_OXT_HANDLER_HXX -#include #include #include #include @@ -53,11 +52,7 @@ namespace framework{ @devstatus ready @threadsafe yes *//*-*************************************************************************************************************/ -class Oxt_Handler : // baseclasses - // Order is necessary for right initialization! - private ThreadHelpBase - // interfaces - , public ::cppu::WeakImplHelper3< +class Oxt_Handler : public ::cppu::WeakImplHelper3< css::lang::XServiceInfo, css::frame::XNotifyingDispatch, // => XDispatch css::document::XExtendedFilterDetection > @@ -114,6 +109,7 @@ class Oxt_Handler : // baseclasses // (should be private everyway!) private: + osl::Mutex m_mutex; css::uno::Reference< css::lang::XMultiServiceFactory > m_xFactory ; /// global uno service factory to create new services css::uno::Reference< css::uno::XInterface > m_xSelfHold ; /// we must protect us against dieing during async(!) dispatch() call! diff --git a/framework/source/dispatch/oxt_handler.cxx b/framework/source/dispatch/oxt_handler.cxx index b24eaecfa288..488f6b4af290 100644 --- a/framework/source/dispatch/oxt_handler.cxx +++ b/framework/source/dispatch/oxt_handler.cxx @@ -18,7 +18,6 @@ */ #include -#include #include #include #include @@ -60,10 +59,7 @@ DEFINE_INIT_SERVICE ( Oxt_Handler, @threadsafe yes *//*-*************************************************************************************************************/ Oxt_Handler::Oxt_Handler( const css::uno::Reference< css::lang::XMultiServiceFactory >& xFactory ) - // Init baseclasses first - : ThreadHelpBase ( ) - // Init member - , m_xFactory ( xFactory ) + : m_xFactory ( xFactory ) { } @@ -117,8 +113,7 @@ void SAL_CALL Oxt_Handler::dispatchWithNotification( const css::util::URL& aURL, const css::uno::Reference< css::frame::XDispatchResultListener >& xListener ) throw( css::uno::RuntimeException, std::exception ) { - // SAFE { - Guard aLock( m_aLock ); + osl::MutexGuard g(m_mutex); OUString sServiceName = "com.sun.star.deployment.ui.PackageManagerDialog"; css::uno::Sequence< css::uno::Any > lParams(1); @@ -137,9 +132,6 @@ void SAL_CALL Oxt_Handler::dispatchWithNotification( const css::util::URL& aURL, aEvent.State = css::frame::DispatchResultState::SUCCESS; xListener->dispatchFinished( aEvent ); } - - // } SAFE - aLock.unlock(); } void SAL_CALL Oxt_Handler::dispatch( const css::util::URL& aURL ,