Commit 52a86740 authored by David Tseng's avatar David Tseng Committed by Commit Bot

Consider clickable nodes as leaves

This aligns us more closely with how TalkBack treats clickables. Note that at the moment, only ARC++ sets the |clickable| property.

Bug: b:111083342
Change-Id: Ida5383ee34ae30b8d01a556c48044096a909eac4
Reviewed-on: https://chromium-review.googlesource.com/1243670
Commit-Queue: David Tseng <dtseng@chromium.org>
Reviewed-by: default avatarYuki Awano <yawano@chromium.org>
Cr-Commit-Position: refs/heads/master@{#594417}
parent f81a83db
......@@ -197,7 +197,8 @@ AutomationPredicate.leaf = function(node) {
node.state[State.INVISIBLE] || node.children.every(function(n) {
return n.state[State.INVISIBLE];
}) ||
!!AutomationPredicate.math(node);
// Explicitly only check the clickable attribute here (for Android).
node.clickable || !!AutomationPredicate.math(node);
};
/**
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment