mirror of
https://github.com/pierre42100/ComunicWeb
synced 2024-11-22 20:19:21 +00:00
Close more properly local streams.
This commit is contained in:
parent
a46a7154ea
commit
982c40788c
@ -488,6 +488,12 @@ ComunicWeb.components.calls.callWindow = {
|
|||||||
*/
|
*/
|
||||||
var interval = setInterval(function(){
|
var interval = setInterval(function(){
|
||||||
|
|
||||||
|
//Check if call is not visible anymore
|
||||||
|
if(!callContainer.isConnected){
|
||||||
|
call.close();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if(!call.open)
|
if(!call.open)
|
||||||
return clearInterval(interval);
|
return clearInterval(interval);
|
||||||
|
|
||||||
@ -811,6 +817,13 @@ ComunicWeb.components.calls.callWindow = {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//Close local stream
|
||||||
|
if(call.localStream){
|
||||||
|
call.localStream.getTracks().forEach(function(track){
|
||||||
|
track.stop();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
//Notify server
|
//Notify server
|
||||||
ComunicWeb.components.calls.interface.hangUp(call.info.id, function(){});
|
ComunicWeb.components.calls.interface.hangUp(call.info.id, function(){});
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user