#include <binder.h>
Inheritance diagram for csInputBinder:

Public Methods | |
| csInputBinder (int size=127) | |
| Create a new binder with initial bindings hash size size. More... | |
| virtual | ~csInputBinder () |
| Destructor does UnbindAll automatically. | |
| bool | HandleEvent (iEvent &ev) |
| Handle an event, a method of iEventHandler This class can be registered with the event queue: iEventQueue::RegisterListener(this, CSMASK_Input);. | |
| void | Bind (iEvent *ev, int *xvar=NULL, int *yvar=NULL) |
| Bind one or two variables to an event. More... | |
| void | Bind (csEvent &ev, int *xvar=NULL, int *yvar=NULL) |
| bool | Unbind (iEvent *ev) |
| Remove a binding. | |
| bool | Unbind (csEvent &ev) |
| bool | UnbindAll () |
| Remove all bindings. | |
Public Attributes | |
| SCF_DECLARE_IBASE | |
|
|
Create a new binder with initial bindings hash size size. size should be a prime number. |
|
|
Bind one or two variables to an event. Bind one or two 'int's to a csev*Move type event. You can bind the two axes simultaneously or separately. If yvar is NULL and the event is a y-axis type, xvar is used as yvar. Or bind a button status '(int)bool' to a csev*Up/Down type event. Will modify the existing binding if any. It is recommended that you use this in conjuction with csParseKeyDef The axis (either x, y or both) is given by whether ev.*.x is greater than ev.*.y (x) or visa versa (y) or if they are equal (both). |