no longer a stub :D |
989onan bot (talk | contribs) Automated: update SyncDelegates |
||
Line 10: | Line 10: | ||
|_targetList|ISyncList|The list to edit. | |_targetList|ISyncList|The list to edit. | ||
|_addNewButton|'''[[Component:Button|Button]]'''|TypeAdv1=true|Button to add a new item to the list. | |_addNewButton|'''[[Component:Button|Button]]'''|TypeAdv1=true|Button to add a new item to the list. | ||
}} | |||
== Sync Delegates == | |||
{{Table ComponentTriggers | |||
|AddNewPressed[[Type:ButtonEventHandler|ButtonEventHandler]]|[[Type:ButtonEventHandler|ButtonEventHandler]]|true| | |||
|MoveUpPressed[[Type:ButtonEventHandler|ButtonEventHandler]]|[[Type:ButtonEventHandler|ButtonEventHandler]]|true| | |||
|MoveDownPressed[[Type:ButtonEventHandler|ButtonEventHandler]]|[[Type:ButtonEventHandler|ButtonEventHandler]]|true| | |||
|RemovePressed[[Type:ButtonEventHandler|ButtonEventHandler]]|[[Type:ButtonEventHandler|ButtonEventHandler]]|true| | |||
}} | }} | ||
Revision as of 06:03, 17 March 2025

The ListEditor component is a internal-use component intended to be used to generate UIX for editing an ISyncList.
Fields
Name | Type | Description |
---|---|---|
persistent
|
Bool | Determines whether or not this item will be saved to the server. |
UpdateOrder
|
Int | Controls the order in which this component is updated. |
Enabled
|
Bool | Controls whether or not this component is enabled. Some components stop their functionality when this field is disabled, but some don't. |
_targetList
|
ISyncList | The list to edit. |
_addNewButton
|
Button | Button to add a new item to the list. |
Sync Delegates
Method Name | Method type and Arguments. | Is the method hidden? | Description |
---|---|---|---|
AddNewPressedButtonEventHandler
|
ButtonEventHandler | ✓ | |
MoveUpPressedButtonEventHandler
|
ButtonEventHandler | ✓ | |
MoveDownPressedButtonEventHandler
|
ButtonEventHandler | ✓ | |
RemovePressedButtonEventHandler
|
ButtonEventHandler | ✓ |
Usage
When _targetList
receives a reference to a list, the ListEditor's slot's children will be populated with items in the list. Each of these child slots will have the name Element
. Each slot contains a HorizontalLayout component and RectTransform component.
This component will misbehave when changing the _targetList
after it already has a reference, as doing so is unintended behavior.
This component is much less useful than its cousin, BagEditor, as it does not expose any method to reference the list members from in-game. FrooxEngine uses internal code to add references on child slots of the elements when building the Scene Inspector UI.