Component/SelectButton
Namespace
components.selectButton
Constants
The form module.
Source: lib/modules/components/selectButton.whl, line: 8
| MODULE_COMPONENT_SELECT_BUTTON | 66 |
Module calls for button component functions.
Source: lib/modules/components/selectButton.whl, line: 11
SELECT_BUTTON_COMPONENT_SET_HIDDEN | 0 |
SELECT_BUTTON_COMPONENT_SET_DISABLED | 1 |
SELECT_BUTTON_COMPONENT_SET_X | 2 |
SELECT_BUTTON_COMPONENT_SET_Y | 3 |
SELECT_BUTTON_COMPONENT_SET_COLOR | 4 |
SELECT_BUTTON_COMPONENT_SET_ACTIVE | 5 |
SELECT_BUTTON_COMPONENT_GET_ACTIVE | 6 |
Properties
These properties can be edited with the property editor in the IDE.
Name | Type | Description |
name | string | The component name. |
hidden | boolean | Hide the component. |
disabled | boolean | Disable the component. |
x | number | The left position of the component inside the parent component. |
y | number | The top position of the component inside the parent component. |
zIndex | number | The depth of the component related to other components in the parent. |
color | color | The color of the buttons, available colors are: gray, yellow, green, blue or red. |
options | string | A list of button titles. |
Events
onChange
Called when an other button is selected.
proc onChange(number windowHandle, number value)
Parameters:
Name | Type | Description |
windowHandle | number | The handle of the parent window of the selectButton. |
value | number | Index of the selected button, the index of the first button is 0, the second is 1, etc.. |
onFocus
Called when the selectButton is focussed.
proc onFocus(number windowHandle)
Parameters:
Name | Type | Description |
windowHandle | number | The handle of the parent window of the selectButton. |
onBlur
Called when the selectButton looses focus.
proc onBlur(number windowHandle)
Parameters:
Name | Type | Description |
windowHandle | number | The handle of the parent window of the selectButton. |
Procedures
setHidden
Source: lib/modules/components/selectButton.whl, line: 40
Hide the select button.
proc setHidden(number windowHandle, number componentHandle, number hidden)
Parameters:
Name | Type | Description |
windowHandle | number | The handle of the window. |
componentHandle | number | The handle of the component. |
hidden | number | Hidden TRUE or FALSE. |
setDisabled
Source: lib/modules/components/selectButton.whl, line: 49
Disable the select button.
proc setDisabled(number windowHandle, number componentHandle, number disabled)
Parameters:
Name | Type | Description |
windowHandle | number | The handle of the window. |
componentHandle | number | The handle of the component. |
disabled | number | Disabled TRUE or FALSE. |
setX
Source: lib/modules/components/selectButton.whl, line: 58
Set the x position of the select button.
proc setX(number windowHandle, number componentHandle, number x)
Parameters:
Name | Type | Description |
windowHandle | number | The handle of the window. |
componentHandle | number | The handle of the component. |
x | number | The x position in pixels. |
setY
Source: lib/modules/components/selectButton.whl, line: 67
Set the y position of the select button.
proc setY(number windowHandle, number componentHandle, number y)
Parameters:
Name | Type | Description |
windowHandle | number | The handle of the window. |
componentHandle | number | The handle of the component. |
y | number | The y position in pixels. |
setColor
Source: lib/modules/components/selectButton.whl, line: 76
Set the select button color.
proc setColor(number windowHandle, number componentHandle, number color)
Parameters:
Name | Type | Description |
windowHandle | number | The handle of the window. |
componentHandle | number | The handle of the component. |
color | number | The button color. |
setActive
Source: lib/modules/components/selectButton.whl, line: 85
Set the active button.
proc setActive(number windowHandle, number componentHandle, number active)
Parameters:
Name | Type | Description |
windowHandle | number | The handle of the window. |
componentHandle | number | The handle of the component. |
active | number | The active button. |
getActive
Source: lib/modules/components/selectButton.whl, line: 94
Get the active button.
proc getActive(number windowHandle, number componentHandle)
Parameters:
Name | Type | Description |
windowHandle | number | The handle of the window. |
componentHandle | number | The handle of the component. |
Return: The active button.