Use views not components for Litho nodes in AX tree + more sidebar props
Summary: Switches the tree to use the view hierarchy for Litho nodes rather than Litho component hierarchy since Accessibility services interact with the views rendered. Includes a few more properties in the accessibility sidebar and updates to the segmented sidebar based on derived/non-derived properties for all views. Also adds functions to the AccessibilityUtil to be able to work on the accessibility sidebar while still leaving the non-accessibility sidebar unchanged. Eventually the accessibility panel will be removed from 'normal' mode and the original functions will no longer be necessary. Reviewed By: blavalla Differential Revision: D8881739 fbshipit-source-id: 9ce37e8f18025538cba2c86c0895ee38d13d024b
This commit is contained in:
committed by
Facebook Github Bot
parent
b28e96624d
commit
0244f15dab
@@ -51,6 +51,11 @@ public class LithoViewDescriptor extends NodeDescriptor<LithoView> {
|
||||
return DebugComponent.getRootInstance(node) == null ? 0 : 1;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getAXChildCount(LithoView node) {
|
||||
return node.getChildCount();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Object getChildAt(LithoView node, int index) {
|
||||
return DebugComponent.getRootInstance(node);
|
||||
@@ -58,7 +63,7 @@ public class LithoViewDescriptor extends NodeDescriptor<LithoView> {
|
||||
|
||||
@Override
|
||||
public @Nullable Object getAXChildAt(LithoView node, int index) {
|
||||
return DebugComponent.getRootInstance(node);
|
||||
return node.getChildAt(index);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user