diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2023-01-23 16:48:51 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2023-01-24 09:57:18 +0000 |
commit | bb0192b332d02dc6a94963992cf65cb5cfdb517b (patch) | |
tree | 8e0b5664d454249f48fd10abe7ded5af978c4986 /include | |
parent | da8d369a1fb06dfe6ef47d6e0da4402bb12ede27 (diff) |
Use ImplInheritanceHelper in OAccessibleComponentHelper
(Explicitly deleting the special member functions is needed to avoid MSVC
> include\cppuhelper/implbase.hxx(152): error C2280: 'comphelper::OCommonAccessibleComponent::OCommonAccessibleComponent(const comphelper::OCommonAccessibleComponent &)': attempting to reference a deleted function
> include\comphelper/accessiblecomponenthelper.hxx(177): note: compiler has generated 'comphelper::OCommonAccessibleComponent::OCommonAccessibleComponent' here
> include\comphelper/accessiblecomponenthelper.hxx(177): note: 'comphelper::OCommonAccessibleComponent::OCommonAccessibleComponent(const comphelper::OCommonAccessibleComponent &)': function was implicitly deleted because a base class invokes a deleted or inaccessible function 'cppu::BaseMutex::BaseMutex(const cppu::BaseMutex &)'
> include\cppuhelper/basemutex.hxx(43): note: 'cppu::BaseMutex::BaseMutex(const cppu::BaseMutex &)': function was implicitly deleted because a data member invokes a deleted or inaccessible function 'osl::Mutex::Mutex(const osl::Mutex &)'
> include\osl/mutex.hxx(107): note: 'osl::Mutex::Mutex(const osl::Mutex &)': function was explicitly deleted
> include\comphelper/accessiblecomponenthelper.hxx(200): note: see reference to function template instantiation 'cppu::ImplInheritanceHelper<comphelper::OCommonAccessibleComponent,com::sun::star::accessibility::XAccessibleComponent>::ImplInheritanceHelper<cppu::ImplInheritanceHelper<comphelper::OCommonAccessibleComponent,com::sun::star::accessibility::XAccessibleComponent>>(cppu::ImplInheritanceHelper<comphelper::OCommonAccessibleComponent,com::sun::star::accessibility::XAccessibleComponent> &&)' being compiled
> include\comphelper/accessiblecomponenthelper.hxx(200): note: see reference to function template instantiation 'cppu::ImplInheritanceHelper<comphelper::OCommonAccessibleComponent,com::sun::star::accessibility::XAccessibleComponent>::ImplInheritanceHelper<cppu::ImplInheritanceHelper<comphelper::OCommonAccessibleComponent,com::sun::star::accessibility::XAccessibleComponent>>(cppu::ImplInheritanceHelper<comphelper::OCommonAccessibleComponent,com::sun::star::accessibility::XAccessibleComponent> &&)' being compiled
)
Change-Id: Ide07c6a7c3660e469f16973d866c949d17fdf419
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/146010
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/comphelper/accessiblecomponenthelper.hxx | 22 |
1 files changed, 9 insertions, 13 deletions
diff --git a/include/comphelper/accessiblecomponenthelper.hxx b/include/comphelper/accessiblecomponenthelper.hxx index 8743b322a4d8..def0b9e2fecb 100644 --- a/include/comphelper/accessiblecomponenthelper.hxx +++ b/include/comphelper/accessiblecomponenthelper.hxx @@ -27,6 +27,7 @@ #include <comphelper/accessibleeventnotifier.hxx> #include <cppuhelper/basemutex.hxx> #include <cppuhelper/compbase.hxx> +#include <cppuhelper/implbase.hxx> #include <cppuhelper/implbase1.hxx> #include <comphelper/uno3.hxx> #include <comphelper/comphelperdllapi.h> @@ -179,28 +180,23 @@ namespace comphelper //= OAccessibleComponentHelper - struct OAccessibleComponentHelper_Base : - public ::cppu::ImplHelper1< css::accessibility::XAccessibleComponent > - { - protected: - ~OAccessibleComponentHelper_Base() {} - }; - /** a helper class for implementing an AccessibleContext which at the same time supports an XAccessibleComponent interface. */ class COMPHELPER_DLLPUBLIC OAccessibleComponentHelper - :public OCommonAccessibleComponent - ,public OAccessibleComponentHelper_Base + :public cppu::ImplInheritanceHelper< + OCommonAccessibleComponent, css::accessibility::XAccessibleComponent> { + private: + OAccessibleComponentHelper(OAccessibleComponentHelper const &) = delete; + OAccessibleComponentHelper(OAccessibleComponentHelper &&) = delete; + void operator =(OAccessibleComponentHelper const &) = delete; + void operator =(OAccessibleComponentHelper &&) = delete; + protected: OAccessibleComponentHelper(); public: - // XInterface - DECLARE_XINTERFACE( ) - DECLARE_XTYPEPROVIDER( ) - // XAccessibleComponent - default implementations virtual sal_Bool SAL_CALL containsPoint( const css::awt::Point& aPoint ) override; virtual css::awt::Point SAL_CALL getLocation( ) override; |