I'm working on a video call web application.
Every time the user is on a mobile device (iPhone or Android) and gets a phone call, the video call sound gets damage.
I've tried the tabfocus
event but not every smartphone "unfocus" during a phone call. Some of them just show a pop up, for example.
document.visibilityState
didn't work either.
I'm searching for a way to know about or fully block the phone call.
Thanks for the help!
Have you tried to listen for BaseAudioContext.onstatechange? I believe, during the call BaseAudioContext.state will be changed from running
to suspended
or closed
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With