Bug 199107 - Accessibility objects contained in links should honor the aria-haspopup attribute in the ancestor link.
Summary: Accessibility objects contained in links should honor the aria-haspopup attri...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2019-06-21 06:37 PDT by Andres Gonzalez
Modified: 2019-06-22 12:03 PDT (History)
10 users (show)

See Also:


Attachments
Patch (13.30 KB, patch)
2019-06-21 07:10 PDT, Andres Gonzalez
no flags Details | Formatted Diff | Diff
Patch (13.91 KB, patch)
2019-06-21 13:29 PDT, Andres Gonzalez
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Andres Gonzalez 2019-06-21 06:37:34 PDT
Accessibility objects contained in links should honor the aria-haspopup attribute in the ancestor link.
Comment 1 Andres Gonzalez 2019-06-21 07:10:10 PDT
Created attachment 372628 [details]
Patch
Comment 2 chris fleizach 2019-06-21 09:26:30 PDT
Comment on attachment 372628 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=372628&action=review

> Source/WebCore/accessibility/AccessibilityRenderObject.cpp:1035
> +    // If this has a link ancestor, check for the aria-haspopup attribute in the ancestor.

I think we can write this whole method as

return AccessibilityObject::matchedParent(*this, true, [&role] (const AccessibilityObject& object) {
        return !equalLettersIgnoringASCIICase(object.hasPopupValue()), "false");
    });

> LayoutTests/accessibility/ios-simulator/button-with-aria-haspopup-role-expected.txt:15
> +test10 AXTraits: 8256 for aria-haspopup=''

it's probably risky to output the actual value of the traits which may change over time. maybe better to verify that the traits are different for an object that has popup and one that does not
Comment 3 Andres Gonzalez 2019-06-21 13:29:51 PDT
Created attachment 372644 [details]
Patch
Comment 4 WebKit Commit Bot 2019-06-22 11:59:24 PDT
Comment on attachment 372644 [details]
Patch

Clearing flags on attachment: 372644

Committed r246715: <https://trac.webkit.org/changeset/246715>
Comment 5 WebKit Commit Bot 2019-06-22 11:59:26 PDT
All reviewed patches have been landed.  Closing bug.
Comment 6 Radar WebKit Bug Importer 2019-06-22 12:03:13 PDT
<rdar://problem/52021559>