Added Media.seekTo(int milliseconds);

This commit is contained in:
kernelsandirs 2011-05-04 11:51:26 -07:00
parent b94eedaf07
commit ffbc010d7b
3 changed files with 3 additions and 2 deletions

View File

@ -156,7 +156,7 @@ Media.prototype.stop = function() {
};
/**
* Seek or jump to a new time in the track.
* Seek or jump to a new time in the track..
*/
Media.prototype.seekTo = function(milliseconds) {
PhoneGap.exec(null, null, "Media", "seekToAudio", [this.id, milliseconds]);

View File

@ -186,6 +186,7 @@ public class AudioHandler extends Plugin {
/**
* Seek to a location.
*
*
* @param id The id of the audio player
* @param miliseconds int: number of milliseconds to skip 1000 = 1 second

View File

@ -238,7 +238,7 @@ public class AudioPlayer implements OnCompletionListener, OnPreparedListener, On
*/
public void seekToPlaying(int milliseconds) {
if (this.mPlayer != null) {
this.mPlayer.seekTo(milliseconds);
this.mPlayer.seekTo(milliseconds);
}
}