Skip to content

Commit

Permalink
fixed space playpause
Browse files Browse the repository at this point in the history
  • Loading branch information
rafaelleru committed Nov 29, 2016
1 parent bd8ca96 commit 7ff8024
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/songsManager.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,7 @@ ipc.on('toPlay', (event, data) => {
//console.log('current Torrent in play: ' + currentTorrent.toString());
audio_tag.src = 'http://localhost:9999/' + data[0].toString();
audio_tag.title=data[0].toString();
play = true;
audio_tag.play();
audio_tag.autoplay = true;


audio_tag.onended = function(){
Expand All @@ -45,9 +44,9 @@ ipc.on('PlayPause', (event, data) => {

if(!play){
play = true;
audio.play();
audio.playPause();
} else {
play = false;
audio.pause();
audio.playPause();
}
})

0 comments on commit 7ff8024

Please sign in to comment.