Bug 162586

Summary: AX: Meter: [Mac] Content in label element should be used as AXTitle or AXDescription
Product: WebKit Reporter: Nan Wang <n_wang>
Component: AccessibilityAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: aboxhall, apinheiro, cfleizach, commit-queue, dmazzoni, jcraig, jdiggs, mario, n_wang, samuel_white, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: All   
OS: All   
Attachments:
Description Flags
patch
none
patch none

Description Nan Wang 2016-09-26 18:20:24 PDT
When an meter element is associated (id/for) with, or wrapped inside a label element, the AXTitle and AXDescription is unaffected by the content in the label element.
Comment 1 Radar WebKit Bug Importer 2016-09-26 18:20:38 PDT
<rdar://problem/28486923>
Comment 2 Nan Wang 2016-09-26 18:21:01 PDT
<rdar://problem/26638734>
Comment 3 Nan Wang 2016-09-26 18:26:17 PDT
Created attachment 289898 [details]
patch
Comment 4 chris fleizach 2016-09-27 11:02:17 PDT
Comment on attachment 289898 [details]
patch

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

> Source/WebCore/accessibility/AccessibilityNodeObject.cpp:1240
> +    String innerText = label->innerText();

seems like we should do the work to fetch this data if aria_Label is going to be used

> Source/WebCore/accessibility/AccessibilityNodeObject.cpp:1243
> +    if (!ariaLabel.isEmpty())

what if aria-labelledby is used on the label element
Comment 5 Nan Wang 2016-09-27 12:56:49 PDT
Created attachment 289999 [details]
patch

update from review.
- Taken care of aria-labelledby on label elements
- Added test cases
Comment 6 WebKit Commit Bot 2016-09-29 08:15:27 PDT
Comment on attachment 289999 [details]
patch

Clearing flags on attachment: 289999

Committed r206581: <http://trac.webkit.org/changeset/206581>
Comment 7 WebKit Commit Bot 2016-09-29 08:15:32 PDT
All reviewed patches have been landed.  Closing bug.