[Webkit-unassigned] [Bug 232033] New: AX: Remove redundant insert of autofill button child in AccessibilityRenderObject::addTextFieldChildren

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Oct 20 12:34:30 PDT 2021


https://bugs.webkit.org/show_bug.cgi?id=232033

            Bug ID: 232033
           Summary: AX: Remove redundant insert of autofill button child
                    in AccessibilityRenderObject::addTextFieldChildren
           Product: WebKit
           Version: WebKit Nightly Build
          Hardware: Unspecified
                OS: Unspecified
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: Accessibility
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: tyler_w at apple.com
                CC: andresg_22 at apple.com,
                    webkit-bug-importer at group.apple.com

This child is represented in the DOM, so there's no reason to also insert it in AccessibilityRenderObject::addTextFieldChildren. This results in duplicate objects for this button in the AX tree. When the autofill button is created, it results in this markup:

<div pseudo="-webkit-textfield-decoration-container">
   <div>
      <div contenteditable="plaintext-only">hello</div>
   </div>
   <div pseudo="-webkit-contacts-auto-fill-button" role="button" aria-label="contact info AutoFill" style="display: block !important;"></div>
</div>

Given this:

```
<input type="text" value="hello" id="textfield">
window.internals.setShowAutoFillButton(document.getElementById("textfield"), "Contacts");
```

Then accessibilityController.accessibleElementById('textfield').childrenCount should be 2 (on non-glib platforms). But it is three. And if we look at what those three are, the first two are expected, and the last is a redundant button object:

Child 0:
AXRole: AXGroup
AXRoleDescription: group
AXSize: NSSize: {114, 13}
AXDescription:


Child 1:
AXRole: AXButton
AXRoleDescription: button
AXSize: NSSize: {23, 13}
AXDescription: contact info AutoFill


Child 2:
AXRole: AXButton
AXRoleDescription: button
AXSize: NSSize: {23, 13}
AXDescription: contact info AutoFill

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20211020/306a2e7f/attachment.htm>


More information about the webkit-unassigned mailing list