VRFS-293. Respond to connection status changes.

This commit is contained in:
Jonathon Wilson 2013-10-12 16:35:12 -06:00
parent 6ddab3926c
commit d741d293c8
2 changed files with 16 additions and 1 deletions

View File

@ -637,6 +637,20 @@
mixerId = mixerId + "_vur";
}
_updateVU(mixerId, vuVal);
} else if (eventName === 'connection_status') {
// Connection Quality Change
var connectionClass = 'green';
if (value < 7) {
connectionClass = 'yellow';
}
if (value < 4) {
connectionClass = 'red';
}
var $connection = $('[mixer-id="' + mixerId + '_connection"]');
$connection.removeClass('green yellow red');
$connection.addClass(connectionClass);
} else if (eventName === 'add' || eventName === 'remove') {
//logger.dbg('non-vu event: ' + eventName + ',' + mixerId + ',' + value);
@ -819,6 +833,7 @@
app.bindScreen('session', screenBindings);
};
this.tracks = tracks;
this.getCurrentSession = function() {

View File

@ -166,7 +166,7 @@
<%= image_tag "content/icon_settings_lg.png", {:width => 18, :height => 18} %>
</div>
<!-- TODO - connection class from curly param -->
<div class="track-connection red">CONNECTION</div>
<div mixer-id="{mixerId}_connection" class="track-connection green">CONNECTION</div>
</div>
</script>