KeyBoard Events

Hi All..

Can anyone pls tell me the expected keyboard events behaviour when a key is preesed and held down (Pressed) for a long time.I mean if i press right key arrow ..'-->' and hold it down for a long time before finally releasing it,should i get a series of "KeyPressed"&"KeyReleased" events or should it be numerous "KeyPressed " events followed by one KeyReleased event?

Thanks in advance

Pallu

[433 byte] By [Pallavi_Na] at [2007-11-27 1:55:35]
# 1
It depends on the OS, which is why you shouldn't rely on any behavour.The proper solution is to start a Timer on keyPressed() and then stop the Timer on keyReleased(). That way you can control the repeat interval independent of OS.
camickra at 2007-7-12 1:28:44 > top of Java-index,Java Essentials,Java Programming...