Browse Source

Detect full screen exit properly and use :fullscreen style instead of custom class to get black background.

pull/198/head
Simon Eisenmann 11 years ago
parent
commit
9c8a2af107
  1. 1
      src/styles/components/_audiovideo.scss
  2. 4
      src/styles/global/_base.scss
  3. 2
      static/css/main.min.css
  4. 9
      static/js/directives/audiovideo.js

1
src/styles/components/_audiovideo.scss

@ -34,7 +34,6 @@
} }
&.fullscreen { &.fullscreen {
background: #000 !important;
bottom: 0 !important; bottom: 0 !important;
left: 0 !important; left: 0 !important;
right: 0 !important; right: 0 !important;

4
src/styles/global/_base.scss

@ -65,3 +65,7 @@ a {
.desktopnotify-icon { .desktopnotify-icon {
background-image: url('../img/logo-48x48.png'); background-image: url('../img/logo-48x48.png');
} }
:fullscreen {
background: #000;
}

2
static/css/main.min.css vendored

File diff suppressed because one or more lines are too long

9
static/js/directives/audiovideo.js

@ -216,8 +216,13 @@ define(['jquery', 'underscore', 'text!partials/audiovideo.html', 'text!partials/
$scope.toggleFullscreen = function() { $scope.toggleFullscreen = function() {
//console.log("Toggle full screen", BigScreen.enabled, $scope.isActive, $scope.hasUsermedia); //console.log("Toggle full screen", BigScreen.enabled, $scope.isActive, $scope.hasUsermedia);
if (BigScreen.enabled && ($scope.isActive || $scope.hasUsermedia)) { if (BigScreen.enabled && ($scope.isActive || $scope.hasUsermedia)) {
$scope.layoutparent.toggleClass("fullscreen"); BigScreen.toggle($scope.layoutparent[0], function() {
BigScreen.toggle($scope.layoutparent[0]); // onEnter
$scope.layoutparent.addClass("fullscreen");
}, function() {
// onExit
$scope.layoutparent.removeClass("fullscreen");
});
} }
}; };

Loading…
Cancel
Save