зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1524688: Part 3 - Convert PeerConnection to static registration r=jib
--HG-- rename : dom/media/PeerConnection.js => dom/media/PeerConnection.jsm extra : rebase_source : 2c18cf151143babf414a2135ec2c7a64b7e976ed
This commit is contained in:
Родитель
075d41c086
Коммит
b8409da492
|
@ -316,11 +316,6 @@
|
|||
@RESPATH@/components/ClearDataService.manifest
|
||||
@RESPATH@/components/ClearDataService.js
|
||||
|
||||
#ifdef MOZ_WEBRTC
|
||||
@RESPATH@/components/PeerConnection.js
|
||||
@RESPATH@/components/PeerConnection.manifest
|
||||
#endif
|
||||
|
||||
; Remote control protocol
|
||||
#ifdef ENABLE_MARIONETTE
|
||||
@RESPATH@/chrome/marionette@JAREXT@
|
||||
|
|
|
@ -6,19 +6,15 @@
|
|||
"use strict";
|
||||
|
||||
const {Services} = ChromeUtils.import("resource://gre/modules/Services.jsm");
|
||||
const {XPCOMUtils} = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
|
||||
ChromeUtils.defineModuleGetter(this, "PeerConnectionIdp",
|
||||
"resource://gre/modules/media/PeerConnectionIdp.jsm");
|
||||
ChromeUtils.defineModuleGetter(this, "convertToRTCStatsReport",
|
||||
"resource://gre/modules/media/RTCStatsReport.jsm");
|
||||
ChromeUtils.defineModuleGetter(this, "AppConstants",
|
||||
"resource://gre/modules/AppConstants.jsm");
|
||||
|
||||
const PC_CONTRACT = "@mozilla.org/dom/peerconnection;1";
|
||||
const PC_OBS_CONTRACT = "@mozilla.org/dom/peerconnectionobserver;1";
|
||||
const PC_ICE_CONTRACT = "@mozilla.org/dom/rtcicecandidate;1";
|
||||
const PC_SESSION_CONTRACT = "@mozilla.org/dom/rtcsessiondescription;1";
|
||||
const PC_MANAGER_CONTRACT = "@mozilla.org/dom/peerconnectionmanager;1";
|
||||
const PC_STATS_CONTRACT = "@mozilla.org/dom/rtcstatsreport;1";
|
||||
const PC_STATIC_CONTRACT = "@mozilla.org/dom/peerconnectionstatic;1";
|
||||
const PC_SENDER_CONTRACT = "@mozilla.org/dom/rtpsender;1";
|
||||
|
@ -2385,17 +2381,16 @@ setupPrototype(CreateOfferRequest, {
|
|||
QueryInterface: ChromeUtils.generateQI([]),
|
||||
});
|
||||
|
||||
this.NSGetFactory = XPCOMUtils.generateNSGetFactory(
|
||||
[GlobalPCList,
|
||||
RTCDTMFSender,
|
||||
RTCIceCandidate,
|
||||
RTCSessionDescription,
|
||||
RTCPeerConnection,
|
||||
RTCPeerConnectionStatic,
|
||||
RTCRtpReceiver,
|
||||
RTCRtpSender,
|
||||
RTCRtpTransceiver,
|
||||
RTCStatsReport,
|
||||
PeerConnectionObserver,
|
||||
CreateOfferRequest]
|
||||
);
|
||||
var EXPORTED_SYMBOLS =
|
||||
["GlobalPCList",
|
||||
"RTCDTMFSender",
|
||||
"RTCIceCandidate",
|
||||
"RTCSessionDescription",
|
||||
"RTCPeerConnection",
|
||||
"RTCPeerConnectionStatic",
|
||||
"RTCRtpReceiver",
|
||||
"RTCRtpSender",
|
||||
"RTCRtpTransceiver",
|
||||
"RTCStatsReport",
|
||||
"PeerConnectionObserver",
|
||||
"CreateOfferRequest"];
|
|
@ -1,23 +0,0 @@
|
|||
component {bdc2e533-b308-4708-ac8e-a8bfade6d851} PeerConnection.js
|
||||
component {d1748d4c-7f6a-4dc5-add6-d55b7678537e} PeerConnection.js
|
||||
component {02b9970c-433d-4cc2-923d-f7028ac66073} PeerConnection.js
|
||||
component {1775081b-b62d-4954-8ffe-a067bbf508a7} PeerConnection.js
|
||||
component {7293e901-2be3-4c02-b4bd-cbef6fc24f78} PeerConnection.js
|
||||
component {7fe6e18b-0da3-4056-bf3b-440ef3809e06} PeerConnection.js
|
||||
component {0fb47c47-a205-4583-a9fc-cbadf8c95880} PeerConnection.js
|
||||
component {4fff5d46-d827-4cd4-a970-8fd53977440e} PeerConnection.js
|
||||
component {d974b814-8fde-411c-8c45-b86791b81030} PeerConnection.js
|
||||
component {74b2122d-65a8-4824-aa9e-3d664cb75dc2} PeerConnection.js
|
||||
component {3610C242-654E-11E6-8EC0-6D1BE389A607} PeerConnection.js
|
||||
|
||||
contract @mozilla.org/dom/peerconnection;1 {bdc2e533-b308-4708-ac8e-a8bfade6d851}
|
||||
contract @mozilla.org/dom/peerconnectionobserver;1 {d1748d4c-7f6a-4dc5-add6-d55b7678537e}
|
||||
contract @mozilla.org/dom/rtcdtmfsender;1 {3610C242-654E-11E6-8EC0-6D1BE389A607}
|
||||
contract @mozilla.org/dom/rtcicecandidate;1 {02b9970c-433d-4cc2-923d-f7028ac66073}
|
||||
contract @mozilla.org/dom/rtcsessiondescription;1 {1775081b-b62d-4954-8ffe-a067bbf508a7}
|
||||
contract @mozilla.org/dom/peerconnectionmanager;1 {7293e901-2be3-4c02-b4bd-cbef6fc24f78}
|
||||
contract @mozilla.org/dom/rtcstatsreport;1 {7fe6e18b-0da3-4056-bf3b-440ef3809e06}
|
||||
contract @mozilla.org/dom/peerconnectionstatic;1 {0fb47c47-a205-4583-a9fc-cbadf8c95880}
|
||||
contract @mozilla.org/dom/rtpsender;1 {4fff5d46-d827-4cd4-a970-8fd53977440e}
|
||||
contract @mozilla.org/dom/rtpreceiver;1 {d974b814-8fde-411c-8c45-b86791b81030}
|
||||
contract @mozilla.org/dom/createofferrequest;1 {74b2122d-65a8-4824-aa9e-3d664cb75dc2}
|
|
@ -0,0 +1,74 @@
|
|||
# -*- Mode: python; indent-tabs-mode: nil; tab-width: 40 -*-
|
||||
# vim: set filetype=python:
|
||||
# This Source Code Form is subject to the terms of the Mozilla Public
|
||||
# License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
Classes = [
|
||||
{
|
||||
'cid': '{bdc2e533-b308-4708-ac8e-a8bfade6d851}',
|
||||
'contract_ids': ['@mozilla.org/dom/peerconnection;1'],
|
||||
'jsm': 'resource://gre/modules/media/PeerConnection.jsm',
|
||||
'constructor': 'RTCPeerConnection',
|
||||
},
|
||||
{
|
||||
'cid': '{d1748d4c-7f6a-4dc5-add6-d55b7678537e}',
|
||||
'contract_ids': ['@mozilla.org/dom/peerconnectionobserver;1'],
|
||||
'jsm': 'resource://gre/modules/media/PeerConnection.jsm',
|
||||
'constructor': 'PeerConnectionObserver',
|
||||
},
|
||||
{
|
||||
'cid': '{3610C242-654E-11E6-8EC0-6D1BE389A607}',
|
||||
'contract_ids': ['@mozilla.org/dom/rtcdtmfsender;1'],
|
||||
'jsm': 'resource://gre/modules/media/PeerConnection.jsm',
|
||||
'constructor': 'RTCDTMFSender',
|
||||
},
|
||||
{
|
||||
'cid': '{02b9970c-433d-4cc2-923d-f7028ac66073}',
|
||||
'contract_ids': ['@mozilla.org/dom/rtcicecandidate;1'],
|
||||
'jsm': 'resource://gre/modules/media/PeerConnection.jsm',
|
||||
'constructor': 'RTCIceCandidate',
|
||||
},
|
||||
{
|
||||
'cid': '{1775081b-b62d-4954-8ffe-a067bbf508a7}',
|
||||
'contract_ids': ['@mozilla.org/dom/rtcsessiondescription;1'],
|
||||
'jsm': 'resource://gre/modules/media/PeerConnection.jsm',
|
||||
'constructor': 'RTCSessionDescription',
|
||||
},
|
||||
{
|
||||
'cid': '{7293e901-2be3-4c02-b4bd-cbef6fc24f78}',
|
||||
'contract_ids': ['@mozilla.org/dom/peerconnectionmanager;1'],
|
||||
'jsm': 'resource://gre/modules/media/PeerConnection.jsm',
|
||||
'constructor': 'GlobalPCList',
|
||||
},
|
||||
{
|
||||
'cid': '{7fe6e18b-0da3-4056-bf3b-440ef3809e06}',
|
||||
'contract_ids': ['@mozilla.org/dom/rtcstatsreport;1'],
|
||||
'jsm': 'resource://gre/modules/media/PeerConnection.jsm',
|
||||
'constructor': 'RTCStatsReport',
|
||||
},
|
||||
{
|
||||
'cid': '{0fb47c47-a205-4583-a9fc-cbadf8c95880}',
|
||||
'contract_ids': ['@mozilla.org/dom/peerconnectionstatic;1'],
|
||||
'jsm': 'resource://gre/modules/media/PeerConnection.jsm',
|
||||
'constructor': 'RTCPeerConnectionStatic',
|
||||
},
|
||||
{
|
||||
'cid': '{4fff5d46-d827-4cd4-a970-8fd53977440e}',
|
||||
'contract_ids': ['@mozilla.org/dom/rtpsender;1'],
|
||||
'jsm': 'resource://gre/modules/media/PeerConnection.jsm',
|
||||
'constructor': 'RTCRtpSender',
|
||||
},
|
||||
{
|
||||
'cid': '{d974b814-8fde-411c-8c45-b86791b81030}',
|
||||
'contract_ids': ['@mozilla.org/dom/rtpreceiver;1'],
|
||||
'jsm': 'resource://gre/modules/media/PeerConnection.jsm',
|
||||
'constructor': 'RTCRtpReceiver',
|
||||
},
|
||||
{
|
||||
'cid': '{74b2122d-65a8-4824-aa9e-3d664cb75dc2}',
|
||||
'contract_ids': ['@mozilla.org/dom/createofferrequest;1'],
|
||||
'jsm': 'resource://gre/modules/media/PeerConnection.jsm',
|
||||
'constructor': 'CreateOfferRequest',
|
||||
},
|
||||
]
|
|
@ -307,9 +307,13 @@ SOURCES += [
|
|||
if CONFIG['CC_TYPE'] in ('clang', 'clang-cl', 'gcc'):
|
||||
SOURCES['DecoderTraits.cpp'].flags += ['-Wno-error=multichar']
|
||||
|
||||
EXTRA_COMPONENTS += [
|
||||
'PeerConnection.js',
|
||||
'PeerConnection.manifest',
|
||||
if CONFIG['MOZ_WEBRTC']:
|
||||
XPCOM_MANIFESTS += [
|
||||
'components.conf',
|
||||
]
|
||||
|
||||
EXTRA_JS_MODULES.media += [
|
||||
'PeerConnection.jsm',
|
||||
]
|
||||
|
||||
EXTRA_JS_MODULES.media += [
|
||||
|
|
|
@ -198,11 +198,6 @@
|
|||
@BINPATH@/components/htmlMenuBuilder.js
|
||||
@BINPATH@/components/htmlMenuBuilder.manifest
|
||||
|
||||
#ifdef MOZ_WEBRTC
|
||||
@BINPATH@/components/PeerConnection.js
|
||||
@BINPATH@/components/PeerConnection.manifest
|
||||
#endif
|
||||
|
||||
@BINPATH@/components/CaptivePortalDetectComponents.manifest
|
||||
@BINPATH@/components/captivedetect.js
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче