APIs

Show:

The Channel class is created under, and managed by, a timeline instance. So if for example a timeline has three channels, each channel would have a corresponding channel instance referenced within the timeline instance. Also, a channel creates, and holds a reference to, all the blocks that are contained within that channel, via the block_id.

Constructor

Channel

(
  • i_campaign_timeline_chanel_id
)
Object

Parameters:

  • i_campaign_timeline_chanel_id String

Returns:

Object:

Channel instantiated

Methods

_createChannelBlocks

()

Create blocks instances for all the channel's blocs (i.e.: players / resources).

Returns:

none

_listenRandomPlayback

()

Wire UI and listen to change in related UI (random playback on channel)

Returns:

none

_listenRandomPlayback

()

Wire UI and listen to change in related UI (random playback on channel)

Returns:

none

_listenReset

()

Listen to reset of when switching to different campaign so we forget current state

_listenResourceRemoving

()

Listen to when a resource removing from resources so we can remove corresponding blocks

Returns:

none

_listenSceneRemoving

()

Listen to when a scene removing from scenes so we can remove corresponding blocks

Returns:

none

_onBlocksLoaded

()

When all block modules have loaded, begin creating blocks

_onChangeRandomPlayback

(
  • e
)

On change in random playback value update msdb with new value.

Parameters:

  • e Event

Returns:

none

_onChangeRepeatToFit

(
  • e
)

On change in repeat to fit value update msdb with new value.

Parameters:

  • e Event

Returns:

none

_onTimelineChannelSelected

()

Listen to even when timeline is selected and it it's this instance's channel_id, populate properties panel.

Returns:

none

_postInit

()

After blocks loaded, continue initiliazation

_propLoadChannel

()

Update the properties panel with the state of random playback.

Returns:

none

_reset

()

Reset current state

createChannelBlock

(
  • i_campaign_timeline_chanel_player_id
  • i_playerData
)
Object

This method produces block instances which will reside on the timeline and referenced within this channel instance.

Parameters:

  • i_campaign_timeline_chanel_player_id Number
  • i_playerData XML

Returns:

Object:

reference to the block instance

deleteBlock

(
  • i_block_id
  • i_memoryOnly
)

Delete a block from the channel

Parameters:

  • i_block_id Number
  • i_memoryOnly Boolean

    if true only remove from existance but not from msdb

Returns:

none

deleteChannel

()

Delete this channel and all of it's related blocks

Returns:

none

getBlockInstance

(
  • i_campaign_timeline_chanel_player_id
)
Object

Return a block instance for the selected i_campaign_timeline_chanel_player_id (i.e.: block_id).

Parameters:

  • i_campaign_timeline_chanel_player_id Number

Returns:

Object:

reference to the block instance

getBlocks

() Object

Get all blocks that belong to this channel instance but push them into an array so they are properly sorted by player offset time.

Returns:

Object:

blocksSorted

initialize

()

Constructor

Events

CAMPAIGN_TIMELINE_CHANNEL_SELECTED

final static

Event fires when a channel is selected on a timeline. The event includes the channel id that was selected.

Event Payload:

  • caller This
  • campaign_timeline_channel_id Event