Consider making focus not follow mouse in chrome UI
Categories
(Core :: DOM: UI Events & Focus Handling, enhancement)
Tracking
()
Tracking | Status | |
---|---|---|
firefox88 | --- | fixed |
People
(Reporter: mstange, Assigned: emilio)
References
Details
(Whiteboard: [mac:integration])
Attachments
(1 file)
Bug 1614658 turned on accessibility.mouse_focuses_formcontrol on macOS. This affected both web content and the UI in our chrome, for example in the Preferences pages, the Downloads dialog and the "Clear Recent History" dialog.
I think this is a positive change for web content. However, I'm not so sure about making this change apply in our UI. For the latter two UI examples, we use native-looking UI, so it would be good to also follow the native focus model.
Emilio, how hard would it be to make this behavior per-document?
Reporter | ||
Comment 1•4 years ago
|
||
As a point of reference, Safari also has different behavior in its UI and its web content.
Assignee | ||
Comment 3•4 years ago
|
||
For that, we make accessibility.mouse_focuses_formcontrol a static pref,
and make it work in all platforms because it's simpler and allows to
test mac-specific things on other platforms more easily.
Updated•4 years ago
|
Comment 6•4 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/3d36671abaec
https://hg.mozilla.org/mozilla-central/rev/0dc645366911
Comment 7•4 years ago
|
||
(In reply to Markus Stange [:mstange] from comment #1)
As a point of reference, Safari also has different behavior in its UI and its web content.
Hi Markus, could you provide some more information about what kind of differences you found on the Safari UI vs web content?
I'm working on :focus-visible on WebKit and dealing with focus stuff there, so I'd love to know more about these differences.
Thank you very much!
Reporter | ||
Comment 8•4 years ago
|
||
(In reply to Manuel Rego Casasnovas from comment #7)
Hi Markus, could you provide some more information about what kind of differences you found on the Safari UI vs web content?
Hi Manuel, here are two examples:
Safari UI: 1. Focus the location bar text field. 2. Click the "sidebar" toolbar button. The text field stays focused. But you can press shift+Tab to move focus to the sidebar button. Similar examples exist in the Safari Preferences window.
Web content: 1. In Safari, go to data:text/html,<input><input%20type="button"%20value="Button">
. 2. Focus the text field. 3. Click the button. Now the text field is no longer focused.
Comment 9•4 years ago
|
||
Thanks for the info.
(In reply to Markus Stange [:mstange] from comment #8)
Safari UI: 1. Focus the location bar text field. 2. Click the "sidebar" toolbar button. The text field stays focused. But you can press shift+Tab to move focus to the sidebar button. Similar examples exist in the Safari Preferences window.
Web content: 1. In Safari, go todata:text/html,<input><input%20type="button"%20value="Button">
. 2. Focus the text field. 3. Click the button. Now the text field is no longer focused.
About the 2nd one, it doesn't matter if you click a button, or just some random content outside of the input, the input gets unfocused in that case anyway, and the activeElement afterwards is the body.
Description
•