Bug Tracker

Opened 7 years ago

Closed 7 years ago

#12123 closed bug (invalid)

Inconsistent number of in-focus elements across different browsers

Reported by: lihan Owned by: lihan
Priority: undecided Milestone: None
Component: unfiled Version: 1.7.2
Keywords: Cc:
Blocked by: Blocking:

Description

Have already created a test page http://jsfiddle.net/MMJSP/

In Chrome/FF, when you open the page, you can see there is no current focused element which is expected.

But in IE8/9, you will see there is 1 focused element which is not expected. Furthermore, if you click on the text "Number of focus", you will see the focused element has been moved to 'BODY' element.

Is there a reason for this? Or it's a bug?

Change History (3)

comment:1 Changed 7 years ago by lihan

Please use http://jsfiddle.net/MMJSP/1/ instead.

comment:2 Changed 7 years ago by dmethvin

Owner: set to lihan
Status: newpending

On browsers that don't support the CSS :focus selector we use document.activeElement to get the focused element. The two don't always agree but I don't think we can determine those cases. If you don't expect the body to be focused in your application, can you just ignore that?

http://jsfiddle.net/MMJSP/4/

comment:3 Changed 7 years ago by trac-o-bot

Resolution: invalid
Status: pendingclosed

Because we get so many tickets, we often need to return them to the initial reporter for more information. If that person does not reply within 14 days, the ticket will automatically be closed, and that has happened in this case. If you still are interested in pursuing this issue, feel free to add a comment with the requested information and we will be happy to reopen the ticket if it is still valid. Thanks!

Note: See TracTickets for help on using tickets.