From 8286e77155dd1ea21272de3b17d38059622afc34 Mon Sep 17 00:00:00 2001 From: Daniel Berteaud Date: Wed, 21 May 2014 19:34:16 +0200 Subject: [PATCH] Chage owner's action buttons depending on the actual status --- public/css/vroom.css | 3 --- public/js/vroom.js | 4 ++++ 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/public/css/vroom.css b/public/css/vroom.css index 0f7c7ce..46a0ecc 100644 --- a/public/css/vroom.css +++ b/public/css/vroom.css @@ -111,17 +111,14 @@ } .actionMute:before{ font-family: 'Glyphicons Halflings'; - color: red; content: "\e036"; } .actionPause:before{ font-family: 'Glyphicons Halflings'; - color: red; content: "\e106"; } .actionKick:before{ font-family: 'Glyphicons Halflings'; - color: red; content: "\e083"; } #emailNotificationList { diff --git a/public/js/vroom.js b/public/js/vroom.js index 71a5ab0..3a506d9 100644 --- a/public/js/vroom.js +++ b/public/js/vroom.js @@ -712,11 +712,13 @@ function initVroom(room) { var div = 'mute_' + data.id, cl = 'muted'; peers[data.id].micMuted = true; + $('#actionMute_' + data.id).addClass('btn-danger'); } else if (data.name === 'video'){ var div = 'pause_' + data.id, cl = 'paused'; peers[data.id].videoPaused = true; + $('#actionPause_' + data.id).addClass('btn-danger'); } else{ return; @@ -729,10 +731,12 @@ function initVroom(room) { if (data.name === 'audio'){ var el = '#mute_' + data.id; peers[data.id].micMuted = false; + $('#actionMute_' + data.id).removeClass('btn-danger'); } else if (data.name === 'video'){ var el = '#pause_' + data.id; peers[data.id].videoPaused = false; + $('#actionPause_' + data.id).removeClass('btn-danger'); } else{ return;