User Interface Event Handlers: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
(Very basic description.)
 
m (Fixed anchor links.)
Line 1: Line 1:
[[Category:Armed Assault: Editing]]
[[Category:Armed Assault: Editing]]
 
===Basic Overview===
 
User Interface Event Handlers are given as values in the Dialog/Control description classes.
 
===Reference List===
 
{| border="1"
{| border="1"
! Priority
! Priority
Line 55: Line 61:
|  class="notes" | Returns control.
|  class="notes" | Returns control.
|  class="scope" | Control
|  class="scope" | Control
|- <a id="onKeyDown"></a>
|- <span idonKeyDown"/>
|  class="priority" | 2
|  class="priority" | 2
|  class="event" | onKeyDown
|  class="event" | onKeyDown
|  class="fired" | Pressing any keyboard key. Fired before the <a href="#onKeyUp">onKeyUp</a> event.
|  class="fired" | Pressing any keyboard key. Fired before the [[#onKeyUp|onKeyUp]] event.
|  class="notes" | Returns the control, the code of the keyboard key and the state of Shift, Ctrl and Alt.
|  class="notes" | Returns the control, the code of the keyboard key and the state of Shift, Ctrl and Alt.
|  class="scope" | Control
|  class="scope" | Control
|- <a id="onKeyUp"></a>
|- <span idonKeyUp"/>
|  class="priority" | 2
|  class="priority" | 2
|  class="event" | onKeyUp
|  class="event" | onKeyUp
|  class="fired" | Releasing any keyboard key. Fired after the <a href="#onKeyDown">onKeyDown</a> event.
|  class="fired" | Releasing any keyboard key. Fired after the [[#onKeyDown|onKeyDown]] event.
|  class="notes" | Returns the control, the code of the keyboard key and the state of Shift, Ctrl and Alt.
|  class="notes" | Returns the control, the code of the keyboard key and the state of Shift, Ctrl and Alt.
|  class="scope" | Control
|  class="scope" | Control
Line 91: Line 97:
|  class="notes" | Returns the control and the the pressed button.
|  class="notes" | Returns the control and the the pressed button.
|  class="scope" | Control
|  class="scope" | Control
|- <a id="onMouseButtonDown"></a>
|- <span idonMouseButtonDown"/>
|  class="priority" | 2
|  class="priority" | 2
|  class="event" | onMouseButtonDown
|  class="event" | onMouseButtonDown
|  class="fired" | Pressing a mouse button. Followed by the <a href="#onMouseButtonUp">onMouseButtonUp</a> event.
|  class="fired" | Pressing a mouse button. Followed by the [[#onMouseButtonUp|onMouseButtonUp]] event.
|  class="notes" | Returns the control, the pressed button, the x and y coordinates and the state of Shift, Ctrl and Alt.
|  class="notes" | Returns the control, the pressed button, the x and y coordinates and the state of Shift, Ctrl and Alt.
|  class="scope" | Control
|  class="scope" | Control
|- <a id="onMouseButtonUp"></a>
|- <span idonMouseButtonUp"/>
|  class="priority" | 2
|  class="priority" | 2
|  class="event" | onMouseButtonUp
|  class="event" | onMouseButtonUp
|  class="fired" | Releasing a mouse button. Follows the <a href="#onMouseButtonDown">onMouseButtonDown</a> event.
|  class="fired" | Releasing a mouse button. Follows the [[#onMouseButtonDown|onMouseButtonDown]] event.
|  class="notes" | Returns the control, the pressed button, the x and y coordinates and the state of Shift, Ctrl and Alt.
|  class="notes" | Returns the control, the pressed button, the x and y coordinates and the state of Shift, Ctrl and Alt.
|  class="scope" | Control
|  class="scope" | Control
Line 151: Line 157:
|  class="notes" | Returns control.
|  class="notes" | Returns control.
|  class="scope" | Button
|  class="scope" | Button
|- <a id="onButtonDown"></a>
|- <span idonButtonDown"/>
|  class="priority" | 1
|  class="priority" | 1
|  class="event" | onButtonDown
|  class="event" | onButtonDown
Line 157: Line 163:
|  class="notes" | Returns control.
|  class="notes" | Returns control.
|  class="scope" | Button
|  class="scope" | Button
|- <a id="onButtonUp"></a>
|- <span idonButtonUp"/>
|  class="priority" | 1
|  class="priority" | 1
|  class="event" | onButtonUp
|  class="event" | onButtonUp

Revision as of 10:06, 11 December 2006


Basic Overview

User Interface Event Handlers are given as values in the Dialog/Control description classes.

Reference List

Priority Event Fired Notes Scope
1 onLoad Display and all controls are created, but no action on any is taken. Returns the display. Display
1 onUnload Display is closed, but no controls are destroyed yet. Returns the display and exit code. Display
1 onChildDestroyed Child display is closed. Returns the display, which child display was closed and exit code. Display
1 onMouseEnter The mouse pointer enters the control area. Returns control. Control
1 onMouseExit The mouse pointer exits the control area. Returns control. Control
2 onSetFocus Input focus is on control. It now begins to accept keyboard input. Returns control. Control
2 onKillFocus Input focus is no longer on control. It no longer accepts keyboard input. Returns control. Control
3 onTimer After amount of time given by setTimer function. Returns control. Control
2 onKeyDown Pressing any keyboard key. Fired before the onKeyUp event. Returns the control, the code of the keyboard key and the state of Shift, Ctrl and Alt. Control
2 onKeyUp Releasing any keyboard key. Fired after the onKeyDown event. Returns the control, the code of the keyboard key and the state of Shift, Ctrl and Alt. Control
2 onChar When some readable characters is recognised. Returns the control and the char code. Control
2 onIMEChar When IME character is recognized (used in Korean and other eastern languages). Returns the control and the char code. Control
2 onIMEComposition When partial IME character is recognized (used in Korean and other eastern languages). Returns the control and the char code. Control
3 onJoystickButton Pressing and releasing any joystick button. Returns the control and the the pressed button. Control
2 onMouseButtonDown Pressing a mouse button. Followed by the onMouseButtonUp event. Returns the control, the pressed button, the x and y coordinates and the state of Shift, Ctrl and Alt. Control
2 onMouseButtonUp Releasing a mouse button. Follows the onMouseButtonDown event. Returns the control, the pressed button, the x and y coordinates and the state of Shift, Ctrl and Alt. Control
2 onMouseButtonClick Pressing and releasing a mouse button. Returns the control, the pressed button, the x and y coordinates and the state of Shift, Ctrl and Alt. Control
2 onMouseButtonDblClick Pressing and releasing a mouse button twice within very short time. Returns the control, the pressed button, the x and y coordinates and the state of Shift, Ctrl and Alt. Control
2 onMouseMoving Fires continiuously while moving the mouse with a certain interval. Returns the control, the x and y coordinates and mouseOver. Control
2 onMouseHolding Fires contiuously while mouse is not moving with a certain interval. Returns the control, the x and y coordinates and mouseOver. Control
2 onMouseZChanged Fires when mouse wheel position is changed. Returns the control and the change of the scrollbar. Control
3 onCanDestroy Ask this control if dialog can be closed (used for validation of contained data). Returns the control and exit code. Control
3 onDestroy Destroying control Returns the control and exit code. Control
1 onButtonClicked The attached button action is performed. Returns control. Button
1 onButtonDown The left mouse button is pressed over the button area or a key on the keyboard is pressed. Returns control. Button
1 onButtonUp The left mouse buttons is released outside the button area and the attached button action is not performed. Returns control. Button
2 onLBSelChanged The selection in a listbox is changed. The left mouse button has been released and the new selection is fully made. Returns the control and the selected element index. Listbox
2 onLBListSelChanged Selection in XCombo box changed (but value is not stored yet). Returns the control and the selected element index. Listbox
2 onLBDblClick Double click on some row in listbox. Returns the control and the selected element index. Listbox
2 onLBDrag Drag & drop operation started. Returns the control and the selected element index. Listbox
2 onLBDragging Drag & drop operation is in progress. Returns the control and the x and y coordinates. Listbox
2 onLBDrop Drag & drop operation finished. Returns the control and the x and y coordinates. Listbox
2 onTreeSelChanged Changing the selection in a tree. Returns the control. Tree
2 onTreeDblClick Pressing and releasing twice on a tree. Returns the control. Tree
3 onTreeExpanded The tree folder structure has been expanded. Returns the control. Tree
3 onTreeCollapsed The tree folder structure has been collapsed. Returns the control. Tree
2 onToolBoxSelChanged Changed the selection in a toolbox. Returns the control and the selected element index. Toolbox
2 onCheckBoxesSelChanged Changed the selection in a checkbox. Returns the control, the selected element index and the current state. Checkbox
2 onHTMLLink Pressing and releasing a HTML link. Returns the control and href. HTML
2 onSliderPosChanged Changing the position of a slider. Returns the control and the change. Slider
2 onObjectMoved Moving an object. Returns the control and the offset on the x,y and z axes. Object
2 onMenuSelected Some item in context menu (used now only in new mission editor) was selected. Returns the control and the command id. Context menu