Closed Bug 1594337 Opened 5 years ago Closed 5 years ago

Fission a11y: Focus inside OOP iframe not restored when dismissing popup/menu bar

Categories

(Core :: Disability Access APIs, defect, P2)

defect

Tracking

()

RESOLVED FIXED
mozilla72
Fission Milestone M4
Tracking Status
firefox72 --- fixed

People

(Reporter: Jamie, Assigned: Jamie)

References

Details

Attachments

(1 file)

STR (with Fission enabled and the NVDA screen reader):

  1. Open this test case:
    data:text/html,foo<iframe src="https://google.com/notfound">
  2. Tab twice to focus the "Google" link inside the iframe.
  3. Alt+tab away from Firefox and back again.
  4. Press NVDA+tab.
    • Observe: NVDA reports that the Google link has focus.
  5. Press alt to activate the menu bar, then alt again to dismiss it.
  6. Press NVDA+tab.
    • Expected: NVDA reports that the Google link has focus.
    • Actual: NVDA reports that a "frame" has focus.

The same happens if you open a context menu and dismiss it in step 5 instead of the menu bar. This also happens if you expand a collapsed HTML select within an OOP iframe and then collapse it.

This is similar to bug 1309271 for e10s, except here, the iframe in the top level tab document gets focus. This might be improved by bug 1556627; I'm not sure.

Fission Milestone: --- → M4

I worked out what's going on here and how to fix it. It does not depend on bug 1556627.

No longer depends on: 1556627

I have a working patch for this, but I'd like to wait until D48583 lands so I can leverage that framework to write tests.

Previously, we only restored focus within the top level remote browser.
This is fine for remote documents without iframes or only in-process iframes, as was the case with e10s.
For Fission, if an OOP iframe has focus, we need to get the appropriate nested remote browser.
Fortunately, BrowserParent::GetFocused was introduced to do exactly this.

Pushed by jteh@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/597cb65dad66
When dismissing a pop-up or the menu bar, if focus is inside an OOP iframe, restore a11y focus inside the iframe. r=yzen
Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla72
Flags: qe-verify+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: