Re: [AD] ALLEGRO_KEY_PAD_ENTER on Windows

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


On 21.03.2011 18:22, Matthew Leverton wrote:
See<http://www.allegro.cc/forums/thread/606792>

Attached is a 5.1 patch that adds support for the
ALLEGRO_KEY_PAD_ENTER on Windows. It's possible that other keys like
right control could use the new 'extended' flag as well, but I just
did the least amount of work to get the pad-enter key detected. Tested
via the keyboard event example.

I've extended the patch. The goal was to make the left and right versions of the modifier keys work independently of each other. It works just fine for Ctrl and Alt, but the Shift keys are still problematic.

I've also tried to simplify some of the code.

Maybe the right way to do keyboard input for games is using WM_INPUT, but I don't feel like tackling that. Windows API programming just isn't fun.

Attachment: winkeyboard.diff
Description: /



Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/