Closed Bug 2018516 Opened 5 months ago Closed 4 months ago

Enable native menus for content select on macOS

Categories

(Core :: Widget: Cocoa, enhancement)

Firefox 150
enhancement

Tracking

()

RESOLVED FIXED
151 Branch
Tracking Status
relnote-firefox --- 151+
firefox150 --- wontfix
firefox151 --- fixed

People

(Reporter: sam, Assigned: sam)

References

Details

Attachments

(1 file)

After bug 1710459, native menus are supported for content select menus on macOS behind the temporary pref widget.macos.native-anchored-select. The pref is disabled by default due to the additional tests that require modifications to pass with native menus for content select. Here I will attach the patch that fixes up the tests and enables native menus by default. A pref will remain for users who prefer the non-native implementation.

After bug 1710459, native menus are supported for content select menus on macOS behind the pref widget.macos.native-anchored-select which is disabled by default. This patch makes the necessary changes to enable this by default:

  • Tests involving content select have been updated to use more native-menu-friendly functions instead of synthesizing events where applicable. Tests which specifically test non-native menu behavior have been updated to disable native menus for content select.
  • The pref widget.macos.native-anchored-select has been renamed to be more accurate, as other prefs can cause native menus to be disabled too. Changes to the pref no longer require a browser restart, so the pref can be toggled during tests.
Assignee: nobody → sam
Status: NEW → ASSIGNED
Blocks: 1725218
Severity: -- → S3
Pushed by ealvarez@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/44835206d482 https://hg.mozilla.org/integration/autoland/rev/30f8c6874e9a Enable native menus for content select on macOS. r=mac-reviewers,extension-reviewers,devtools-reviewers,layout-reviewers,tgiles,robwu,ochameau,bradwerth,emilio
Status: ASSIGNED → RESOLVED
Closed: 4 months ago
Resolution: --- → FIXED
Target Milestone: --- → 151 Branch
Blocks: 1868416

Release Note Request (optional, but appreciated)
[Why is this notable]: HTML <select> dropdowns now display as an OS-native menu on macOS, aligning their appearance and behavior with the rest of the system. Notably, scrolling works a bit differently in native menus, and longer menus may display more options at a time, improving usability. The previous behavior can be restored by disabling widget.macos.allow-native-select.
[Affects Firefox for Android]: No
[Suggested wording]: HTML <select> dropdowns now display as an OS-native menu on macOS, aligning their appearance and behavior with the rest of the system.
[Links (documentation, blog post, etc)]:

relnote-firefox: --- → ?

Added to the Fx151 nightly release notes, please allow 30 minutes for the site to update.
Keeping the relnote-firefox flag as ? to keep it on the radar for inclusion in the final Fx151 release notes.

Blocks: 2029228
Duplicate of this bug: 1801208
See Also: → 2030148
QA Whiteboard: [qa-triage-done-c152/b151]
Regressions: 2035467

Added to the final Fx151 release notes

See Also: → 2041942
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: