patch to add KeyboardEvent for JavaScript
Maciej Stachowiak
mjs at apple.com
Thu Nov 6 11:37:31 CET 2003
On Nov 6, 2003, at 2:26 AM, David Faure wrote:
> On Thursday 06 November 2003 07:26, Darin Adler wrote:
>> + * khtml/ecma/kjs_events.h: Added DOMKeyboardEvent class.
>
> I am a bit surprised by this...
> The DOM3 events spec defines TextEvent but no KeyboardEvent,
> and we have TextEvent already.
Actually they current draft has both KeyboardEvents and TextEvents. See
http://www.w3.org/TR/2003/WD-DOM-Level-3-Events-20030331/
events.htmlhipt#Events-eventgroupings
> Should the two be merged, or is there a conceptual difference between
> the two?
Yes, they are different. Keyboard events are about actual raw
keypresses, and text events are about the characters generated as a
result. For example, pressing and releasing the control key would
generate keyboard events but not text events.
It's kind of funny that we have keyboard events but not text events in
WebCore and in kdelibs it's vice versa. We should probably merge your
TextEvent implementation ASAP (verifying that it matches the latest
draft).
Regards,
Macies
More information about the Khtml-devel
mailing list