Clicking anywhere on tab modal prompt should focus it

RESOLVED FIXED in Firefox 50

Status

()

RESOLVED FIXED
8 years ago
2 years ago

People

(Reporter: jk1700, Assigned: jaws)

Tracking

(Depends on: 1 bug)

Trunk
mozilla50
x86
Windows 7
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(firefox50 fixed)

Details

Attachments

(1 attachment)

(Reporter)

Description

8 years ago
User-Agent:       Mozilla/5.0 (Windows NT 6.1; WOW64; rv:2.0b9pre) Gecko/20110101 Firefox/4.0b9pre
Build Identifier: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:2.0b9pre) Gecko/20110101 Firefox/4.0b9pre

When tab modal prompt is not focused (for example user clicked on the url bar) user can focus it again by clicking the prompt text. However if other part of modal box is clicked (for example icon) box is not focused and when the box is not focused the "Esc" key doesn't work

Reproducible: Always

Steps to Reproduce:
1. type javascript:alert('test') in url bar and press enter
2. focus the url bar by clicking on it
3. click on the tab modal icon
4. press esc

Actual Results:  
Nothing happens

Expected Results:  
Prompt should close

I guess also clicking in the content area but outside the modal box should also focus modal box
(Reporter)

Updated

8 years ago
Blocks: 59314
Version: unspecified → Trunk
(Reporter)

Updated

8 years ago
Summary: Clickin anywhere on tab modal prompt should focus it → Clicking anywhere on tab modal prompt should focus it
Created attachment 8771036 [details]
Bug 622939 - Clicking anywhere on a tab-modal prompt should focus it.

Review commit: https://reviewboard.mozilla.org/r/64286/diff/#index_header
See other reviews: https://reviewboard.mozilla.org/r/64286/
Attachment #8771036 - Flags: review?(gijskruitbosch+bugs)
Assignee: nobody → jaws
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true

Comment 2

2 years ago
Comment on attachment 8771036 [details]
Bug 622939 - Clicking anywhere on a tab-modal prompt should focus it.

https://reviewboard.mozilla.org/r/64286/#review61610

This stuff is well weird.

So, I'm not opposed to r+'ing this and having it land as-is, because it fixes the case where you click the area around the container (big black area). I don't understand *why* it fixes that, because you're only changing focusability of the thing in the dialog, not the container. But it does seem to help.

However, if I follow these STR:

1. load javascript:alert('whatever') in a tab with about:blank in it.
2. click in location bar
3. click whitespace in alert dialog
4. hit [esc]

Nothing happens for me. Both with and without the patch.

So I don't think this fixes the bug as filed completely. I tried adding -moz-user-focus: normal in some more places but it didn't help. Ideas? :-)
Attachment #8771036 - Flags: review?(gijskruitbosch+bugs)

Comment 3

2 years ago
FWIW, Neil Deakin might be a better reviewer / source of suggestions here.
That's odd, this patch fixed the bug for me. Clicking in the big black area doesn't focus the dialog but clicking in the blank area of the dialog does focus it and specifically gives focus to the OK button.

I am using Windows 10. What OS did you test with? I don't expect the host OS to make a difference here though.
Flags: needinfo?(gijskruitbosch+bugs)

Comment 5

2 years ago
(In reply to Jared Wein [:jaws] (please needinfo? me) from comment #4)
> That's odd, this patch fixed the bug for me. Clicking in the big black area
> doesn't focus the dialog but clicking in the blank area of the dialog does
> focus it and specifically gives focus to the OK button.
> 
> I am using Windows 10. What OS did you test with? I don't expect the host OS
> to make a difference here though.

I tested on OS X. Makes some sense that that makes a difference because focus on OS X is weeeeeird. File a followup bug for OS X?
Flags: needinfo?(gijskruitbosch+bugs)
Comment on attachment 8771036 [details]
Bug 622939 - Clicking anywhere on a tab-modal prompt should focus it.

I filed bug 1287281 to investigate OSX.
Attachment #8771036 - Flags: review?(gijskruitbosch+bugs)

Comment 7

2 years ago
Comment on attachment 8771036 [details]
Bug 622939 - Clicking anywhere on a tab-modal prompt should focus it.

https://reviewboard.mozilla.org/r/64286/#review61774
Attachment #8771036 - Flags: review?(gijskruitbosch+bugs) → review+

Comment 8

2 years ago
Pushed by jwein@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/9ee862a030f3
Clicking anywhere on a tab-modal prompt should focus it. r=Gijs

Comment 9

2 years ago
bugherder
https://hg.mozilla.org/mozilla-central/rev/9ee862a030f3
Status: ASSIGNED → RESOLVED
Last Resolved: 2 years ago
status-firefox50: --- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla50
You need to log in before you can comment on or make changes to this bug.