adonthell-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Adonthell-devel] unified event system


From: Kai Sterker
Subject: [Adonthell-devel] unified event system
Date: Sat, 24 Aug 2002 21:16:41 +0200

I had some more thoughts about integrating input events into the common
event system. Before I forget them, I better send 'em to the list.

Basically, each window system object that can recieve input would
inherit from event_list. It could then add events for any keypress it
wants to recieve to the list. From there on everything would work
automatically.

Internally, C++ callbacks could be used, for example for the default
controls. When writing the GUI in python, we can easily use python
methods as callbacks instead. All that functionality is in the code
already.

When it comes to modal or transient windows, we can easily disable
keybord input for a widget or window by calling the event_list::pause
method, or enable input by calling event_list::resume. So this aspect of
input focus handling is really simple, and already in the code as well.

I'm not sure whether there are other problems. Perhaps I should have a
look at the new input system first. Still, I think it would make sense
to integrate input and event system. Especially as it would allow us to
make the player schedule event-driven as well.

Any opinions? Alex? Joel?

Kai




reply via email to

[Prev in Thread] Current Thread [Next in Thread]