Extends
Signals
ui.core.UI_SIGNALCHILD_ADDED
Broadcasted right after a chlid was added to the display list
# | Type | Description |
---|---|---|
args[0] → parent |
ui.core.DisplayObjectContainer | Parent of the display list |
args[1] → target |
ui.core.DisplayObject | The display object that just got added to the display list |
args[2] → index |
number | display object index inside the display list |
ui.core.UI_SIGNALCHILD_MOVED
Broadcasted right after a child was moved inside the display list
# | Type | Description |
---|---|---|
args[0] → parent |
ui.core.DisplayObjectContainer | Parent of the display list |
args[1] → target |
ui.core.DisplayObject | The display object that just got moved inside the display list |
args[2] → index |
number | New index inside the display list |
args[3] → oldIndex |
number | Old index inside the display list |
ui.core.UI_SIGNALCHILD_REMOVED
Broadcasted right after a child was removed from the display list
# | Type | Description |
---|---|---|
args[0] → parent |
ui.core.DisplayObjectContainer | Parent of the display list |
args[1] → target |
ui.core.DisplayObject | The display object that just got removed to the display list |
args[2] → index |
number | Index of the removed object (before removal) |
common.SIGNALRELEASING
- Inherited From:
common.SIGNALRELEASED
- Inherited From:
ui.core.UI_SIGNALFIRST_PAINT
- Inherited From:
ui.core.UI_SIGNALPAINTED
- Inherited From:
ui.core.UI_SIGNALUNPAINTED
- Inherited From:
Members
:number
countThe number of current child in this DisplayObjectContainer
:array
displayListThe DisplayObjectContainer' display list.
Methods
Add(p_displayObject, p_containeropt, p_cssClassopt, p_indexopt)
TODO
Parameters:
Name | Type | Attributes | Default | Description |
---|---|---|---|---|
p_displayObject |
ui.core.DisplayObject | |||
p_container |
* |
<optional> |
null
|
parent DOM Element |
p_cssClass |
string |
<optional> |
css class to be added to the display object upon addition |
|
p_index |
number |
<optional> |
Index inside the display list at which the item should be inserted |
Examples:
//Working with existing objects
var myDisplayObject = ... ; // Any existing DisplayObject
var myContainer = ... ; // Any existing DisplayObjectContainer
myContainer.Add(myDisplayObject);
//Working with an existing container
var myContainer = ... ; // Any existing DisplayObjectContainer
myContainer.Add(DisplayObjectConstructor, 'css-class1 css-class2');
//Working with an existing container
//and adding the child to a specific DOM element
var myContainer = ... ; // Any existing DisplayObjectContainer
var myDomElement = ... ; // Any existing DOM Element
myContainer.Add(DisplayObjectConstructor, 'css-class1 css-class2', myDomElement);
At(p_index) → {ui.core.DisplayObject|ui.core.DisplayObject}
Return the display object at the given index.
Parameters:
Name | Type | Description |
---|---|---|
p_index |
number |
Move(p_displayObject, p_index)
Move a display object inside the display list.
Parameters:
Name | Type | Description |
---|---|---|
p_displayObject |
ui.core.DisplayObject | |
p_index |
number |
Remove(p_displayObject)
Remove a display object from the display list.
Parameters:
Name | Type | Description |
---|---|---|
p_displayObject |
ui.core.DisplayObject |
RemoveAt(p_index) → {ui.core.DisplayObject}
Remove a display object at a specific index in the display list, and return that element.
Parameters:
Name | Type | Description |
---|---|---|
p_index |
number | Index to be removed |
(p_displayObject, p_index)
_OnChildAddedInternal method called when a display object has been successfully added to the display list.
Since it is reponsible for broadcasting the CHILD_ADDED signal, overriding this methods gives you control
over the order of any operations that would need to happen before or after the signal is being broadcasted.
Parameters:
Name | Type | Description |
---|---|---|
p_displayObject |
ui.core.DisplayObject | |
p_index |
number |
Examples:
_OnChildAdded(p_displayObject, p_index){
// ... Before signal broadcast
super._OnChildAdded(p_displayObject, p_index); // Will broadcast CHILD_ADDED
// ... After signal broadcast
}
(p_displayObject, p_index, p_oldIndex)
_OnChildMovedInternal method called when a display object has been successfully moved inside the display list.
Since it is reponsible for broadcasting the CHILD_MOVED signal, overriding this methods gives you control
over the order of any operations that would need to happen before or after the signal is being broadcasted.
Parameters:
Name | Type | Description |
---|---|---|
p_displayObject |
ui.core.DisplayObject | |
p_index |
number | |
p_oldIndex |
number |
Examples:
_OnChildMoved(p_displayObject, p_index, p_oldIndex){
// ... Before signal broadcast
super._OnChildMoved(p_displayObject, p_index, p_oldIndex); // Will broadcast CHILD_MOVED
// ... After signal broadcast
}
(p_displayObject, p_index)
_OnChildRemovedInternal method called when a display object has been successfully removed from the display list.
Since it is reponsible for broadcasting the CHILD_REMOVED signal, overriding this methods gives you control
over the order of any operations that would need to happen before or after the signal is being broadcasted.
Parameters:
Name | Type | Description |
---|---|---|
p_displayObject |
ui.core.DisplayObject | |
p_index |
number |
Examples:
_OnChildRemoved(p_displayObject, p_index){
// ... Before signal broadcast
super._OnChildRemoved(p_displayObject, p_index); // Will broadcast CHILD_REMOVED
// ... After signal broadcast
}
Methods
()
_Style- Inherited From:
Members
isPainted
- Inherited From:
visible :boolean
- Inherited From:
__usePaintCallback
- Inherited From:
Methods
()
_OnPaintChange- Inherited From:
()
_PostRender- Inherited From:
()
_Render- Inherited From:
Members
parent :ui.core.DisplayObjectContainer
- Inherited From:
Methods
BringToFront()
- Inherited From:
(p_oldParent)
_OnParentChanged- Inherited From:
This section list the main methods used to watch/unwatch signals on this object. For more info on signals, see signals
Methods
Unwatch(p_signal, p_fn, p_listener) → {ui.core.DisposableHTMLElement}
- Inherited From:
Watch(p_signal, p_fn, p_listener) → {ui.core.DisposableHTMLElement}
- Inherited From:
WatchOnce(p_signalId, p_fn, p_listener) → {ui.core.DisposableHTMLElement}
- Inherited From:
(p_signal, …args)
_Broadcast- Inherited From:
Members
:boolean
isReleasing- Inherited From:
Methods
()
_Wake- Inherited From:
PreventRelease()
- Inherited From:
Release()
- Inherited From:
()
_CleanUp- Inherited From:
Members
flags
- Inherited From:
host
- Inherited From:
order :number
- Inherited From:
wrapper
- Inherited From:
Methods
(p_requestType, p_fn)
_RegisterLocalRequestHandler- Inherited From:
(p_requestType, p_fn)
_UnregisterLocalRequestHandler- Inherited From: