Dropdown#
- class UI.Dropdown()#
A control for choosing one of a list of options, which are shown when it is clicked. Added to a
UI.Canvasor aUI.Panel.Base class:UI.InputControlInherited Members
- Dropdown.getOptions()#
- Dropdown.setOptions(value)#
The options that the dropdown offers.
- Property:
Can be read or written
- Return type:
Arrayofstring
Note
Setting the options resets the selection to the first of them, or to nothing when the list is empty.
- Dropdown.getSelectedIndex()#
- Dropdown.setSelectedIndex(value)#
The position in
UI.Dropdown.getOptions()of the option that is chosen.- Property:
Can be read or written
- Return type:
number
Note
Zero while the dropdown has no options, as there is nothing to choose.