Home Manual Reference Source Repository
import TrackCollection from 'waves-ui-piper/src/core/track-collection.js'
public class | source

TrackCollection

Extends:

Array → TrackCollection

Collection hosting all the Track instances registered into the timeline. It provides shorcuts to trigger render / update methods on tracks or layers. Extend built-in Array

Constructor Summary

Public Constructor
public

constructor(timeline: *)

Member Summary

Public Members
public get

An array of all registered layers.

Method Summary

Public Methods
public

render()

Render all tracks and layers.

public

update(layerOrGroup: Layer | String)

Updates all tracks and layers.

public

updateLayers(layerOrGroup: Layer | String)

Updates all layers.

Public Constructors

public constructor(timeline: *) source

Params:

NameTypeAttributeDescription
timeline *

Public Members

public get layers: Array<Layer> source

An array of all registered layers.

Public Methods

public render() source

Render all tracks and layers. When done, the timeline triggers a render event.

public update(layerOrGroup: Layer | String) source

Updates all tracks and layers. When done, the timeline triggers a update event.

Params:

NameTypeAttributeDescription
layerOrGroup Layer | String

Filter the layers to update by passing the Layer instance to update or a groupId

public updateLayers(layerOrGroup: Layer | String) source

Updates all layers. When done, the timeline triggers a update:layers event.

Params:

NameTypeAttributeDescription
layerOrGroup Layer | String

Filter the layers to update by passing the Layer instance to update or a groupId