1
Fork 0
mirror of https://github.com/jech/galene.git synced 2024-12-22 23:35:46 +01:00

Add warning about screen sharing under Safari.

This commit is contained in:
Juliusz Chroboczek 2020-10-31 22:31:14 +01:00
parent 2efb5b3cea
commit 96c3e4f830

View file

@ -818,6 +818,8 @@ async function addLocalMedia(id) {
setButtonsVisibility();
}
let safariWarningDone = false;
async function addShareMedia() {
if(!getUserPass())
return;
@ -835,6 +837,15 @@ async function addShareMedia() {
return;
}
if(!safariWarningDone) {
let ua = navigator.userAgent.toLowerCase();
if(ua.indexOf('safari') >= 0 && ua.indexOf('chrome') < 0) {
displayWarning('Screen sharing under Safari is experimental. ' +
'Please use a different browser if possible.');
}
safariWarningDone = true;
}
let c = newUpStream();
c.kind = 'screenshare';
c.stream = stream;