Doorhanger loses focus on navigation

NEW
Unassigned

Status

()

P3
normal
2 years ago
3 months ago

People

(Reporter: dietrich, Unassigned)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

(Reporter)

Description

2 years ago
Mac OS 55.0a1 (2017-04-03) (64-bit)

STR:

1. go to website with password form
2. enter username and password
3. firefox asks to save in the panel
4. focus username field in panel
5. web page form submission happens and new page loads

Expected: focus remains in browser chrome panel where i'm editing

Actual: panel remains open but focus is gone from panel - something in page was able to steal it from browser chrome.
Afaict this sounds a bit more dramatic than what's really happening. The popup notification indeed loses focus on navigation, which is annoying, but the focus remains on the Chrome window. Bug 1334496 might help here. I'll try that later.

Dietrich, do you have a POC where it is actually possible to move focus into the content window while the doorhanger is open? I hacked this demo together in a couple of minutes, there might be more ways to steal focus: http://output.jsbin.com/guhiyoduli
Flags: needinfo?(dietrich)
(Reporter)

Comment 2

2 years ago
> Bug 1334496 might help here. 

That bug seems to be focused (ha!) on the reverse situation: Making the popup steal focus from content in certain situations.

> Dietrich, do you have a POC where it is actually possible to move focus into
> the content window while the doorhanger is open? I hacked this demo together
> in a couple of minutes, there might be more ways to steal focus:
> http://output.jsbin.com/guhiyoduli

No, I just noticed on Mozilla's business card service, which I hadn't logged into in years, so needed to update my password. Thanks for making that test case!
Flags: needinfo?(dietrich)
Alright, thanks for reporting!
Summary: web content can steal focus from password saving panel → Doorhanger loses focus on navigation

Comment 4

2 years ago
I am trying http://output.jsbin.com/guhiyoduli, and I see the input elements flicker at the 2 second mark, but the doorhanger keeps focus. I was expecting the doorhanger to lose keyboard focus.
Priority: -- → P3

Comment 5

2 years ago
Oops, I just re-read this bug and my own comment 4 made little sense to me.
I meant to say more clearly: I don't see the bug using the jsbin page from comment 1.
My statement 'I was expecting the doorhanger to lose keyboard focus' === I was expecting to see the bug and did not.
The flicker I mentioned is my visual cue that perhaps the dialog lost and regained focus, but is not a bug in itself.
Duplicate of this bug: 1387965
Duplicate of this bug: 1506444
You need to log in before you can comment on or make changes to this bug.