diff options
-rw-r--r-- | avmedia/source/framework/soundhandler.cxx | 4 | ||||
-rw-r--r-- | avmedia/source/framework/soundhandler.hxx | 4 | ||||
-rw-r--r-- | include/toolkit/helper/listenermultiplexer.hxx | 6 | ||||
-rw-r--r-- | include/toolkit/helper/mutexhelper.hxx | 36 |
4 files changed, 7 insertions, 43 deletions
diff --git a/avmedia/source/framework/soundhandler.cxx b/avmedia/source/framework/soundhandler.cxx index 07bee2113358..7d26c252201b 100644 --- a/avmedia/source/framework/soundhandler.cxx +++ b/avmedia/source/framework/soundhandler.cxx @@ -164,7 +164,7 @@ void SAL_CALL SoundHandler::dispatchWithNotification(const css::util::URL& const css::uno::Reference< css::frame::XDispatchResultListener >& xListener ) { // SAFE { - const ::osl::MutexGuard aLock( GetMutex() ); + const ::osl::MutexGuard aLock( m_aMutex ); utl::MediaDescriptor aDescriptor(lDescriptor); @@ -276,7 +276,7 @@ OUString SAL_CALL SoundHandler::detect( css::uno::Sequence< css::beans::Property IMPL_LINK_NOARG(SoundHandler, implts_PlayerNotify, Timer *, void) { // SAFE { - ::osl::ClearableMutexGuard aLock( GetMutex() ); + ::osl::ClearableMutexGuard aLock( m_aMutex ); if (m_xPlayer.is() && m_xPlayer->isPlaying() && m_xPlayer->getMediaTime() < m_xPlayer->getDuration()) { diff --git a/avmedia/source/framework/soundhandler.hxx b/avmedia/source/framework/soundhandler.hxx index 5575bba1876c..648cbe59dd4b 100644 --- a/avmedia/source/framework/soundhandler.hxx +++ b/avmedia/source/framework/soundhandler.hxx @@ -29,12 +29,12 @@ #include <com/sun/star/lang/XServiceInfo.hpp> +#include <cppuhelper/basemutex.hxx> #include <cppuhelper/weak.hxx> #include <vcl/timer.hxx> #include <vcl/idle.hxx> #include <tools/link.hxx> -#include <toolkit/helper/mutexhelper.hxx> namespace avmedia{ @@ -56,7 +56,7 @@ class SoundHandler : // interfaces , public css::document::XExtendedFilterDetection // baseclasses // Order is necessary for right initialization! - , private MutexHelper + , private cppu::BaseMutex , public ::cppu::OWeakObject { // public methods diff --git a/include/toolkit/helper/listenermultiplexer.hxx b/include/toolkit/helper/listenermultiplexer.hxx index 45267944c40e..b562e9e2852c 100644 --- a/include/toolkit/helper/listenermultiplexer.hxx +++ b/include/toolkit/helper/listenermultiplexer.hxx @@ -42,10 +42,10 @@ #include <com/sun/star/awt/tree/XTreeExpansionListener.hpp> #include <com/sun/star/awt/tree/XTreeEditListener.hpp> #include <com/sun/star/view/XSelectionChangeListener.hpp> +#include <cppuhelper/basemutex.hxx> #include <cppuhelper/queryinterface.hxx> #include <cppuhelper/weak.hxx> #include <comphelper/interfacecontainer3.hxx> -#include <toolkit/helper/mutexhelper.hxx> #include <toolkit/helper/macros.hxx> #include <com/sun/star/awt/grid/XGridSelectionListener.hpp> #include <com/sun/star/awt/tab/XTabPageContainerListener.hpp> @@ -53,7 +53,7 @@ // class ListenerMultiplexerBase template <class ListenerT> -class UNLESS_MERGELIBS(TOOLKIT_DLLPUBLIC) ListenerMultiplexerBase : public MutexHelper, +class UNLESS_MERGELIBS(TOOLKIT_DLLPUBLIC) ListenerMultiplexerBase : public cppu::BaseMutex, public ::comphelper::OInterfaceContainerHelper3<ListenerT>, public css::uno::XInterface { @@ -65,7 +65,7 @@ protected: public: ListenerMultiplexerBase( ::cppu::OWeakObject& rSource ) - : ::comphelper::OInterfaceContainerHelper3<ListenerT>(GetMutex()), mrContext(rSource) + : ::comphelper::OInterfaceContainerHelper3<ListenerT>(m_aMutex), mrContext(rSource) { } diff --git a/include/toolkit/helper/mutexhelper.hxx b/include/toolkit/helper/mutexhelper.hxx deleted file mode 100644 index 80c6c7303e67..000000000000 --- a/include/toolkit/helper/mutexhelper.hxx +++ /dev/null @@ -1,36 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -/* - * This file is part of the LibreOffice project. - * - * This Source Code Form is subject to the terms of the Mozilla Public - * License, v. 2.0. If a copy of the MPL was not distributed with this - * file, You can obtain one at http://mozilla.org/MPL/2.0/. - * - * This file incorporates work covered by the following license notice: - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed - * with this work for additional information regarding copyright - * ownership. The ASF licenses this file to you under the Apache - * License, Version 2.0 (the "License"); you may not use this file - * except in compliance with the License. You may obtain a copy of - * the License at http://www.apache.org/licenses/LICENSE-2.0 . - */ - -#ifndef INCLUDED_TOOLKIT_HELPER_MUTEXHELPER_HXX -#define INCLUDED_TOOLKIT_HELPER_MUTEXHELPER_HXX - -#include <osl/mutex.hxx> - -class MutexHelper -{ -private: - ::osl::Mutex maMutex; - -public: - ::osl::Mutex& GetMutex() { return maMutex; } -}; - -#endif // INCLUDED_TOOLKIT_HELPER_MUTEXHELPER_HXX - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ |