Browse Source

workarounds for setting volume. hopefully fixes issue #17

j8
Philipp Hancke 12 years ago
parent
commit
40af39a8dc
1 changed files with 7 additions and 2 deletions
  1. 7
    2
      app.js

+ 7
- 2
app.js View File

99
 $(document).bind('mediaready.jingle', function (event, stream) {
99
 $(document).bind('mediaready.jingle', function (event, stream) {
100
     connection.jingle.localStream = stream;
100
     connection.jingle.localStream = stream;
101
     RTC.attachMediaStream($('#localVideo'), stream);
101
     RTC.attachMediaStream($('#localVideo'), stream);
102
-    document.getElementById('localVideo').muted = true;
103
     document.getElementById('localVideo').autoplay = true;
102
     document.getElementById('localVideo').autoplay = true;
104
     document.getElementById('localVideo').volume = 0;
103
     document.getElementById('localVideo').volume = 0;
105
 
104
 
107
     updateLargeVideo(localVideoSrc, true, 0);
106
     updateLargeVideo(localVideoSrc, true, 0);
108
 
107
 
109
     $('#localVideo').click(function () {
108
     $('#localVideo').click(function () {
110
-        updateLargeVideo($(this).attr('src'), true, 1);
109
+        updateLargeVideo($(this).attr('src'), true, 0);
110
+        $('video').each(function (idx, el) {
111
+            if (el.id.indexOf('mixedmslabel') != -1) {
112
+                el.volume = 0;
113
+                el.volume = 1;
114
+            }
115
+        });
111
     });
116
     });
112
 
117
 
113
     doJoin();
118
     doJoin();

Loading…
Cancel
Save