SIGN IN SIGN UP
facebook / react-native UNCLAIMED

A framework for building native applications using React

0 0 0 C++

Implement accessibilityOrder by building the accessibilityTree through addChildrenForAccessibility (#52743)

Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52743

We can build an accessibility tree for Talkback by overriding addChildrenForAccessibility of ViewGroup.

With this we just manually build a tree that contains the elements we care about in the order we want.

We also try to keep most of the tree intact so that coopting works properly
Changelog: [Internal]

EDITS: After backout, fixed the issue where we were incorrectly setting the `accessibility_order_parent` tag the ReactAxOrderHelper class instead of the actual view. Also, made the cast safe to prevent any unexpected issues.

Also refactored the ReactAxOrderHelper functions to not have the block scoped `traverse` functions in favor of just looping through the children of a view when calling them

Reviewed By: joevilches

Differential Revision: D78669715

fbshipit-source-id: e714367c28e722ce42895531cf18e6f2dc926556
J
Jorge Cabiedes Acosta committed
e1ae619fce906954a4ddd4cc7c4e459ff68060bd
Parent: 2de4984
Committed by Facebook GitHub Bot <facebook-github-bot@users.noreply.github.com> on 7/24/2025, 1:08:29 AM