Bug 112968

Summary: FKA: mouse click on buttons causes focus (document.activeElement) to be lost
Product: WebKit Reporter: James Craig <jcraig>
Component: AccessibilityAssignee: Nobody <webkit-unassigned>
Status: UNCONFIRMED ---    
Severity: Normal CC: cfleizach, jcraig, me, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Description Flags
test case demonstrating bug none

Description James Craig 2013-03-21 14:44:22 PDT
1. Load attached test case.
2. Tab so that focus is on one of the buttons.
3. Perform a mouse click on the same button. (Notice focus ring disappears.)
4. Press Tab again. (focus has been lost and resets to the beginning of the document)

Note: It's probably okay to "hide" the focus pseudo-state when switching to a mouse, but Tabbing should cause focus to come back to the same element rather than losing document.activeElement entirely.
Comment 1 James Craig 2013-03-21 14:47:19 PDT
Created attachment 194349 [details]
test case demonstrating bug
Comment 2 Radar WebKit Bug Importer 2013-03-21 14:48:14 PDT
Comment 3 James Craig 2013-03-21 14:48:42 PDT
See expected behavior in Firefox 19 for Mac.
Comment 4 Radar WebKit Bug Importer 2013-03-21 14:49:02 PDT
Comment 5 Alexey Proskuryakov 2013-03-22 15:51:21 PDT
See also: bug 22261.
Comment 6 James Craig 2015-03-11 23:20:37 PDT
Comment 7 Mu-An Chiou 2018-08-09 11:26:44 PDT
Any updates on this? I see that there's not been any changes since the bug was reported 5 years ago. This issue makes building custom widget with focus management very tricky.