Opened 13 years ago

Closed 12 years ago

#6300 closed Bug (invalid)

'focus' and 'blur' events will not fire in Chrome 6.0.472.55

Reported by: Scalar Owned by:
Priority: Normal Milestone:
Component: General Version: 3.4
Keywords: Cc:


If we bind handler for 'focus' or 'blur' event, it will not be fired in Google Chrome.

Browser: Google Chrome 6.0.472.55 OS: Windows XP

Attachments (1)

test.html (1.3 KB) - added by Scalar 13 years ago.
Test file, demonstrates the bug

Download all attachments as: .zip

Change History (2)

Changed 13 years ago by Scalar

Attachment: test.html added

Test file, demonstrates the bug

comment:1 Changed 12 years ago by Jakub Ś

Keywords: blur focus chrome removed
Resolution: invalid
Status: newclosed

This is because e.document.on( 'focus' and e.document.on( 'blur' - is NOT guaranteed to work, as per each browser way of work. Some browsers focus the documentElement, some the body and some are just tricky.

To get this example working one should use (This is the correct way):

e.on('focus', TestFocus);
e.on('blur', TestBlur);
e.document.on('click', TestClick);
Note: See TracTickets for help on using tickets.
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy