Skip to content

Commit 4d95cac

Browse files
Stopping and removing loop buffer source when setting loop property to false
1 parent b9ec8f2 commit 4d95cac

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

v3/src/sound/webaudio/WebAudioSound.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -391,6 +391,9 @@ Object.defineProperty(WebAudioSound.prototype, 'loop', {
391391
if (value) {
392392
this.createAndStartLoopBufferSource();
393393
}
394+
else {
395+
this.stopAndRemoveLoopBufferSource();
396+
}
394397
}
395398
}
396399
});

0 commit comments

Comments
 (0)