1
0
Fork 0

Don't let people pause

This commit is contained in:
Andrew Tomaka 2014-09-26 09:55:44 -04:00
parent 85847e7680
commit 43ab4c6562

View file

@ -7,11 +7,9 @@ function toggle() {
if(playing) {
sound.pause();
playing = false;
control.className = 'icon-play';
} else {
sound.play();
playing = true;
control.className = 'icon-pause';
}
}
@ -24,7 +22,10 @@ function makeItPlay() {
sound = new Howl({
urls: ['assets/audio/africa.ogg', 'assets/audio/africa.m4a'],
autoplay: true,
loop: true
loop: true,
onplay: function() {
control.style.visibility = 'hidden';
}
});
setTimeout(enableToggle, 2500);
}