FS-8401 [verto_communicator] - Added Speaker selection in settings modal and video page.

This commit is contained in:
Jaon EarlWolf
2015-11-17 15:07:00 -03:00
parent c918ec8c4f
commit c2073cb05d
10 changed files with 79 additions and 5 deletions

View File

@@ -75,6 +75,10 @@
verto.data.conf.setVideoLayout(layout);
};
$scope.confChangeSpeaker = function(speakerId) {
storage.data.selectedSpeaker = speakerId;
$rootScope.$emit('changedSpeaker', speakerId);
};
$scope.screenshare = function() {
if(verto.data.shareCall) {

View File

@@ -34,6 +34,11 @@
$rootScope.$on('config.http.success', function(ev) {
$scope.login(false);
});
$rootScope.$on('changedSpeaker', function(event, speakerId) {
attachSinkId(myVideo, speakerId);
});
/**
* Login the user to verto server and
* redirects him to dialpad page.

View File

@@ -4,8 +4,8 @@
angular
.module('vertoControllers')
.controller('ModalSettingsController', ['$scope', '$http',
'$location', '$modalInstance', 'storage', 'verto',
function($scope, $http, $location, $modalInstance, storage, verto) {
'$location', '$modalInstance', '$rootScope', 'storage', 'verto',
function($scope, $http, $location, $modalInstance, $rootScope, storage, verto) {
console.debug('Executing ModalSettingsController.');
$scope.storage = storage;
@@ -13,8 +13,12 @@
$scope.mydata = angular.copy(storage.data);
$scope.ok = function() {
if ($scope.mydata.selectedSpeaker != storage.data.selectedSpeaker) {
$rootScope.$emit('changedSpeaker', $scope.mydata.selectedSpeaker);
}
storage.changeData($scope.mydata);
verto.data.instance.iceServers(storage.data.useSTUN);
if (storage.data.autoBand) {
$scope.testSpeed();
}