Home | History | Annotate | Download | only in validators

Lines Matching refs:element

31   public boolean isApplicable(UiElement element, Action action) {
36 public String validate(UiElement element, Action action) {
37 return isSpeakingNode(element) ? null : "TalkBack cannot speak about it";
41 private static boolean isAccessibilityFocusable(UiElement element) {
42 if (isActionableForAccessibility(element)) {
46 if (isTopLevelScrollItem(element) && (isSpeakingNode(element))) {
52 private static boolean isTopLevelScrollItem(UiElement element) {
53 UiElement parent = element.getParent();
57 private static boolean isActionableForAccessibility(UiElement element) {
58 if (element.isFocusable() || element.isClickable() || element.isLongClickable()) {
62 if (element instanceof UiAutomationElement) {
63 AccessibilityNodeInfo node = ((UiAutomationElement) element).getRawElement();
69 private static boolean isSpeakingNode(UiElement element) {
70 return hasContentDescriptionOrText(element) || element.isCheckable()
71 || hasNonActionableSpeakingChildren(element);
74 private static boolean hasNonActionableSpeakingChildren(UiElement element) {
76 for (UiElement child : element.getChildren(UiElement.VISIBLE)) {
84 private static boolean hasContentDescriptionOrText(UiElement element) {
85 return !TextUtils.isEmpty(element.getContentDescription())
86 || !TextUtils.isEmpty(element.getText());