|
|
|
|
Wimpy Button Bridge - Javascript Function Reference
See the Wimpy Button Bridge Examples for additional source code.
wimpyButtonPlayPause() |
Plays the file specified in the argument. Toggles the play state between play and pause depending on the player's current state and / or if a different file is requested.
Example
<a href="javascript:;"
onClick="wimpyButtonPlayPause('example.mp3');">
Play
</a>
|
wimpyButtonPlay() |
Plays the file specified in the argument.
Example
<a href="javascript:;"
onClick="wimpyButtonPlay('example.mp3');">
Play
</a>
|
wimpyButtonPause() |
Pauses the currently loaded track.
Example
<a href="javascript:;"
onClick="wimpyButtonPause();">
Pause
</a>
|
Event Handlers
wimpyButtonTrackStarted() |
Wimpy Button pings this function every time a track is started.
Returns
A URL to the track that is being played.
Example
function wimpyButtonTrackStarted(myFile_in){
alert("Now Playing: " + myFile_in);
}
|
wimpyButtonTrackDone() |
Wimpy Button pings this function when a track has finished playing without user interaction.
Returns
A URL to the track that is being played.
Example
function wimpyButtonTrackDone(myFile_in){
// The following two lines reset the state of the player and the graphics to the "play" state
wimpyButtonState = 0;
wimpyButtonResetGrapicStates();
alert("Now Playing: " + myFile_in);
}
NOTE: This feature was included as of Wimpy Button version 4.1.4.
|
|
|
|
|