Bug 942343: pref off RTCPeerConnection for B2G until it's functional r=ekr,smaug,jsmith

This commit is contained in:
Randell Jesup 2013-11-24 19:46:39 -05:00
parent 6a122228c4
commit bb4b8e953e
3 changed files with 47 additions and 40 deletions

View File

@ -6,41 +6,42 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=872377
<head> <head>
<meta charset="utf-8"> <meta charset="utf-8">
<title>Test for Bug 872377 and Bug 928304</title> <title>Test for Bug 872377 and Bug 928304</title>
<script type="application/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
<link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css"/> <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css"/>
<script type="application/javascript"> <script type="application/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
<script type="application/javascript" src="head.js"></script>
/** Test for Bug 872377 **/
var rtcSession = new mozRTCSessionDescription({ sdp: "Picklechips!",
type: "offer" });
var jsonCopy = JSON.parse(JSON.stringify(rtcSession));
for (key in rtcSession) {
if (typeof(rtcSession[key]) == "function") continue;
is(rtcSession[key], jsonCopy[key], "key " + key + " should match.");
}
/** Test for Bug 928304 **/
var rtcIceCandidate = new mozRTCIceCandidate({ candidate: "dummy",
sdpMid: "test",
sdpMLineIndex: 3 });
jsonCopy = JSON.parse(JSON.stringify(rtcIceCandidate));
for (key in rtcIceCandidate) {
if (typeof(rtcIceCandidate[key]) == "function") continue;
is(rtcIceCandidate[key], jsonCopy[key], "key " + key + " should match.");
}
</script>
</head> </head>
<body> <body>
<a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=872377">Mozilla Bug 872377</a>
<a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=928304">Mozilla Bug 928304</a>
<p id="display"></p>
<div id="content" style="display: none">
</div>
<pre id="test"> <pre id="test">
<script type="application/javascript">
createHTML({
bug: "928304",
title: "test toJSON() on mozRTCSessionDescription and mozRTCIceCandidate"
});
runTest(function () {
/** Test for Bug 872377 **/
var rtcSession = new mozRTCSessionDescription({ sdp: "Picklechips!",
type: "offer" });
var jsonCopy = JSON.parse(JSON.stringify(rtcSession));
for (key in rtcSession) {
if (typeof(rtcSession[key]) == "function") continue;
is(rtcSession[key], jsonCopy[key], "key " + key + " should match.");
}
/** Test for Bug 928304 **/
var rtcIceCandidate = new mozRTCIceCandidate({ candidate: "dummy",
sdpMid: "test",
sdpMLineIndex: 3 });
jsonCopy = JSON.parse(JSON.stringify(rtcIceCandidate));
for (key in rtcIceCandidate) {
if (typeof(rtcIceCandidate[key]) == "function") continue;
is(rtcIceCandidate[key], jsonCopy[key], "key " + key + " should match.");
}
SimpleTest.finish();
});
</script>
</pre> </pre>
</body> </body>
</html> </html>

View File

@ -330,7 +330,7 @@ var interfaceNamesInGlobalScope =
"MediaStream", "MediaStream",
"MediaStreamAudioDestinationNode", "MediaStreamAudioDestinationNode",
"MediaStreamAudioSourceNode", "MediaStreamAudioSourceNode",
"MediaStreamEvent", {name: "MediaStreamEvent", pref: "media.peerconnection.enabled"},
"MediaStreamTrack", "MediaStreamTrack",
"MessageEvent", "MessageEvent",
"MessagePort", "MessagePort",
@ -366,9 +366,9 @@ var interfaceNamesInGlobalScope =
{name: "MozNFCTag", b2g: true}, {name: "MozNFCTag", b2g: true},
{name: "MozOtaStatusEvent", b2g: true, pref: "dom.mobileconnection.enabled"}, {name: "MozOtaStatusEvent", b2g: true, pref: "dom.mobileconnection.enabled"},
"MozPowerManager", "MozPowerManager",
"mozRTCIceCandidate", {name: "mozRTCIceCandidate", pref: "media.peerconnection.enabled"},
"mozRTCPeerConnection", {name: "mozRTCPeerConnection", pref: "media.peerconnection.enabled"},
"mozRTCSessionDescription", {name: "mozRTCSessionDescription", pref: "media.peerconnection.enabled"},
"MozSettingsEvent", "MozSettingsEvent",
"MozSmsEvent", "MozSmsEvent",
"MozSmsFilter", "MozSmsFilter",
@ -419,9 +419,9 @@ var interfaceNamesInGlobalScope =
"RecordErrorEvent", "RecordErrorEvent",
"Rect", "Rect",
"RGBColor", "RGBColor",
"RTCDataChannelEvent", {name: "RTCDataChannelEvent", pref: "media.peerconnection.enabled"},
"RTCPeerConnectionIceEvent", {name: "RTCPeerConnectionIceEvent", pref: "media.peerconnection.enabled"},
"RTCStatsReport", {name: "RTCStatsReport", pref: "media.peerconnection.enabled"},
"Screen", "Screen",
"ScriptProcessorNode", "ScriptProcessorNode",
"ScrollAreaEvent", "ScrollAreaEvent",

View File

@ -230,14 +230,20 @@ pref("media.apple.mp3.enabled", true);
#endif #endif
#ifdef MOZ_WEBRTC #ifdef MOZ_WEBRTC
pref("media.navigator.enabled", true); pref("media.navigator.enabled", true);
pref("media.navigator.load_adapt", false);
pref("media.navigator.video.default_width",640); pref("media.navigator.video.default_width",640);
pref("media.navigator.video.default_height",480); pref("media.navigator.video.default_height",480);
pref("media.navigator.video.default_fps",30); pref("media.navigator.video.default_fps",30);
pref("media.navigator.video.default_minfps",10); pref("media.navigator.video.default_minfps",10);
#ifdef MOZ_WIDGET_GONK
pref("media.peerconnection.enabled", false);
pref("media.navigator.video.max_fs", 1200); // 640x480 == 1200mb
pref("media.navigator.video.max_fr", 30);
#else
pref("media.peerconnection.enabled", true);
pref("media.navigator.video.max_fs", 0); // unrestricted pref("media.navigator.video.max_fs", 0); // unrestricted
pref("media.navigator.video.max_fr", 0); // unrestricted pref("media.navigator.video.max_fr", 0); // unrestricted
pref("media.navigator.load_adapt", false); #endif
pref("media.peerconnection.enabled", true);
pref("media.navigator.permission.disabled", false); pref("media.navigator.permission.disabled", false);
pref("media.peerconnection.default_iceservers", "[{\"url\": \"stun:stun.services.mozilla.com\"}]"); pref("media.peerconnection.default_iceservers", "[{\"url\": \"stun:stun.services.mozilla.com\"}]");
pref("media.peerconnection.trickle_ice", true); pref("media.peerconnection.trickle_ice", true);