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

Unified Diff: test/data/webrtc/manual/constraints.js

Issue 12824011: Updated Chrome Test pages (Closed) Base URL: https://src.chromium.org/svn/trunk/src/chrome/test/data/webrtc/
Patch Set: Created 7 years, 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « test/data/webrtc/manual/constraints.html ('k') | test/data/webrtc/manual/peerconnection.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/data/webrtc/manual/constraints.js
===================================================================
--- test/data/webrtc/manual/constraints.js (revision 191906)
+++ test/data/webrtc/manual/constraints.js (working copy)
@@ -12,18 +12,18 @@
/**
* Asks permission to use the webcam and mic from the browser.
*/
-function getUserMedia() {
+function doGetUserMedia() {
+ // Call into getUserMedia via the polyfill (adapter.js).
var constraints = getConstraints_();
var constraintsString = JSON.stringify(constraints, null, ' ');
$('getusermedia-constraints').innerHTML = constraintsString;
- if (!navigator.webkitGetUserMedia) {
+ if (!getUserMedia) {
log_('Browser does not support WebRTC.');
return;
}
log_('Requesting getUserMedia with constraints: ' + constraintsString);
- navigator.webkitGetUserMedia(constraints,
- getUserMediaOkCallback_,
- getUserMediaFailedCallback_);
+ getUserMedia(constraints, getUserMediaOkCallback_,
phoglund_chromium 2013/04/09 08:08:17 Nit: indent
+ getUserMediaFailedCallback_);
}
// Internals
@@ -104,7 +104,7 @@
function getUserMediaOkCallback_(stream) {
gLocalStream = stream;
var videoTag = $('local-view');
- videoTag.src = webkitURL.createObjectURL(stream);
+ attachMediaStream(videoTag, stream);
// Due to crbug.com/110938 the size is 0 when onloadedmetadata fires.
// videoTag.onloadedmetadata = updateVideoTagSize_(videoTag);
« no previous file with comments | « test/data/webrtc/manual/constraints.html ('k') | test/data/webrtc/manual/peerconnection.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698