From bb6ed27b50d8832bfd105d3e8cff9abfad5c617a Mon Sep 17 00:00:00 2001 From: Michael Weghorn Date: Sat, 11 Nov 2023 00:04:48 +0100 Subject: [PATCH] a11y uia: Map 3 more roles to UIA control type IDs MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit For QAccessible::Paragraph and QAccessible::Heading, use UIA_TextControlTypeId as specified in the Core Accessibility API Mappings specification [1] [2]. For QAccessible::WebDocument use UIA_DocumentControlTypeId. [1] https://w3c.github.io/core-aam/#role-map-paragraph [2] https://w3c.github.io/core-aam/#role-map-heading Change-Id: Idae1e2da28b495d5d639df63c3de1260f2177142 Reviewed-by: Jan Arve Sæther --- .../platforms/windows/uiautomation/qwindowsuiautils.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/plugins/platforms/windows/uiautomation/qwindowsuiautils.cpp b/src/plugins/platforms/windows/uiautomation/qwindowsuiautils.cpp index 9287e89084..78ab3e890e 100644 --- a/src/plugins/platforms/windows/uiautomation/qwindowsuiautils.cpp +++ b/src/plugins/platforms/windows/uiautomation/qwindowsuiautils.cpp @@ -176,6 +176,9 @@ long roleToControlTypeId(QAccessible::Role role) {QAccessible::PageTabList, UIA_TabControlTypeId}, {QAccessible::Clock, UIA_CustomControlTypeId}, {QAccessible::Splitter, UIA_CustomControlTypeId}, + {QAccessible::Paragraph, UIA_TextControlTypeId}, + {QAccessible::WebDocument, UIA_DocumentControlTypeId}, + {QAccessible::Heading, UIA_TextControlTypeId}, }; return mapping.value(role, UIA_CustomControlTypeId);