diff --git a/lib/Vroom/I18N/en.pm b/lib/Vroom/I18N/en.pm index d4d3ae9..e824901 100644 --- a/lib/Vroom/I18N/en.pm +++ b/lib/Vroom/I18N/en.pm @@ -149,6 +149,9 @@ our %Lexicon = ( "NO_WEBRTC_SUPPORT" => "Sorry, but the video conference will not work because your web browser doesn't have the " . "required functionnalities. We recommand you download one of the following browsers " . "which support the latest web technologies required to use VROOM", + "NO_WEBCAM" => "Cannot access your webcam", + "CANT_ACCESS_WEBCAM" => "We couldn't access your webcam. Please check it's connected, powered on, and that you've ". + "allowed the browser to access it, then reload this page", "HOME" => "Home", "HELP" => "Help", "ABOUT" => "About", diff --git a/lib/Vroom/I18N/fr.pm b/lib/Vroom/I18N/fr.pm index 6d29792..7e1958e 100644 --- a/lib/Vroom/I18N/fr.pm +++ b/lib/Vroom/I18N/fr.pm @@ -160,6 +160,9 @@ our %Lexicon = ( "ne dispose pas des fonctions nécessaires. Nous recommandons de télécharger " . "un des navigateurs suivants, qui supportent les dernières technologies nécessaires " . "à l'utilisation de VROOM", + "NO_WEBCAM" => "Impossible d'accéder à votre webcam", + "CANT_ACCESS_WEBCAM" => "Nous n'avons pas pu accéder à votre webcam, vérifiez qu'elle soit bien connectée, allumée, et que ". + "vous avez autorisé le navigateur à y accéder, puis raffraichissez cette page", "HOME" => "Accueil", "HELP" => "Aide", "ABOUT" => "À propos", diff --git a/public/img/webcam.png b/public/img/webcam.png new file mode 100644 index 0000000..f6195a9 Binary files /dev/null and b/public/img/webcam.png differ diff --git a/public/js/vroom.js b/public/js/vroom.js index 978c9c8..34a6b67 100644 --- a/public/js/vroom.js +++ b/public/js/vroom.js @@ -895,10 +895,16 @@ function initVroom(room) { addVideo(video,peer); }); + // We share our screen webrtc.on('localScreenAdded', function(video){ addVideo(video); }); + // error opening the webcam stream + webrtc.on('localMediaError', function(){ + $('#noWebcam').modal('show'); + }); + // Handle video stream removed: someone leaved the room // TODO: don't trigger on local screen unshare webrtc.on('videoRemoved', function(video,peer){ diff --git a/templates/default/join.html.ep b/templates/default/join.html.ep index 420211af..4eccc86 100644 --- a/templates/default/join.html.ep +++ b/templates/default/join.html.ep @@ -285,6 +285,22 @@ +