ComboBoxListBox¶
Under Construction
This documentation is auto-generated, and is a work in progress. Please see the source code at https://github.com/phetsims/sun/blob/main/js/ComboBoxListBox.ts for the most up-to-date information.
Overview¶
The popup list box for a ComboBox.
@author Chris Malley (PixelZoom, Inc.)
Class ComboBoxListBox¶
Constructor¶
new ComboBoxListBox( property : TProperty<T>, items : ComboBoxItemNoNode<T>[], nodes : Node[], hideListBoxCallback : () => void, focusButtonCallback : () => void, voiceOnSelectionNode : VoicingNode, tandem : Tandem, providedOptions? : ComboBoxListBoxOptions )¶
Instance Methods¶
dispose()¶
setItemVisible( value : T, visible : boolean )¶
Sets the visibility of one or more items in the listbox that correspond to a value. Assumes that each item in the listbox has a unique value. @param value - the value associated with the ComboBoxItem @param visible
isItemVisible( value : T ) : boolean¶
Is the item that corresponds to a value visible when the listbox is popped up? @param value - the value associated with the ComboBoxItem
focusListItemNode( value : T )¶
Focuses the ComboBoxListItemNode that corresponds to a specified value. If the item for that value is not visible, focus is placed on the first visible item.
Type ComboBoxListBoxOptions¶
- highlightFill?: TPaint
fill for the highlight behind items in the list - comboBoxListItemNodeOptions?: ComboBoxListItemNodeOptions
Options that apply to every ComboBoxItemNode created in the list - openedSoundPlayer?: TSoundPlayer
Sound generators for when combo box is opened and when it is closed with no change. Closing with a change is covered by individual combo box items. - closedNoChangeSoundPlayer?: TSoundPlayer
- & PanelOptions
Source Code¶
See the source for ComboBoxListBox.ts in the sun repository.