Opened 9 years ago

Closed 9 years ago

Last modified 8 years ago

#12495 closed defect (fixed)

IE9: evt.charOrCode set incorrectly for ESCAPE key

Reported by: bill Owned by: sjmiles
Priority: high Milestone: 1.5.2
Component: Events Version: 1.6.0
Keywords: Cc:
Blocked By: Blocking:

Description

See test_TooltipDialog.html. Open first dialog and then press ESCAPE key to close the dialog. On IE9, it has no effect.

For dojo normalized events, evt.charOrCode should be set to 27 for the ESCAPE key. However, on IE9, it's set to a character instead. Thus our existing code that checks evt.charOrCode doesn't realize it's the ESCAPE key.

The problem is in event.js: _setKeyChar() depends on evt.charCode being 0/null/""/etc., but on IE9 it's a valid character.

Attachments (1)

ie9CharOrCode.patch (555 bytes) - added by bill 9 years ago.
make IE9 report numbers rather than strings for codes <32, like other browsers. are there other cases to worry about?

Download all attachments as: .zip

Change History (4)

Changed 9 years ago by bill

Attachment: ie9CharOrCode.patch added

make IE9 report numbers rather than strings for codes <32, like other browsers. are there other cases to worry about?

comment:1 Changed 9 years ago by bill

Resolution: fixed
Status: newclosed

(In [24088]) On IE9, fix evt.charOrCode on IE9 to be number rather than character, to be consistent w/dojo's behavior on other browsers. Fixes #12495 on trunk, !strict.

comment:2 Changed 9 years ago by bill

(In [24089]) On IE9, fix evt.charOrCode on IE9 to be number rather than character, to be consistent w/dojo's behavior on other browsers. Fixes #12495 on 1.6/ branch, !strict.

comment:3 Changed 8 years ago by Kenneth G. Franqueiro

Milestone: 1.6.11.5.2

Updating milestone to 1.5.2 to reflect inclusion in changeset [26956] for ticket #14199.

Note: See TracTickets for help on using tickets.