typedef struct { GR_EVENT_TYPE type; GR_WINDOW_ID wid; GR_WINDOW_ID otherid; } GR_EVENT_GENERAL;
The GR_EVENT_GENERAL structure is used by nano-X to pass data related to the events:
GR_EVENT_TYPE_TIMEOUT
GR_EVENT_TYPE_CLOSE_REQ
GR_EVENT_TYPE_MOUSE_EXIT
GR_EVENT_TYPE_MOUSE_ENTER
GR_EVENT_TYPE_FOCUS_OUT
GR_EVENT_TYPE_FOCUS_IN
Type | Name | Description |
---|---|---|
GR_EVENT_TYPE | type | The event type will be one of GR_EVENT_TYPE_TIMEOUT, GR_EVENT_TYPE_CLOSE_REQ, GR_EVENT_TYPE_MOUSE_ENTER, GR_EVENT_TYPE_MOUSE_EXIT, GR_EVENT_TYPE_FOCUS_IN, GR_EVENT_TYPE_FOCUS_OUT. |
GR_WINDOW_ID | wid | For GR_EVENT_TYPE_CLOSE_REQ events this is the ID of the window that is being closed. For GR_EVENT_TYPE_MOUSE_ENTER and GR_EVENT_TYPE_MOUSE_EXIT events this is the ID of the window the mouse is entering or exiting, respectively. For GR_EVENT_TYPE_FOCUS_IN events this is the ID of the window that is receiving the focus. For GR_EVENT_TYPE_FOCUS_OUT events this is the window that is loosing the focus. This field is unused for GR_EVENT_TYPE_TIMEOUT events. |
GR_ID | otherid | For GR_EVENT_TYPE_FOCUS_IN events this is the ID of the window that is loosing the focus. For GR_EVENT_TYPE_FOCUS_OUT events this is the ID of the window that is receiving the focus. This field is unused for all other event types. |