Target link for the plugin url, added comment explaining override $.FSRTC callback
This commit is contained in:
parent
43cb965f7e
commit
320cf0adb8
|
@ -8,6 +8,11 @@ body {
|
||||||
padding-top: 60px;
|
padding-top: 60px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.install {
|
||||||
|
color: white;
|
||||||
|
text-decoration: underline;
|
||||||
|
}
|
||||||
|
|
||||||
.ellipsis {
|
.ellipsis {
|
||||||
text-overflow: ellipsis;
|
text-overflow: ellipsis;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
.module('vertoControllers')
|
.module('vertoControllers')
|
||||||
.controller('InCallController', ['$rootScope', '$scope',
|
.controller('InCallController', ['$rootScope', '$scope',
|
||||||
'$http', '$location', '$modal', '$timeout', 'toastr', 'verto', 'storage', 'prompt', 'Fullscreen',
|
'$http', '$location', '$modal', '$timeout', 'toastr', 'verto', 'storage', 'prompt', 'Fullscreen',
|
||||||
function($rootScope, $scope, $http, $location, $modal, $timeout, toatr,
|
function($rootScope, $scope, $http, $location, $modal, $timeout, toastr,
|
||||||
verto, storage, prompt, Fullscreen) {
|
verto, storage, prompt, Fullscreen) {
|
||||||
|
|
||||||
console.debug('Executing InCallController.');
|
console.debug('Executing InCallController.');
|
||||||
|
@ -87,16 +87,17 @@
|
||||||
$scope.muteMic = verto.muteMic;
|
$scope.muteMic = verto.muteMic;
|
||||||
$scope.muteVideo = verto.muteVideo;
|
$scope.muteVideo = verto.muteVideo;
|
||||||
|
|
||||||
$scope.$on('ScreenShareExtensionStatus', function(error) {
|
$rootScope.$on('ScreenShareExtensionStatus', function(event, error) {
|
||||||
|
var pluginUrl = 'https://chrome.google.com/webstore/detail/screen-capturing/ajhifddimkapgcifgcodmmfdlknahffk';
|
||||||
switch(error) {
|
switch(error) {
|
||||||
case 'permission-denied':
|
case 'permission-denied':
|
||||||
toastr.info('Please allow the plugin in order to use Screen Share', 'Error'); break;
|
toastr.info('Please allow the plugin in order to use Screen Share', 'Error'); break;
|
||||||
case 'not-installed':
|
case 'not-installed':
|
||||||
toastr.warning('Please install the plugin in order to use Screen Share', 'Warning'); break;
|
toastr.warning('Please <a target="_blank" class="install" href="'+ pluginUrl +'">install</a> the plugin in order to use Screen Share', 'Warning', { allowHtml: true }); break;
|
||||||
case 'installed-disabled':
|
case 'installed-disabled':
|
||||||
toastr.info('Please enable the plugin in order to use Screen Share', 'Error'); break;
|
toastr.info('Please enable the plugin in order to use Screen Share', 'Error'); break;
|
||||||
// case 'not-chrome'
|
// case 'not-chrome'
|
||||||
// toastr.info('Please allow the plugin in order to use Screen Share', 'Error');
|
// toastr.info('Chrome', 'Error');
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -704,7 +704,7 @@ vertoService.service('verto', ['$rootScope', '$cookieStore', '$location', 'stora
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// Override onStream callback in $.FSRTC instance
|
||||||
call.rtc.options.callbacks.onStream = function(rtc, stream) {
|
call.rtc.options.callbacks.onStream = function(rtc, stream) {
|
||||||
if(stream) {
|
if(stream) {
|
||||||
var StreamTrack = stream.getVideoTracks()[0];
|
var StreamTrack = stream.getVideoTracks()[0];
|
||||||
|
@ -712,8 +712,8 @@ vertoService.service('verto', ['$rootScope', '$cookieStore', '$location', 'stora
|
||||||
// (stream.getVideoTracks()[0]).onended = stopSharing;
|
// (stream.getVideoTracks()[0]).onended = stopSharing;
|
||||||
}
|
}
|
||||||
|
|
||||||
console.log("stream started");
|
console.log("screenshare started");
|
||||||
|
|
||||||
function stopSharing() {
|
function stopSharing() {
|
||||||
if(that.data.shareCall) {
|
if(that.data.shareCall) {
|
||||||
that.screenshareHangup();
|
that.screenshareHangup();
|
||||||
|
|
Loading…
Reference in New Issue