include/svx/AccessibleGraphicShape.hxx | 21 --------- svx/source/accessibility/AccessibleGraphicShape.cxx | 44 +------------------- 2 files changed, 4 insertions(+), 61 deletions(-)
New commits: commit a17ca736697d95845ab2df20bef514b8ba5b4211 Author: Michael Weghorn <[email protected]> AuthorDate: Mon Jan 12 21:15:10 2026 +0100 Commit: Michael Weghorn <[email protected]> CommitDate: Tue Jan 13 21:59:00 2026 +0100 svx a11y: Use ImplInheritanceHelper for AccessibleGraphicShape Change-Id: I650870d348f49593b6dfdee3049109f0f8622ca4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/197146 Tested-by: Jenkins Reviewed-by: Michael Weghorn <[email protected]> diff --git a/include/svx/AccessibleGraphicShape.hxx b/include/svx/AccessibleGraphicShape.hxx index 472198366bae..789149d0d1a9 100644 --- a/include/svx/AccessibleGraphicShape.hxx +++ b/include/svx/AccessibleGraphicShape.hxx @@ -40,8 +40,7 @@ class AccessibleShapeTreeInfo; XAccessibleImage interface. */ class SVX_DLLPUBLIC AccessibleGraphicShape - : public AccessibleShape, - public css::accessibility::XAccessibleImage + : public cppu::ImplInheritanceHelper<AccessibleShape, css::accessibility::XAccessibleImage> { public: AccessibleGraphicShape ( @@ -58,24 +57,6 @@ public: sal_Int32 SAL_CALL getAccessibleImageWidth() override; - //===== XInterface ====================================================== - - virtual css::uno::Any SAL_CALL - queryInterface (const css::uno::Type & rType) override; - - virtual void SAL_CALL - acquire() - noexcept override; - - virtual void SAL_CALL - release() - noexcept override; - - //===== XTypeProvider =================================================== - - virtual css::uno::Sequence< css::uno::Type> SAL_CALL - getTypes() override; - protected: /// Create a name string that contains the accessible name. virtual OUString diff --git a/svx/source/accessibility/AccessibleGraphicShape.cxx b/svx/source/accessibility/AccessibleGraphicShape.cxx index 1b45a24cc5e8..14eae87938bc 100644 --- a/svx/source/accessibility/AccessibleGraphicShape.cxx +++ b/svx/source/accessibility/AccessibleGraphicShape.cxx @@ -33,10 +33,9 @@ using namespace ::com::sun::star; using namespace ::com::sun::star::accessibility; // internal -AccessibleGraphicShape::AccessibleGraphicShape ( - const AccessibleShapeInfo& rShapeInfo, - const AccessibleShapeTreeInfo& rShapeTreeInfo) - : AccessibleShape (rShapeInfo, rShapeTreeInfo) +AccessibleGraphicShape::AccessibleGraphicShape(const AccessibleShapeInfo& rShapeInfo, + const AccessibleShapeTreeInfo& rShapeTreeInfo) + : ImplInheritanceHelper(rShapeInfo, rShapeTreeInfo) { } @@ -65,43 +64,6 @@ sal_Int32 SAL_CALL AccessibleGraphicShape::getAccessibleImageWidth() return AccessibleShape::getSize().Width; } -// XInterface -css::uno::Any SAL_CALL - AccessibleGraphicShape::queryInterface (const css::uno::Type & rType) -{ - css::uno::Any aReturn = AccessibleShape::queryInterface (rType); - if ( ! aReturn.hasValue()) - aReturn = ::cppu::queryInterface (rType, - static_cast<XAccessibleImage*>(this)); - return aReturn; -} - - -void SAL_CALL - AccessibleGraphicShape::acquire() - noexcept -{ - AccessibleShape::acquire (); -} - - -void SAL_CALL - AccessibleGraphicShape::release() - noexcept -{ - AccessibleShape::release (); -} - -// XTypeProvider -uno::Sequence<uno::Type> SAL_CALL - AccessibleGraphicShape::getTypes() -{ - // Get list of types from the context base implementation... - return comphelper::concatSequences(AccessibleShape::getTypes(), - uno::Sequence { cppu::UnoType<XAccessibleImage>::get() }); -} - - /// Create the base name of this object, i.e. the name without appended number. OUString AccessibleGraphicShape::CreateAccessibleBaseName()
