@@ -80,6 +80,7 @@ var WebAudioSound = new Class({
8080 if ( ! BaseSound . prototype . play . call ( this , markerName , config ) ) {
8181 return null ;
8282 }
83+ // \/\/\/ isPlaying = true, isPaused = false \/\/\/
8384 this . stopAndRemoveBufferSource ( ) ;
8485 var seek = this . currentConfig . seek ;
8586 var offset = ( this . currentMarker ? this . currentMarker . start : 0 ) + seek ;
@@ -93,6 +94,7 @@ var WebAudioSound = new Class({
9394 if ( ! BaseSound . prototype . pause . call ( this ) ) {
9495 return false ;
9596 }
97+ // \/\/\/ isPlaying = false, isPaused = true \/\/\/
9698 this . stopAndRemoveBufferSource ( ) ;
9799 this . pausedTime = this . seek ;
98100 return true ;
@@ -101,6 +103,7 @@ var WebAudioSound = new Class({
101103 if ( ! BaseSound . prototype . resume . call ( this ) ) {
102104 return false ;
103105 }
106+ // \/\/\/ isPlaying = true, isPaused = false \/\/\/
104107 // TODO take in account playback rate
105108 var offset = ( this . currentMarker ? this . currentMarker . start : 0 ) + this . pausedTime ;
106109 var duration = this . duration - this . pausedTime ;
@@ -113,6 +116,7 @@ var WebAudioSound = new Class({
113116 if ( ! BaseSound . prototype . stop . call ( this ) ) {
114117 return false ;
115118 }
119+ // \/\/\/ isPlaying = false, isPaused = false \/\/\/
116120 this . stopAndRemoveBufferSource ( ) ;
117121 this . startTime = 0 ;
118122 this . pausedTime = 0 ;
0 commit comments