浏览代码

Updates app.bundle.js

master
paweldomas 10 年前
父节点
当前提交
8fea9b76ee
共有 2 个文件被更改,包括 51 次插入9 次删除
  1. 1
    1
      index.html
  2. 50
    8
      libs/app.bundle.js

+ 1
- 1
index.html 查看文件

@@ -22,7 +22,7 @@
22 22
     <script src="libs/popover.js?v=1"></script><!-- bootstrap tooltip lib -->
23 23
     <script src="libs/toastr.js?v=1"></script><!-- notifications lib -->
24 24
     <script src="interface_config.js?v=5"></script>
25
-    <script src="libs/app.bundle.js?v=125"></script>
25
+    <script src="libs/app.bundle.js?v=126"></script>
26 26
     <script src="analytics.js?v=1"></script><!-- google analytics plugin -->
27 27
     <link rel="stylesheet" href="css/font.css?v=7"/>
28 28
     <link rel="stylesheet" href="css/toastr.css?v=1">

+ 50
- 8
libs/app.bundle.js 查看文件

@@ -2050,7 +2050,7 @@ RTCUtils.prototype.createStream = function(stream, isVideo) {
2050 2050
 module.exports = RTCUtils;
2051 2051
 
2052 2052
 },{"../../service/RTC/Resolutions":104,"../xmpp/SDPUtil":60,"./RTCBrowserType":10,"./adapter.screenshare":12}],12:[function(require,module,exports){
2053
-/*! adapterjs - v0.11.0 - 2015-06-08 */
2053
+/*! adapterjs - custom version from - 2015-08-12 */
2054 2054
 
2055 2055
 // Adapter's interface.
2056 2056
 var AdapterJS = AdapterJS || {};
@@ -2069,7 +2069,7 @@ AdapterJS.options = AdapterJS.options || {};
2069 2069
 // AdapterJS.options.hidePluginInstallPrompt = true;
2070 2070
 
2071 2071
 // AdapterJS version
2072
-AdapterJS.VERSION = '0.11.0';
2072
+AdapterJS.VERSION = '0.11.1';
2073 2073
 
2074 2074
 // This function will be called when the WebRTC API is ready to be used
2075 2075
 // Whether it is the native implementation (Chrome, Firefox, Opera) or
@@ -2392,9 +2392,24 @@ AdapterJS.renderNotificationBar = function (text, buttonText, buttonLink, openNe
2392 2392
       try {
2393 2393
         event.cancelBubble = true;
2394 2394
       } catch(error) { }
2395
-    });
2396
-  }
2397
-  else {
2395
+
2396
+        var pluginInstallInterval = setInterval(function(){
2397
+            if(! isIE) {
2398
+              navigator.plugins.refresh(false);
2399
+            }
2400
+            AdapterJS.WebRTCPlugin.isPluginInstalled(
2401
+              AdapterJS.WebRTCPlugin.pluginInfo.prefix,
2402
+              AdapterJS.WebRTCPlugin.pluginInfo.plugName,
2403
+              function() {
2404
+                clearInterval(pluginInstallInterval);
2405
+                AdapterJS.WebRTCPlugin.defineWebRTCInterface()
2406
+              },
2407
+              function() { //Does nothing because not used here
2408
+              });
2409
+          } , 500);
2410
+    });   
2411
+
2412
+  }else {
2398 2413
     c.document.close();
2399 2414
   }
2400 2415
   AdapterJS.addEvent(c.document, 'click', function() {
@@ -2912,6 +2927,11 @@ if (navigator.mozGetUserMedia) {
2912 2927
   };
2913 2928
 
2914 2929
   AdapterJS.WebRTCPlugin.defineWebRTCInterface = function () {
2930
+    if (AdapterJS.WebRTCPlugin.pluginState ===
2931
+        AdapterJS.WebRTCPlugin.PLUGIN_STATES.READY) {
2932
+      console.error("WebRTC interface has been defined already");
2933
+      return;
2934
+    }
2915 2935
     AdapterJS.WebRTCPlugin.pluginState = AdapterJS.WebRTCPlugin.PLUGIN_STATES.INITIALIZING;
2916 2936
 
2917 2937
     AdapterJS.isDefined = function (variable) {
@@ -8174,6 +8194,20 @@ module.exports = {
8174 8194
         element.setAttribute("data-placement", position);
8175 8195
         element.setAttribute("data-html", true);
8176 8196
         element.setAttribute("data-container", "body");
8197
+    },
8198
+
8199
+    /**
8200
+     * Inserts given child element as the first one into the container.
8201
+     * @param container the container to which new child element will be added
8202
+     * @param newChild the new element that will be inserted into the container
8203
+     */
8204
+    prependChild: function (container, newChild) {
8205
+        var firstChild = container.childNodes[0];
8206
+        if (firstChild) {
8207
+            container.insertBefore(newChild, firstChild);
8208
+        } else {
8209
+            container.appendChild(newChild);
8210
+        }
8177 8211
     }
8178 8212
 };
8179 8213
 },{"../side_pannels/SidePanelToggler":22}],36:[function(require,module,exports){
@@ -9436,7 +9470,8 @@ LocalVideo.prototype.changeVideo = function (stream, isMuted) {
9436 9470
     localVideo.oncontextmenu = function () { return false; };
9437 9471
 
9438 9472
     var localVideoContainer = document.getElementById('localVideoWrapper');
9439
-    localVideoContainer.appendChild(localVideo);
9473
+    // Put the new video always in front
9474
+    UIUtil.prependChild(localVideoContainer, localVideo);
9440 9475
 
9441 9476
     var localVideoSelector = $('#' + localVideo.id);
9442 9477
 
@@ -9484,6 +9519,7 @@ var AudioLevels = require("../audio_levels/AudioLevels");
9484 9519
 var LargeVideo = require("./LargeVideo");
9485 9520
 var Avatar = require("../avatar/Avatar");
9486 9521
 var RTCBrowserType = require("../../RTC/RTCBrowserType");
9522
+var UIUtils = require("../util/UIUtil");
9487 9523
 
9488 9524
 function RemoteVideo(peerJid, VideoLayout) {
9489 9525
     this.peerJid = peerJid;
@@ -9691,7 +9727,8 @@ RemoteVideo.prototype.addRemoteStreamElement = function (sid, stream, thessrc) {
9691 9727
     var streamElement = SmallVideo.createStreamElement(sid, stream);
9692 9728
     var newElementId = streamElement.id;
9693 9729
 
9694
-    this.container.appendChild(streamElement);
9730
+    // Put new stream element always in front
9731
+    UIUtils.prependChild(this.container, streamElement);
9695 9732
 
9696 9733
     var sel = $('#' + newElementId);
9697 9734
     sel.hide();
@@ -9892,7 +9929,7 @@ RemoteVideo.createContainer = function (spanId) {
9892 9929
 
9893 9930
 
9894 9931
 module.exports = RemoteVideo;
9895
-},{"../../RTC/RTCBrowserType":10,"../audio_levels/AudioLevels":14,"../avatar/Avatar":18,"./ConnectionIndicator":36,"./LargeVideo":37,"./SmallVideo":40}],40:[function(require,module,exports){
9932
+},{"../../RTC/RTCBrowserType":10,"../audio_levels/AudioLevels":14,"../avatar/Avatar":18,"../util/UIUtil":35,"./ConnectionIndicator":36,"./LargeVideo":37,"./SmallVideo":40}],40:[function(require,module,exports){
9896 9933
 /* global $, APP, require */
9897 9934
 var Avatar = require("../avatar/Avatar");
9898 9935
 var UIUtil = require("../util/UIUtil");
@@ -15363,6 +15400,11 @@ var LocalSSRCReplacement = {
15363 15400
         if (!isEnabled)
15364 15401
             return localDescription;
15365 15402
 
15403
+        if (!localDescription) {
15404
+            console.warn("localDescription is null or undefined");
15405
+            return localDescription;
15406
+        }
15407
+
15366 15408
         // IF we have local video SSRC stored make sure it is replaced
15367 15409
         // with old SSRC
15368 15410
         if (localVideoSSRC) {

正在加载...
取消
保存