Allegro.cc - Online Community

Allegro.cc Forums » Programming Questions » Not receiving any input events

This thread is locked; no one can reply to it. rss feed Print
Not receiving any input events
roger levy
Member #2,513
July 2002

I'm getting window and timer events but not mouse or keyboard. In my event handler function, I log each event that is not a timer event so I have confirmed this.

I think I am setting things up properly. Sorry the code is in Forth.

This is called right after creating the window:

#SelectExpand

This bit from the event handler logs events by doing a memory dump on the event struct. It filters out timer events. Only display events are showing up, leaving me scratching my head.

   e @ ALLEGRO_EVENT_TIMER <> if e 100 idump then

My event handler is working fine, AFAIK. Up to this point, I've been getting by with al_get_keyboard_state and al_get_mouse_state but now I would like to use events, particularly ALLEGRO_EVENT_KEY_CHAR.

EDIT:
Nevermind - resolved. Basically at some point I was uninstalling and re-installing the mouse and keyboard - it's a long story. It's working now.

---

Make games in Forth! -
http://github.com/rogerLevy/ramen

Go to: