Closed Bug 486863 Opened 15 years ago Closed 6 years ago

When a disabled form item is in focus, keyboard shortcuts do not work

Categories

(Firefox :: Keyboard Navigation, defect)

4.0 Branch
defect
Not set
major

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: bugzilla, Unassigned)

References

Details

(Keywords: access)

Attachments

(2 files)

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.9.0.8) Gecko/2009032609 Firefox/3.0.8
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.9.0.8) Gecko/2009032609 Firefox/3.0.8

When you have a form element like a text box or a button in focus, and it becomes disabled (such as when you click a submit button and the author uses JavaScript to disable it and prevent further presses), you cannot use ALT+LEFT, ALT+RIGHT or ALT+HOME to navigate, CTRL+TAB to change tabs, CTRL+W to close tab, CTRL+R to refresh, and many other shortcuts do not respond.

Reproducible: Always

Steps to Reproduce:
Create a test page with some HTML like

<input onclick="this.disabled=true" type="submit" value="Hello"/>
<input onclick="this.disabled=true" type="text" value="Hello"/>

Open some web page, and then open the test page (so you have some page(s) in your history, if you want to test ALT+LEFT to go back)

Click the form element.
Actual Results:  
While this element is 'in focus', a large number of keyboard shortcuts are not available, and all you can do is press TAB or click off the element to change focus.

Expected Results:  
Keyboard shortcuts should behave as normal.
Is this Bug 78414?
(In reply to comment #1)
I don't think so.  There are no plugins involved here.
This bug was reported using Firefox 3.0 or older, which is no longer supported. The bug has also not been changed in over 500 days and is still in UNCO.
Reporter, please retest this bug in Firefox 3.6.10 or later using a fresh profile, http://support.mozilla.com/en-US/kb/managing+profiles. If you still see this problem, please update the bug. If you no longer see the bug, please set the resolution to RESOLVED, WORKSFORME.

This is a mass search of unconfirmed bugs that have no activity on them, so if you feel a bug was marked in error, just remove the CLOSEME comment in the whiteboard within the next month.
Whiteboard: [CLOSEME 2010-11-15]
This bug still exists in in Firefox 3.6.10 and in Firefox 4 beta, and is a serious usability issue.  Please confirm it.
Keywords: access
Whiteboard: [CLOSEME 2010-11-15]
Use this example to test keyboard issues when a disabled button has focus. Browse to another page first to get a page in your history, allowing you to test ALT+LEFT as well.  Note that mouse buttons are not affected.
This example proves that the problem is with a disabled element having focus.  It also shows that after the element is blurred, it is not possible for it to gain focus again.

This leads me to believe that a disabled element should never be able to keep focus in the first place, and a fix should be made to automatically blur any element which is dynamically disabled, perhaps via an event listener.
Issue still reproducible in FF 4.0.1.
Version: unspecified → 4.0 Branch
See Also: → 706773
I can confirm on
http://hg.mozilla.org/mozilla-central/rev/cc94a16983b0
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:11.0a1) Gecko/20111130 Firefox/11.0a1 ID:20111130031011
Status: UNCONFIRMED → NEW
Ever confirmed: true
No longer an issue in 58.0.2.
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: