diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-01-20 12:05:56 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-01-20 12:52:45 +0200 |
commit | f7db2b5b3ffe7bff84636cdd0017e85a439b8c4f (patch) | |
tree | 9ec05735d8b315f078f52e71896f4f3dd5e168d9 /include/comphelper/SelectionMultiplex.hxx | |
parent | 7cf3ae68afb9d3f2f126e544de85f38a18ad3de0 (diff) |
use rtl::Reference in OSelectionChangeListener
instead of manual acquire/release
Change-Id: I33e3018b5deb4240d4aff1d8136ae6f8f538c779
Diffstat (limited to 'include/comphelper/SelectionMultiplex.hxx')
-rw-r--r-- | include/comphelper/SelectionMultiplex.hxx | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/include/comphelper/SelectionMultiplex.hxx b/include/comphelper/SelectionMultiplex.hxx index c63cd8fa046a..552ce3bf76a4 100644 --- a/include/comphelper/SelectionMultiplex.hxx +++ b/include/comphelper/SelectionMultiplex.hxx @@ -24,6 +24,7 @@ #include <com/sun/star/view/XSelectionSupplier.hpp> #include <cppuhelper/implbase.hxx> #include <comphelper/comphelperdllapi.h> +#include <rtl/ref.hxx> //= selection helper classes @@ -43,12 +44,12 @@ namespace comphelper { friend class OSelectionChangeMultiplexer; - OSelectionChangeMultiplexer* m_pAdapter; - ::osl::Mutex& m_rMutex; + rtl::Reference<OSelectionChangeMultiplexer> m_xAdapter; + ::osl::Mutex& m_rMutex; public: OSelectionChangeListener(::osl::Mutex& _rMutex) - : m_pAdapter(nullptr), m_rMutex(_rMutex) { } + : m_rMutex(_rMutex) { } virtual ~OSelectionChangeListener(); /// @throws css::uno::RuntimeException |