List prototype
Manage graphical list.
Data fields
- SFVec2f size - Size of the list
- SFInt32 nbElements - Number of elements
- SFInt32 nbItems - Number of visible items
- SFInt32 nbMaxItems - Number of items used for transitions (should be nbItems + 1)
- SFInt32 itemHeight - Item height
- MFInt32 elementsStates - Elements states; enable>=0, disable=-1
- MFNode items - Must contain the items that will be used to display the list
- SFInt32 atElement - Element to load in the item given by the setItem field
- SFInt32 atPosition - Pixel position of the item given by the setItem field
Exposed Fields
- SFBool enable - Enable/disable SimpleList focus
- SFInt32 firstItem - Index of the element that must be associated to the first item (DEPRECATED)
Event In
- SFInt32 update - Force refresh of all displayable items and check parameters (like number of elements, their size)
- SFInt32 gotoElement - Force list to focus a given element
- SFInt32 updateElement - Update only the content of one element and refresh the corresponding displayable item
Event Out
- SFInt32 currentElement - Index of currently focused element
- SFInt32 scroll - Scrolling position in pixel, to route to the ScrollBar.moveTo (DEPRECATED)
- SFVec2f focusPos - Focus position, to route to the focus bar proto (DEPRECATED)
- SFVec2f itemsPos - Items position, to route to the Transform2D containing all the items (DEPRECATED)
- SFInt32 setItem - Next item to load, to route to a Script function handling items update
- SFTime selection - The time when an item is selected
Style
- MFString focusbarStyle - Style for the FocusBar
- MFString focusbarImages - Images for the FocusBar
- MFString scrollbarStyle - Style for the ScrollBar
- SFBool useAnimation - Use animation when scrolling (default: TRUE)
- SFBool enableCycle - Allows focus bar to jump from first to last position when using the keyboard
- SFBool topAlign - Controls vertical alignment: top or middle
Warning:
Define style is required (we can use the default style - see
Style node).
FocusBar, ScrollBar