Class ElemGroup
Base class for elements which have an array of children.
Constructors
Name | Description |
---|---|
this
()
|
Fields
11 inherited fields
Properties
Type | Name | Description |
---|---|---|
int |
childCount [get]
|
Returns number of children of this element |
34 inherited properties
Methods
Name | Description |
---|---|
addChild
(item)
|
Add a child and return it |
child
(index)
|
Returns child by index |
childIndex
(id)
|
Returns index of element in child list, -1 if there is no child with this ID |
childIndex
(item)
|
Returns index of element in child list, -1 if passed element is not a child of this element |
diffChildren
(oldItems)
|
|
insertChild
(index, item)
|
Insert child before given index, returns inserted item |
removeAllChildren
(destroyThem)
|
Remove all children and optionally destroy them |
removeChild
(index)
|
Remove child by index, returns removed item |
removeChild
(id)
|
Remove child by ID, returns removed item |
removeChild
(child)
|
Remove child, returns removed item |
replaceChild
(oldChild, newChild)
|
Replace one child with another. It DOES NOT destroy the old item |
handleChildListChange
()
|
44 inherited methods