[Xcb] Xproto generated values

Elie Dac ervadac at gmail.com
Wed Jun 4 00:40:39 PDT 2014


Hi,

In order to handle xcb events, I've created a static array which
contains a specific event handler for each event (or NULL if not
needed). I actually wanted to avoid the switch case.
The array index is basically XCB_EVENT_RESPONSE_TYPE(event) and of
course, I always check this index to not be out of bounds.
I'm just wondering if there is a new event in the future, what its
value would be?
To be clear, the last value is currently:

#define XCB_MAPPING_NOTIFY 34


Can a future event be inserted between two already existing events?
(which would change the value of all following events)
Or, it is really supposed to be last_event_value + 1?

Thanks,

Elie


More information about the Xcb mailing list