summaryrefslogtreecommitdiff
path: root/sdext
diff options
context:
space:
mode:
authorColomban Wendling <cwendling@hypra.fr>2020-04-30 10:49:37 +0200
committerStephan Bergmann <sbergman@redhat.com>2020-05-07 12:11:33 +0200
commitb46a0a7f9f88a0213b0a5ca2712b6eb93b74d088 (patch)
treeaf83d20d3c08508268c465a7c6983db294f64559 /sdext
parente420b89a698f50b174422b962a24e2a21672a178 (diff)
tdf#118418 implement scrollSubstringTo() for gtk
Define & use new accessibility scroll type compatible with IAccessible2 and extend the XAccessibleText interface to require scrollSubstringTo(). Co-authored-by: Martin Pieuchot <mpi@grenadille.net> Change-Id: Id3b2e8616892d7dcbfb41a14b72a8a457fd1dbf6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/89851 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'sdext')
-rw-r--r--sdext/source/presenter/PresenterAccessibility.cxx14
1 files changed, 14 insertions, 0 deletions
diff --git a/sdext/source/presenter/PresenterAccessibility.cxx b/sdext/source/presenter/PresenterAccessibility.cxx
index 35d094d8bf87..2c494c058a2b 100644
--- a/sdext/source/presenter/PresenterAccessibility.cxx
+++ b/sdext/source/presenter/PresenterAccessibility.cxx
@@ -28,6 +28,7 @@
#include <com/sun/star/accessibility/AccessibleEventId.hpp>
#include <com/sun/star/accessibility/AccessibleRelationType.hpp>
#include <com/sun/star/accessibility/AccessibleRole.hpp>
+#include <com/sun/star/accessibility/AccessibleScrollType.hpp>
#include <com/sun/star/accessibility/AccessibleStateType.hpp>
#include <com/sun/star/accessibility/XAccessibleComponent.hpp>
#include <com/sun/star/accessibility/XAccessibleContext.hpp>
@@ -324,6 +325,11 @@ public:
virtual sal_Bool SAL_CALL copyText (sal_Int32 nStartIndex, sal_Int32 nEndIndex) override;
+ virtual sal_Bool SAL_CALL scrollSubstringTo(
+ sal_Int32 nStartIndex,
+ sal_Int32 nEndIndex,
+ css::accessibility::AccessibleScrollType aScrollType) override;
+
protected:
virtual awt::Point GetRelativeLocation() override;
virtual awt::Size GetSize() override;
@@ -1575,6 +1581,14 @@ sal_Bool SAL_CALL PresenterAccessible::AccessibleParagraph::copyText (
return false;
}
+sal_Bool SAL_CALL PresenterAccessible::AccessibleParagraph::scrollSubstringTo(
+ sal_Int32,
+ sal_Int32,
+ AccessibleScrollType)
+{
+ return false;
+}
+
//----- protected -------------------------------------------------------------
awt::Point PresenterAccessible::AccessibleParagraph::GetRelativeLocation()