Re: [whatwg] focus change inside keypress event handler

On Wed, Oct 28, 2009 at 2:43 AM, Michael A. Puls II
<> wrote:
> (CCing DOM list just in case anyone there has any comments)
> With:
> <p><input onkeypress="this.nextSibling.focus()"><input></p>
> , if you type a character in the first field, should the character be
> entered in the second field or the first?
> In Firefox and Safari, it's the first field. In IE and Opera, it's the
> second.
> I do think FF and Safari's way makes more sense and I think most will agree.

If we consider keypress to be the same as DOM-3 Events' textinput,
then it makes way more sense for the char to be added to the first
field (i.e. the Gecko/WebKit way).

My .2c

Thomas Broyer

Received on Wednesday, 28 October 2009 09:02:20 UTC