initialize()
function initialize( _dashBase:*, _dashService:*, _dashResizer:*, _dashUtils:*, _dashLayout:*, _flashVars:*, _dashInterface:* ) : Boolean
Function to initialize your skin.
- Parameters:
dashBase | - The Dash Media Player Base class. |
dashService | - The Dash Media Player Service class. (for calling services to Drupal and others). |
dashResizer | - The Dash Media Player Resizer class (for resizing objects) |
dashUtils | - The Dash Media Player Utils class. (common utilities used throughout the player). |
dashLayout | - The Dash Media Player Layout Manager. (to store all information from the layout XML file) |
flashVars | - The Flash Variables Object (for handling all flashvars). |
dashInterface | - The Dash Media Player Interface class (for loading nodes, playlists, and handling media). |
- Returns:
- True to indicate to the media player to start loading content.
False to let the skin take over from here and do what it needs to do.
getConfigInfo()
function getConfigInfo() : XML
Allows you to provide all your information within your skin file so that you do not have to expose the configuration XML
file to outside parties. You can also associate certain FlashVariables with your skin by using the "flashvars" section of
the XML configuration. Each of these tags are described as follows. For more information, go to
http://www.tmtdigital.com/node/143
| Element | Description |
| license | This is where you will place your license if you purchase a license for commercial use. |
| gateway | This is the URL to your Drupal Services Gateway. |
| apiKey | This is the Services API Key to provide a secure connection between the player and your Drupal site |
| baseURL | This is the Base URL of your domain name. For this site, this value is http://www.tmtdigital.com |
| flashvars | Allows you to pre-define flash variables so that they are not required when you embed the player in your page. For example, if you wish to have all your players autostart the media, then you can provide a <autostart>true</autostart> tag within this flashvars tag. |
- Returns:
- Your XML configuration, as it would be in the dashconfig.xml file.
getLayoutInfo()
function getLayoutInfo() : XML
Returns the layout information of this skin as an XML structure. This is used to define the resize properties used for each
element within the skin. Each element within the XML structure is defined as follows. For more information, go to
http://www.tmtdigital.com/node/140.
| Element | Description |
| width | This is the original with of your skin (before it gets resized) |
| height | This is the original height of your skin (before it gets resized) |
| autohideX | This is the minimum width that your skin can be before the playlist is hidden automatically. |
| autohideY | This is the minimum height that your skin can be before the information box is hidden automatically. |
| spacer | This is the space between the Playlist and your Main Node. |
| linkpadding | This is the space on either side of the text within a playlist link to be used as padding. |
| resize | There can be an unlimited number of these tags in your layout. Basically what this tag indicates is a resizable object property when your skin is resized. If you wish to have an object in your skin float right with a resize of the player, then you would provide the path to that object and then the x property as the value that will move with the size of the player. If you wish for that object to float right and also float to the bottom during a resize event, then you will need to provide two different resize tags where one provides the x property, and the other provides the y property of your object. You can also set the "width" and "height" properties if you wish for the object to resize with the player. |
- Returns:
- The XML layout information.
serviceCall()
function serviceCall( message:Object ) : Boolean
This function is a hook which can be used to control each and every service call that is made from within
the player. Before the player makes any calls to the server, it will first pass the message that will be
sent to this function to allow the skin to modify the message being sent to the player. This will allow
the skin to make any changes necessary to the message (such as changing the service command), as well as
add any arguments to the message.
- Parameters:
message | - The message object. Each message object contains the following...
command - This is a command that is getting sent to the skin. The following is a list of all commands...
- System.SYSTEM_CONNECT - Called when the player connects to Drupal.
- System.SYSTEM_MAIL - Called when an email message is sent from the player.
- System.NODE_LOAD -Called when the player makes a call to load a node.
- System.GET_VERSION - Called when the player queries Drupal for the version #
- System.GET_VIEW - Called when the player queries for the Drupal view (playlist)
- System.GET_VOTE - Called when the player queries to get a vote.
- System.SET_VOTE - Called when the player queries to set a vote.
- System.GET_USER_VOTE - Called when the player queries to get a user vote.
- System.DELETE_VOTE - Called when the player deletes a vote.
- System.ADD_TAG - Called when the player adds a new taxonomy tag to a node.
- System.INCREMENT_NODE_COUNTER - Called when the player increments the node counter.
- System.SET_FAVORITE - Called when the player sets a new favorite node.
- System.DELETE_FAVORITE - Called when the player deletes a favorite.
- System.IS_FAVORITE - Called when the player queries to see if this node is a favorite.
- System.USER_LOGIN - Called when the player logs the user into the Drupal system.
- System.USER_LOGOUT - Called when the player logs the user out.
- System.SET_USER_STATUS - Called when the player sets the user status.
onSuccess - The callback that is called when a successful call has been made.
onFailed - The callback that is called when an error occurs.
args - An array of all the arguments for this view.
|
- Returns:
- You can use the return of this function to tell the player to make the call or not.
If you do not want the player to make any call to the server, then you would simply
provide false for the return value, true otherwise.
onResize()
function onResize() : void
Hook that gets called when the player resizes.
function getMedia( mediaFile:Object )
When your media type is "custom", the dash media player will then call this routine to grab a media handling
class. This can be anything class to handle any type of media like SWF files, ect.
For an example stub class to be used to build your own, refer to the SWFMedia.as file.
- Parameters:
mediaFile | - The media file object to play. This object contains the following...
- path - The full path of the media file.
- filename - The filename of the media file.
- extension - The file extension...
- mediatype - The media type...
- mediaclass - This will always be "media" here...
- weight - The weight of this media.
|
- Returns:
- Your custom media class
function onMediaPlaying()
Called when the media starts playing...
function onMediaComplete()
Called when the media finishes playing...
getTeaser()
function getTeaser() : MovieClip
Hook that allows you to return a MovieClip of your teaser.
- Returns:
- A new movie clip of your teaser.
onTeaserInit()
function onTeaserInit( teaser:* )
Called when the teaser gets initialized.
- Parameters:
teaser | - The teaser object. |
onTeaserSelect()
function onTeaserSelect( teaser:*, select:Boolean )
Called when the teaser gets selected.
- Parameters:
teaser | - The teaser object. |
select | - If the teaser has been selected or not |
onTeaserOver()
function onTeaserOver( teaser:* )
Called when the mouse hovers over a teaser
- Parameters:
teaser | - The teaser object. |
onTeaserOut()
function onTeaserOut( teaser:* )
Called when the mouse moves out of hovering over a teaser.
- Parameters:
teaser | - The teaser object. |
onTeaserDown()
function onTeaserDown( teaser:* )
Called when the user presses the down button on the teaser.
- Parameters:
teaser | - The teaser object. |
getPlaylistLink()
function getPlaylistLink() : MovieClip
Hook that allows you to return a MovieClip of a playlist link.
- Returns:
- A new movie clip of your playlist link.
getTermLink()
function getTermLink() : MovieClip
Hook that allows you to return a MovieClip of a term link.
- Returns:
- A new movie clip of your term link.
onNodeLoad()
function onNodeLoad( node:Object )
Hook that gets called when a node loads in the system
- Parameters:
node | - A standard Drupal node object. |
onPlaylistLoad()
function onPlaylistLoad( playlist:Object )
Hook that gets called when a node loads in the system
- Parameters:
playlist | - A standard Drupal view object. |
onFullScreenMove()
function onFullScreenMove( mouseX:Number, mouseY:Number )
Hook when the mouse is moved when the player is in full screen mode.
- Parameters:
mouseX | - The x-position of the mouse. |
mouseY | - The y-position of the mouse. |
onFullScreenHide()
function onFullScreenHide()
Hook when the inactive timout occurs when in full screen mode. Typically you should
hide everything at this point.
onFullScreen()
function onFullScreen( full:Boolean )
Hook when the player goes in and out of full screen.
- Parameters:
full | - To determine if we are in fullscreen mode or not...
true - Fullscreen
false - Normal |
getTweenFunction()
function getTweenFunction() : Function
Ability to change how the resizer tweens its resize transitions.
function toggleMenuMode( on:Boolean, tween:Boolean )
Called when the toggle menu mode button gets pressed.
- Parameters:
on | - Boolean to let us know if the Menu should be on or off...
true - menu is on.
false - menu is off.
|
tween | - Let us know if this movement should be tweened or not. |
function onMenuFinish(event:TweenEvent)
Called when the menu has finished moving off the screen. Here we will just hide the menu when
it is not in use.
- Parameters:
event | - A standard tween event. |
function showMinMaxButton( show:Boolean )
Called to hide or show the Min/Max button.
- Parameters:
show | - Determine if we should show or hide the minMaxButton.
true - Show the min/max button.
false - Hide the min/max button. |
function showMenuButton( show:Boolean )
Called to hide or show the Menu button.
- Parameters:
show | - Determine if we should hide or show the menuButton.
true - Show the menu button.
false - Hide the menu button. |
showInfo()
function showInfo( show:Boolean, tween:Boolean, refresh:Boolean )
Called to hide or show the media player information section.
- Parameters:
show | - Determine if we should hide or show the Info section.
true - Show the information.
false - Hide the information. |
tween | - Boolean to indicate if this transition should be tweened or not. |
refresh | - Boolean to indicate if there should be a full screen refresh after the transition. |
showControls()
function showControls( show:Boolean, tween:Boolean )
Called to hide or show the media player controls.
- Parameters:
show | - Determine if we should hide or show the controls.
true - Show the controls.
false - Hide the controls.
|
tween | - Boolean to indicate if this transition should be tweened or not. |
maximize()
function maximize( max:Boolean, tween:Boolean = true )
Called to maximize/minimize the player (show or hide the playlist).
- Parameters:
max | - Boolean to determine if we should maximize the player or not.
true - Maximize (hide the playlist).
false - Minimize (show the playlist). |
tween | - Boolean to indicate if this transition should be tweened or not. |
getEmbedCode()
function getEmbedCode( loaderURL:String, mediaFile:String, imageFile:String, embedVars:Array )
Allow the skin to provide their own embed code.
- Parameters:
loaderURL | - The URL of the player SWF file. |
mediaFile | - The path to the media file to embed. |
imageFile | - The image provided with the media file to embed. |
embedVars | - An array of extra flashVars. |
setPlaylistSize()
function setPlaylistSize( playlistSize:Number )
Called to set the width or height of the playlist.
- Parameters:
playlistSize | - The size (in pixels) that you would like to set the playlist. |
function formatTime(mediaTime:Number) : Object
Hook to allow your to format the time indication however you would like it to be formated.
- Parameters:
mediaTime | - The time in seconds. |
- Returns:
- An object that represents both the units and the time as Strings.
showPlaylistLinks()
function showPlaylistLinks()
Called to show the dynamic links for the playlist.
setNavBar()
function setNavBar( nextVisible:Boolean, prevVisible:Boolean )
Automatically places the previous and next buttons depending of whether there is a previous or next playlist.
- Parameters:
nextVisible | - A boolean to indicate if there should be a next button for the playlist. |
prevVisible | - A boolean to indicate if there should be a previous button for the playlist. |
setLogoPos()
function setLogoPos( addObject:Boolean )
Allows you to set the logo position. You must have a valid license for this function to get called...
- Parameters:
addObject | - A boolean that will indicate if the logo needs to be added as a dynamic property to the resizer. |