[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [pygame] [BUG] keyboard



Ah there is one more step required to get the effect.

Start the program from an editor that doesn't set the focus
to the launched app while pressing the CTRL key. Then release the
CTRL key, set focus to the program, press 'e' and you will see the effect.

My guess is that pygame picks up the modifier state of keys on startup dispite
not having keyboard focus. So when the key is released that info isn't sent
to the app since it hasn't got focus. It should pick up the modifier keys status
every time it gets keyboard focus.

I should say that I am running on Windows Vista but have seen the same
effect on XP.
It's an admittedly obscure bug.

Bo)

Lenard Lindstrom skrev:
Bo Jangeborg wrote:
If you start Pygame with the CTRL key being pressed the program doesn't acknowledge when the CTRL key is released. It is therefore continuously reporting the key as
pressed until its pressed and released again.

I this an SDL issue ?

Bo)
Hi,

I don't see it myself. Attached is my test program.

Lenard Lindstrom

P.S. It helps to include a test program.

------------------------------------------------------------------------


No virus found in this incoming message.
Checked by AVG - www.avg.com Version: 8.5.392 / Virus Database: 270.13.20/2249 - Release Date: 07/19/09 17:59:00


Attachment: keytest.py
Description: application/python