Improve normalization of charCode, fix FF not reporting Enter

#1955

Haven't tested it yet (it's late), I'll run it through some manual tests tomorrow.
Hmm? I'm not sure if I fully understand, `charCode` is "character code" (which is why we can use `String.fromCharCode`) and `keyCode` is "virtual key code". All similarities between the two are circumstancial and (theoretically) implementation-defined AFAIK, but for our purposes it's rather safe to assume that `keyCode = 13` represents `charCode = 13` (since *keyboards* at least agree on enter key being 13).

I should however explain some of that there I agree :)