Open Bug 697446 Opened 13 years ago Updated 10 months ago

JavaScript confirm/alert/prompt dialog loses focus with Find/Find as you type

Categories

(Toolkit :: Content Prompts, defect)

x86
macOS
defect

Tracking

()

UNCONFIRMED

People

(Reporter: u142003, Unassigned)

References

Details

Attachments

(1 file)

User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:8.0) Gecko/20100101 Firefox/8.0
Build ID: 20111019081014

Steps to reproduce:

When opening a JavaScript confirm/alert/prompt dialog, it is possible to search for text on the page behind the dialog. This has the unfortunate effect that the dialog loses focus, which means you cannot hit Enter/Return or Esc to accept or decline.

Steps to reproduce:
1. Open the attached file (confirm-alert-prompt-with-find.html)
2. Click the Alert, Confirm or Prompt buttons
3. Hit Ctrl+F (or Cmd+F)
4. Type e.g. "lorem"

Result:
Text is selected in the background and the dialog loses focus. This prevents the user from accepting/declining the confirm/alert/prompt dialog with the keyboard.

Expected result:
The find bar should be disabled and the dialog should not lose focus.

N.b. This happens with Find as you type as well for confirm and alert, but not for prompt.
Blocks: 59314
Alternatively for expected result, since being able to search could actually be useful, have a keyboard method of getting back to the dialog.  Maybe pressing Escape to get out of the Find box would be good enough if it worked (right now it gets out of the Find box, but doesn't return focus to the dialog), although it does require the user to be careful not to press Escape too many times (which would activate the Cancel on the dialog, if it has one).
Attachment #569684 - Attachment mime type: text/plain → text/html
Bulk move to Toolkit::Notifications and Alerts

Filter on notifications-and-alerts-component.
Component: General → Notifications and Alerts
Product: Firefox → Toolkit
Version: 8 Branch → unspecified
Severity: normal → S3
Component: Notifications and Alerts → Content Prompts
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: