Returns the gizmo ID of the control that triggered the current event.
Takes no parameters.
Returns the value of the global variable LuiSource.
BGI GUI
Parameters & Returns
Parameters
This function takes no parameters.
Returns
Int
Quick Summary
Returns the gizmo ID of the control that triggered the current event.
Takes no parameters.
Returns the value of the global variable LuiSource.
Technical Exegesis...
Returns the gizmo ID of the control that triggered the current event. Returns the value of the global variable LuiSource. This is the specific control ID (gizmo handle) returned by control creation functions like bgiCreateButton, bgiCreateTextBox, bgiCreateTrackbar, etc. Returns 0 when no event is pending or if the event source is not a gizmo (e.g., window close event).
This function identifies the exact control instance that generated the event.
Returns the gizmo ID of the control that triggered the current event. Returns the value of the global variable LuiSource. This is the specific control ID (gizmo handle) returned by control creation functions like bgiCreateButton, bgiCreateTextBox, bgiCreateTrackbar, etc. Returns 0 when no event is pending or if the event source is not a gizmo (e.g., window close event).
This function identifies the exact control instance that generated the event. The LuiSource global is set to the gizmo's ID when events are dispatched from the Windows message loop. Use after determining event message and event ID to identify which specific control to query or update. Example: user clicks a button (bgiGetEventMessage() == COMMAND_CLICK, bgiGetEventID() == EVENT_ID_BUTTON), then bgiGetEventSource() tells you which button (button1, button2, etc.). Common pattern: store control IDs in variables at creation, compare bgiGetEventSource() against these IDs to route event handling logic.