Mail Archives: djgpp/1997/03/03/20:14:38
mejm2 AT hermes DOT cam DOT ac DOT uk (Michael Meeks) wrote:
> A more interesting ( possibly ) question is : why does the K/B
>hardware react like this :
> If <shift> is down, and then <arrow up> is pressed,
> The interrupt handler receives :
> <extended shift> off, <arrow up> down ?
> This really cocks up handlers that use the same map for extended
>and normal keys. ( By extended I mean a dual code thing 0xA0, code (
>perhaps ) ).
> Is there any logical reason for this / is this a figment of my
>imagination ?
You might find the behaviour even stranger if Num Lock is active, it
would then generate <extended shift on> when shift is not down. This
only happens to the grey arrow keys, not the numpad keys. The reason
for this is that a simple keyboard handler would normally translate
Shift+numpad to generate the corresponding digit, instead of the arrow
key (and vice versa with NumLock on). The hardware will try to avoid
this for the grey arrow keys by using the extended shift sequence, to
simulate an unmodified arrow key.
By the way, I thought Allegro already intercepted extended shifts?
- Raw text -