... | ... | @@ -213,7 +213,7 @@ BOOL InitCustomInput (INPUT* input, const char* mdev, const char* mtype); |
|
|
void TermCustomInput (void);
|
|
|
```
|
|
|
|
|
|
In `InitCustomInput` function, you should fill the operators (the callbacks)
|
|
|
In `InitCustomInput` function, you should fill the operations (the callbacks)
|
|
|
of `input` argument, the pointer to a INPUT structure:
|
|
|
|
|
|
```cpp
|
... | ... | @@ -250,7 +250,7 @@ typedef struct tagINPUT { |
|
|
} INPUT;
|
|
|
```
|
|
|
|
|
|
The key to support extra input messages is the new operator: `wait_event_ex`.
|
|
|
The key to support extra input messages is the new operation: `wait_event_ex`.
|
|
|
If you implement `wait_event_ex`, you can set `wait_event` to be NULL.
|
|
|
|
|
|
In the implementation of `wait_event_ex`, when there is an extra input message,
|
... | ... | @@ -265,7 +265,7 @@ you should: |
|
|
extra->lparam = MAKELONG(mouse_event->sv, mouse_event->dsv);
|
|
|
```
|
|
|
|
|
|
1. Make sure the return value of this operator have the bit of `IAL_EVENT_EXTRA` set:
|
|
|
1. Make sure the return value of this operation has the bit of `IAL_EVENT_EXTRA` set:
|
|
|
|
|
|
```cpp
|
|
|
retval |= IAL_EVENT_EXTRA;
|
... | ... | |