Browse Source

Does not switch to local video when we're detected as an active speaker. Comments out sample code.

j8
paweldomas 11 years ago
parent
commit
8d6e8d360b
1 changed files with 5 additions and 12 deletions
  1. 5
    12
      data_channels.js

+ 5
- 12
data_channels.js View File

12
     {
12
     {
13
         console.info("Data channel opened by the bridge !!!", dataChannel);
13
         console.info("Data channel opened by the bridge !!!", dataChannel);
14
 
14
 
15
+        // Code sample for sending string and/or binary data
15
         // Sends String message to the bridge
16
         // Sends String message to the bridge
16
-        dataChannel.send("Hello bridge!");
17
-
17
+        //dataChannel.send("Hello bridge!");
18
         // Sends 12 bytes binary message to the bridge
18
         // Sends 12 bytes binary message to the bridge
19
-        dataChannel.send(new ArrayBuffer(12));
19
+        //dataChannel.send(new ArrayBuffer(12));
20
     };
20
     };
21
 
21
 
22
     dataChannel.onerror = function (error)
22
     dataChannel.onerror = function (error)
38
 
38
 
39
             var container  = document.getElementById(
39
             var container  = document.getElementById(
40
                 'participant_' + endpointId);
40
                 'participant_' + endpointId);
41
-            // Check if local video
42
-            if (!container)
43
-            {
44
-                if (endpointId ===
45
-                        Strophe.getResourceFromJid(connection.emuc.myroomjid))
46
-                {
47
-                    container = document.getElementById('localVideoContainer');
48
-                }
49
-            }
41
+            // Local video will not have container found, but that's ok
42
+            // since we don't want to switch to local video
50
             if (container)
43
             if (container)
51
             {
44
             {
52
                 var video = container.getElementsByTagName("video");
45
                 var video = container.getElementsByTagName("video");

Loading…
Cancel
Save