Expose the AX tree of PDFs loaded via iframes on the Mac
https://bugs.webkit.org/show_bug.cgi?id=238168
Reviewed by Chris Fleizach.
Source/WebKit:
Given this markup:
<iframe src="/path/to/paystub.pdf">
An accessibility tree is built for paystub.pdf, but we don't expose it
to AX clients, making the PDF entirely inaccessible.
This happens because we were setting the AX parent to be the webpage
for full-frame PDF plugins (which an iframe with this markup is).
This behavior is correct only for main-frame (i.e. not iframe)
full-frame plugins, so this patch adds an extra condition to that logic.
Test: accessibility/mac/iframe-pdf.html
* WebProcess/Plugins/PDF/PDFPlugin.mm:
(WebKit::PDFPlugin::PDFPlugin):
LayoutTests:
* accessibility/mac/iframe-pdf-expected.txt: Added.
* accessibility/mac/iframe-pdf.html: Added.
* platform/mac-wk1/TestExpectations:
Skip new test as it always times out in WK1 (similar to
accessibility/mac/basic-embed-pdf-accessibility.html)
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@291724 268f45cc-cd09-0410-ab3c-d52691b4dbfc