Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(219)

Side by Side Diff: chrome/test/data/webrtc/jsep01_call.js

Issue 23172002: Landing https://codereview.chromium.org/18769010/. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /** 1 /**
2 * Copyright (c) 2012 The Chromium Authors. All rights reserved. 2 * Copyright (c) 2012 The Chromium Authors. All rights reserved.
3 * Use of this source code is governed by a BSD-style license that can be 3 * Use of this source code is governed by a BSD-style license that can be
4 * found in the LICENSE file. 4 * found in the LICENSE file.
5 */ 5 */
6 6
7 /** @private */ 7 /** @private */
8 var gTransformOutgoingSdp = function(sdp) { return sdp; }; 8 var gTransformOutgoingSdp = function(sdp) { return sdp; };
9 9
10 /** @private */ 10 /** @private */
(...skipping 206 matching lines...) Expand 10 before | Expand all | Expand 10 after
217 function() { success_('setLocalDescription'); }, 217 function() { success_('setLocalDescription'); },
218 function() { failure_('setLocalDescription'); }); 218 function() { failure_('setLocalDescription'); });
219 debug('Sending SDP message:\n' + session_description.sdp); 219 debug('Sending SDP message:\n' + session_description.sdp);
220 sendToPeer(gRemotePeerId, JSON.stringify(session_description)); 220 sendToPeer(gRemotePeerId, JSON.stringify(session_description));
221 } 221 }
222 222
223 /** @private */ 223 /** @private */
224 function addStreamCallback_(event) { 224 function addStreamCallback_(event) {
225 debug('Receiving remote stream...'); 225 debug('Receiving remote stream...');
226 var videoTag = document.getElementById('remote-view'); 226 var videoTag = document.getElementById('remote-view');
227 videoTag.src = webkitURL.createObjectURL(event.stream); 227 attachMediaStream(videoTag, event.stream);
228 228
229 // Due to crbug.com/110938 the size is 0 when onloadedmetadata fires. 229 // Due to crbug.com/110938 the size is 0 when onloadedmetadata fires.
230 // videoTag.onloadedmetadata = displayVideoSize_(videoTag); 230 // videoTag.onloadedmetadata = displayVideoSize_(videoTag);
231 // Use setTimeout as a workaround for now. 231 // Use setTimeout as a workaround for now.
232 // Displays the remote video size for both the video element and the stream. 232 // Displays the remote video size for both the video element and the stream.
233 setTimeout(function() {displayVideoSize_(videoTag);}, 500); 233 setTimeout(function() {displayVideoSize_(videoTag);}, 500);
234 } 234 }
235 235
236 /** @private */ 236 /** @private */
237 function removeStreamCallback_(event) { 237 function removeStreamCallback_(event) {
(...skipping 22 matching lines...) Expand all
260 // about the created data channel. 260 // about the created data channel.
261 onDataChannelReadyStateChange_(); 261 onDataChannelReadyStateChange_();
262 } 262 }
263 263
264 /** @private */ 264 /** @private */
265 function onDataChannelReadyStateChange_() { 265 function onDataChannelReadyStateChange_() {
266 var readyState = gDataChannel.readyState; 266 var readyState = gDataChannel.readyState;
267 debug('DataChannel state:' + readyState); 267 debug('DataChannel state:' + readyState);
268 gDataStatusCallback(readyState); 268 gDataStatusCallback(readyState);
269 } 269 }
OLDNEW
« no previous file with comments | « chrome/test/data/webrtc/getusermedia.js ('k') | chrome/test/data/webrtc/manual/constraints.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698