Closed Bug 1750680 Opened 2 years ago Closed 2 years ago

AccessibleChildren fails in-process on an OOP iframe with overridden role

Categories

(Core :: Disability Access APIs, defect)

Desktop
Windows
defect

Tracking

()

RESOLVED FIXED
98 Branch
Tracking Status
firefox98 --- fixed

People

(Reporter: Jamie, Assigned: Jamie)

References

Details

Attachments

(1 file)

STR (with the NVDA screen reader):

  1. Open this test case:
    data:text/html,before<iframe src="https://example.com/" role="navigation"></iframe>after
  2. Read the document with the arrow keys.
    • Expected: You should see the content of example.com; "Example Domain", etc.
    • Actual: The content of the iframe is completely missing.

We can't support IEnumVARIANT in AccessibleHandler for OOP iframes. However, we currently check for IA2_ROLE_INTERNAL_FRAME. Because the role is overridden, this check doesn't work and we try to use HandlerProvider::get_AllChildren, which fails exactly as described in the code comment.

I guess we can just not support IEnumVARIANT if the child count is 1, rather than checking for the role. This is kinda ugly, but it should work.

Originally reported in NVDA issue: https://github.com/nvaccess/nvda/issues/13244#issuecomment-1014901726

We need to handle OOP iframes specially when querying for IEnumVARIANT.
However, we can't rely on the role because it might be overridden by ARIA.
Instead, check for the absence of IAccessibleHyperText (which isn't supported for iframes) and a child count of 1.
This might trigger for a few things other than iframes, but it's not a problem to do what we're doing here whenever the child count is 1.

Pushed by jteh@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/04afde5e03ca
Don't use the role to check for iframes in AccessibleHandler. r=morgan
Status: NEW → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 98 Branch
QA Whiteboard: [qa-98b-p2]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: