How does ended event works in web audio api?[Solved] | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 2

How does ended event works in web audio api?[Solved]

So i have this handler function for ended event on source for stoping the audio context current time but it creates a problem when you wanna play ,pause and play again ,if you comment it out everything works fine but then there is a problem of currentTime being recorded even after the music ends ,anyone know how can I solve it ?Ty in advance! https://code.sololearn.com/Wo47bGQuQEgZ/?ref=app

8th Sep 2020, 1:07 PM
Abhay
Abhay - avatar
6 Answers
+ 2
#MRX yes ,do you know about me ? What you really meant by seriously ?I just asked a question after hours of struggling with understanding how ended event works ,from what I learned it is called when source stops playing or when source.stop() is called but when i call source.stop() it didn't seemed to work at all , And what's with all the liking your own comments and disliking my comment ? additionaly i am interested to know why people like their own comments :)
9th Sep 2020, 7:43 PM
Abhay
Abhay - avatar
+ 1
Did you used Google to search?
9th Sep 2020, 7:25 PM
AlienX
AlienX - avatar
+ 1
Seriously??)
9th Sep 2020, 7:38 PM
AlienX
AlienX - avatar
+ 1
i like your comments😂😂😂, because they don't mean anything))
9th Sep 2020, 7:49 PM
AlienX
AlienX - avatar
0
#MRX obviously ,I do extensive search using Google before asking any question ,also things aren't very clear enough given the less tutorials on ended event and even the ones on mdn aren't that useful or makes sense when it comes to the way I am trying to implement ,if you can check the code you will understand what problem i am facing
9th Sep 2020, 7:33 PM
Abhay
Abhay - avatar
0
sorry for your problems)
9th Sep 2020, 7:51 PM
AlienX
AlienX - avatar