Closed Bug 1817634 Opened 1 year ago Closed 1 year ago

:focus-visible pseudo-class incorrectly enabled on mouse click when access keys are enabled

Categories

(Core :: DOM: UI Events & Focus Handling, defect)

Firefox 110
defect

Tracking

()

VERIFIED FIXED
112 Branch
Tracking Status
firefox-esr102 --- unaffected
firefox110 --- wontfix
firefox111 --- verified
firefox112 --- verified

People

(Reporter: davri, Assigned: emilio)

References

(Regression)

Details

(Keywords: regression)

Attachments

(1 file)

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:109.0) Gecko/20100101 Firefox/110.0

Steps to reproduce:

Enable the "Underline access keys when available" option in windows 10 Ease of access settings, and click on a link or a form element on a website that doesn't override the default ua styles (eg. developer.mozilla.org).

Actual results:

A double focus ring appears even when keyboard navigation isn't used. This wasn't the case in v109 and earlier versions.

Expected results:

Underlining access keys shouldn't have an effect on how mouse clicks are interpreted. Alternatively there should be an option to completely toggle the behavior (accessibility.mouse_focuses_formcontrol doesn't include dropdowns and clickable links).

Component: Untriaged → DOM: UI Events & Focus Handling
Product: Firefox → Core

This seemed like the intention of this code always, see bug 1807687 and the comments in the patch in particular. Seemed to be the Win32 behavior since ~forever. Creating a ui.showKeyboardCues preference in about:config with the value 0 overrides the system value. But maybe we should consider just removing that code and make it not force focus rings either.

Regressed by: 1807687
See Also: → 1807687

Other browsers don't do this, and it might confuse users, see e.g., 1
and bug 1813684.

Before Firefox 110, we didn't do it consistently, but I fixed that in
bug 1807687. See comments in the patch for context, 2 in particular:

The code being removed here is intended to implement the Windows
setting 'Underline access keys' in the Keyboard Accessibility
control panel, which somewhat confusingly also controls whether
focus rings appear by default when clicking on controls. The former
part -- the showing and hiding of the underlines based on the
setting -- was never yet implemented, this is bug 25894. The focus
rings part was implemented.

Given:

  • This setting is confusing.
  • Modern windows apps and other browsers don't follow it.
  • We already provide other means of achieving the same behavior
    (browser.display.show_focus_rings=true).

It seems better to remove. I asked Neil in bug 1813684 in case he felt
more strongly about this, and didn't hear back.

Assignee: nobody → emilio
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true

Set release status flags based on info from the regressing bug 1807687

Pushed by ealvarez@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/726d4222d7f4
Remove "show keyboard cues" handling. r=cmartin
Status: ASSIGNED → RESOLVED
Closed: 1 year ago
Resolution: --- → FIXED
Target Milestone: --- → 112 Branch

The patch landed in nightly and beta is affected.
:emilio, is this bug important enough to require an uplift?

  • If yes, please nominate the patch for beta approval.
  • If no, please set status-firefox111 to wontfix.

For more information, please visit auto_nag documentation.

Flags: needinfo?(emilio)

Comment on attachment 9318819 [details]
Bug 1817634 - Remove "show keyboard cues" handling. r=cmartin

Beta/Release Uplift Approval Request

  • User impact if declined: See comment 0 and links from the patch. This restores to pre-110 behavior for most users.
  • Is this code covered by automated tests?: Yes
  • Has the fix been verified in Nightly?: Yes
  • Needs manual test from QE?: Yes
  • If yes, steps to reproduce: comment 0
  • List of other uplifts needed: none
  • Risk to taking this patch: Low
  • Why is the change risky/not risky? (and alternatives if risky): Trivial patch, removing code.
  • String changes made/needed: none
  • Is Android affected?: No
Flags: needinfo?(emilio)
Attachment #9318819 - Flags: approval-mozilla-beta?
Flags: qe-verify+

Comment on attachment 9318819 [details]
Bug 1817634 - Remove "show keyboard cues" handling. r=cmartin

Approved for 111.0b5

Attachment #9318819 - Flags: approval-mozilla-beta? → approval-mozilla-beta+
QA Whiteboard: [qa-triaged]

Reproduced the issue on Firefox 112.0a1 (2023-02-19) on Windows 10 by following the informations provided in Comment 0.

The issue is fixed on Firefox 111.0b6 and Firefox 112.0a1 (2023-02-26) on the same system.

Status: RESOLVED → VERIFIED
QA Whiteboard: [qa-triaged]
Flags: qe-verify+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: