<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[214030] trunk/Source/WebCore</title>
</head>
<body>
<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; }
#msg dl a { font-weight: bold}
#msg dl a:link { color:#fc3; }
#msg dl a:active { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/214030">214030</a></dd>
<dt>Author</dt> <dd>jonlee@apple.com</dd>
<dt>Date</dt> <dd>2017-03-15 23:10:34 -0700 (Wed, 15 Mar 2017)</dd>
</dl>
<h3>Log Message</h3>
<pre>Flatten RTC enum naming
https://bugs.webkit.org/show_bug.cgi?id=169664
Reviewed by Youenn Fablet.
Use consistent names of RTC enums throughout WebCore. This means surfacing
ICE enums out of PeerConnectionState. Keep the old names around for other
ports.
Add RTCIceConnectionState, RTCIceGatheringState, and RTCSignalingState enums.
* CMakeLists.txt:
* DerivedSources.make:
* Modules/mediastream/RTCIceConnectionState.h: Added. The enum is defined in
PeerConnectionStates.h, so just include that file.
* Modules/mediastream/RTCIceConnectionState.idl: Added.
* Modules/mediastream/RTCIceGatheringState.h: Added.
* Modules/mediastream/RTCIceGatheringState.idl: Added.
* Modules/mediastream/RTCSignalingState.h: Added.
* Modules/mediastream/RTCSignalingState.idl: Added.
* WebCore.xcodeproj/project.pbxproj:
* platform/mediastream/PeerConnectionStates.h: Move the existing enums into
WebCore, but keep aliases to the old names within the PeerConnectionStates
namespace.
Refactor to use the new enum names.
* Modules/mediastream/MediaEndpointPeerConnection.cpp: Refactor.
* Modules/mediastream/MediaEndpointPeerConnection.h:
* Modules/mediastream/PeerConnectionBackend.cpp:
* Modules/mediastream/PeerConnectionBackend.h:
* Modules/mediastream/RTCConfiguration.h:
* Modules/mediastream/RTCConfiguration.idl: Add FIXMEs for bringing this up
to spec.
* Modules/mediastream/RTCIceTransport.h:
* Modules/mediastream/RTCPeerConnection.cpp: Refactor the three functions
below to using the enum instead of returning strings. This allows remove of
the internal* versions of these functions.
(WebCore::RTCPeerConnection::signalingState): Deleted.
(WebCore::RTCPeerConnection::iceGatheringState): Deleted.
(WebCore::RTCPeerConnection::iceConnectionState): Deleted.
* Modules/mediastream/RTCPeerConnection.h: Replace internalSignalingState,
internalIceGatheringState, and internalIceConnectionState.
* Modules/mediastream/RTCPeerConnection.idl:
* Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.cpp:
* Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.cpp:
* platform/mediastream/MediaEndpoint.h:
* platform/mediastream/MediaEndpointConfiguration.cpp:
* platform/mediastream/MediaEndpointConfiguration.h:
* platform/mock/MockMediaEndpoint.cpp:
* platform/mock/MockMediaEndpoint.h:
* platform/mediastream/openwebrtc/MediaEndpointOwr.cpp:
(WebCore::MediaEndpointOwr::processIceTransportStateChange):</pre>
<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkSourceWebCoreCMakeListstxt">trunk/Source/WebCore/CMakeLists.txt</a></li>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCoreDerivedSourcesmake">trunk/Source/WebCore/DerivedSources.make</a></li>
<li><a href="#trunkSourceWebCoreModulesmediastreamMediaEndpointPeerConnectioncpp">trunk/Source/WebCore/Modules/mediastream/MediaEndpointPeerConnection.cpp</a></li>
<li><a href="#trunkSourceWebCoreModulesmediastreamMediaEndpointPeerConnectionh">trunk/Source/WebCore/Modules/mediastream/MediaEndpointPeerConnection.h</a></li>
<li><a href="#trunkSourceWebCoreModulesmediastreamPeerConnectionBackendcpp">trunk/Source/WebCore/Modules/mediastream/PeerConnectionBackend.cpp</a></li>
<li><a href="#trunkSourceWebCoreModulesmediastreamPeerConnectionBackendh">trunk/Source/WebCore/Modules/mediastream/PeerConnectionBackend.h</a></li>
<li><a href="#trunkSourceWebCoreModulesmediastreamRTCConfigurationh">trunk/Source/WebCore/Modules/mediastream/RTCConfiguration.h</a></li>
<li><a href="#trunkSourceWebCoreModulesmediastreamRTCConfigurationidl">trunk/Source/WebCore/Modules/mediastream/RTCConfiguration.idl</a></li>
<li><a href="#trunkSourceWebCoreModulesmediastreamRTCIceTransporth">trunk/Source/WebCore/Modules/mediastream/RTCIceTransport.h</a></li>
<li><a href="#trunkSourceWebCoreModulesmediastreamRTCPeerConnectioncpp">trunk/Source/WebCore/Modules/mediastream/RTCPeerConnection.cpp</a></li>
<li><a href="#trunkSourceWebCoreModulesmediastreamRTCPeerConnectionh">trunk/Source/WebCore/Modules/mediastream/RTCPeerConnection.h</a></li>
<li><a href="#trunkSourceWebCoreModulesmediastreamRTCPeerConnectionidl">trunk/Source/WebCore/Modules/mediastream/RTCPeerConnection.idl</a></li>
<li><a href="#trunkSourceWebCoreModulesmediastreamlibwebrtcLibWebRTCMediaEndpointcpp">trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.cpp</a></li>
<li><a href="#trunkSourceWebCoreModulesmediastreamlibwebrtcLibWebRTCPeerConnectionBackendcpp">trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.cpp</a></li>
<li><a href="#trunkSourceWebCoreWebCorexcodeprojprojectpbxproj">trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj</a></li>
<li><a href="#trunkSourceWebCoreplatformmediastreamMediaEndpointh">trunk/Source/WebCore/platform/mediastream/MediaEndpoint.h</a></li>
<li><a href="#trunkSourceWebCoreplatformmediastreamMediaEndpointConfigurationcpp">trunk/Source/WebCore/platform/mediastream/MediaEndpointConfiguration.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformmediastreamMediaEndpointConfigurationh">trunk/Source/WebCore/platform/mediastream/MediaEndpointConfiguration.h</a></li>
<li><a href="#trunkSourceWebCoreplatformmediastreamPeerConnectionStatesh">trunk/Source/WebCore/platform/mediastream/PeerConnectionStates.h</a></li>
<li><a href="#trunkSourceWebCoreplatformmediastreamopenwebrtcMediaEndpointOwrcpp">trunk/Source/WebCore/platform/mediastream/openwebrtc/MediaEndpointOwr.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformmockMockMediaEndpointcpp">trunk/Source/WebCore/platform/mock/MockMediaEndpoint.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformmockMockMediaEndpointh">trunk/Source/WebCore/platform/mock/MockMediaEndpoint.h</a></li>
</ul>
<h3>Added Paths</h3>
<ul>
<li><a href="#trunkSourceWebCoreModulesmediastreamRTCIceConnectionStateh">trunk/Source/WebCore/Modules/mediastream/RTCIceConnectionState.h</a></li>
<li><a href="#trunkSourceWebCoreModulesmediastreamRTCIceConnectionStateidl">trunk/Source/WebCore/Modules/mediastream/RTCIceConnectionState.idl</a></li>
<li><a href="#trunkSourceWebCoreModulesmediastreamRTCIceGatheringStateh">trunk/Source/WebCore/Modules/mediastream/RTCIceGatheringState.h</a></li>
<li><a href="#trunkSourceWebCoreModulesmediastreamRTCIceGatheringStateidl">trunk/Source/WebCore/Modules/mediastream/RTCIceGatheringState.idl</a></li>
<li><a href="#trunkSourceWebCoreModulesmediastreamRTCSignalingStateh">trunk/Source/WebCore/Modules/mediastream/RTCSignalingState.h</a></li>
<li><a href="#trunkSourceWebCoreModulesmediastreamRTCSignalingStateidl">trunk/Source/WebCore/Modules/mediastream/RTCSignalingState.idl</a></li>
</ul>
</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkSourceWebCoreCMakeListstxt"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/CMakeLists.txt (214029 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/CMakeLists.txt        2017-03-16 05:12:53 UTC (rev 214029)
+++ trunk/Source/WebCore/CMakeLists.txt        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -241,6 +241,8 @@
</span><span class="cx"> Modules/mediastream/RTCDataChannelEvent.idl
</span><span class="cx"> Modules/mediastream/RTCIceCandidate.idl
</span><span class="cx"> Modules/mediastream/RTCIceCandidateEvent.idl
</span><ins>+ Modules/mediastream/RTCIceConnectionState.idl
+ Modules/mediastream/RTCIceGatheringState.idl
</ins><span class="cx"> Modules/mediastream/RTCIceServer.idl
</span><span class="cx"> Modules/mediastream/RTCOfferAnswerOptions.idl
</span><span class="cx"> Modules/mediastream/RTCOfferOptions.idl
</span><span class="lines">@@ -250,6 +252,7 @@
</span><span class="cx"> Modules/mediastream/RTCRtpTransceiver.idl
</span><span class="cx"> Modules/mediastream/RTCRtpTransceiverDirection.idl
</span><span class="cx"> Modules/mediastream/RTCSessionDescription.idl
</span><ins>+ Modules/mediastream/RTCSignalingState.idl
</ins><span class="cx"> Modules/mediastream/RTCStatsReport.idl
</span><span class="cx"> Modules/mediastream/RTCTrackEvent.idl
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (214029 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2017-03-16 05:12:53 UTC (rev 214029)
+++ trunk/Source/WebCore/ChangeLog        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -1,3 +1,58 @@
</span><ins>+2017-03-15 Jon Lee <jonlee@apple.com>
+
+ Flatten RTC enum naming
+ https://bugs.webkit.org/show_bug.cgi?id=169664
+
+ Reviewed by Youenn Fablet.
+
+ Use consistent names of RTC enums throughout WebCore. This means surfacing
+ ICE enums out of PeerConnectionState. Keep the old names around for other
+ ports.
+
+ Add RTCIceConnectionState, RTCIceGatheringState, and RTCSignalingState enums.
+ * CMakeLists.txt:
+ * DerivedSources.make:
+ * Modules/mediastream/RTCIceConnectionState.h: Added. The enum is defined in
+ PeerConnectionStates.h, so just include that file.
+ * Modules/mediastream/RTCIceConnectionState.idl: Added.
+ * Modules/mediastream/RTCIceGatheringState.h: Added.
+ * Modules/mediastream/RTCIceGatheringState.idl: Added.
+ * Modules/mediastream/RTCSignalingState.h: Added.
+ * Modules/mediastream/RTCSignalingState.idl: Added.
+ * WebCore.xcodeproj/project.pbxproj:
+
+ * platform/mediastream/PeerConnectionStates.h: Move the existing enums into
+ WebCore, but keep aliases to the old names within the PeerConnectionStates
+ namespace.
+
+ Refactor to use the new enum names.
+ * Modules/mediastream/MediaEndpointPeerConnection.cpp: Refactor.
+ * Modules/mediastream/MediaEndpointPeerConnection.h:
+ * Modules/mediastream/PeerConnectionBackend.cpp:
+ * Modules/mediastream/PeerConnectionBackend.h:
+ * Modules/mediastream/RTCConfiguration.h:
+ * Modules/mediastream/RTCConfiguration.idl: Add FIXMEs for bringing this up
+ to spec.
+ * Modules/mediastream/RTCIceTransport.h:
+ * Modules/mediastream/RTCPeerConnection.cpp: Refactor the three functions
+ below to using the enum instead of returning strings. This allows remove of
+ the internal* versions of these functions.
+ (WebCore::RTCPeerConnection::signalingState): Deleted.
+ (WebCore::RTCPeerConnection::iceGatheringState): Deleted.
+ (WebCore::RTCPeerConnection::iceConnectionState): Deleted.
+ * Modules/mediastream/RTCPeerConnection.h: Replace internalSignalingState,
+ internalIceGatheringState, and internalIceConnectionState.
+ * Modules/mediastream/RTCPeerConnection.idl:
+ * Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.cpp:
+ * Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.cpp:
+ * platform/mediastream/MediaEndpoint.h:
+ * platform/mediastream/MediaEndpointConfiguration.cpp:
+ * platform/mediastream/MediaEndpointConfiguration.h:
+ * platform/mock/MockMediaEndpoint.cpp:
+ * platform/mock/MockMediaEndpoint.h:
+ * platform/mediastream/openwebrtc/MediaEndpointOwr.cpp:
+ (WebCore::MediaEndpointOwr::processIceTransportStateChange):
+
</ins><span class="cx"> 2017-03-15 Jer Noble <jer.noble@apple.com>
</span><span class="cx">
</span><span class="cx"> Optionally capture audio in the UIProcess
</span></span></pre></div>
<a id="trunkSourceWebCoreDerivedSourcesmake"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/DerivedSources.make (214029 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/DerivedSources.make        2017-03-16 05:12:53 UTC (rev 214029)
+++ trunk/Source/WebCore/DerivedSources.make        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -185,6 +185,8 @@
</span><span class="cx"> $(WebCore)/Modules/mediastream/RTCDataChannelEvent.idl \
</span><span class="cx"> $(WebCore)/Modules/mediastream/RTCIceCandidate.idl \
</span><span class="cx"> $(WebCore)/Modules/mediastream/RTCIceCandidateEvent.idl \
</span><ins>+ $(WebCore)/Modules/mediastream/RTCIceConnectionState.idl \
+ $(WebCore)/Modules/mediastream/RTCIceGatheringState.idl \
</ins><span class="cx"> $(WebCore)/Modules/mediastream/RTCIceServer.idl \
</span><span class="cx"> $(WebCore)/Modules/mediastream/RTCOfferAnswerOptions.idl \
</span><span class="cx"> $(WebCore)/Modules/mediastream/RTCOfferOptions.idl \
</span><span class="lines">@@ -194,6 +196,7 @@
</span><span class="cx"> $(WebCore)/Modules/mediastream/RTCRtpTransceiver.idl \
</span><span class="cx"> $(WebCore)/Modules/mediastream/RTCRtpTransceiverDirection.idl \
</span><span class="cx"> $(WebCore)/Modules/mediastream/RTCSessionDescription.idl \
</span><ins>+ $(WebCore)/Modules/mediastream/RTCSignalingState.idl \
</ins><span class="cx"> $(WebCore)/Modules/mediastream/RTCStatsReport.idl \
</span><span class="cx"> $(WebCore)/Modules/mediastream/RTCTrackEvent.idl \
</span><span class="cx"> $(WebCore)/Modules/notifications/DOMWindowNotifications.idl \
</span></span></pre></div>
<a id="trunkSourceWebCoreModulesmediastreamMediaEndpointPeerConnectioncpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/mediastream/MediaEndpointPeerConnection.cpp (214029 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/mediastream/MediaEndpointPeerConnection.cpp        2017-03-16 05:12:53 UTC (rev 214029)
+++ trunk/Source/WebCore/Modules/mediastream/MediaEndpointPeerConnection.cpp        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -1,5 +1,6 @@
</span><span class="cx"> /*
</span><span class="cx"> * Copyright (C) 2015 Ericsson AB. All rights reserved.
</span><ins>+ * Copyright (C) 2017 Apple Inc. All rights reserved.
</ins><span class="cx"> *
</span><span class="cx"> * Redistribution and use in source and binary forms, with or without
</span><span class="cx"> * modification, are permitted provided that the following conditions
</span><span class="lines">@@ -29,9 +30,9 @@
</span><span class="cx"> */
</span><span class="cx">
</span><span class="cx"> #include "config.h"
</span><ins>+#include "MediaEndpointPeerConnection.h"
</ins><span class="cx">
</span><span class="cx"> #if ENABLE(WEB_RTC)
</span><del>-#include "MediaEndpointPeerConnection.h"
</del><span class="cx">
</span><span class="cx"> #include "EventNames.h"
</span><span class="cx"> #include "JSRTCSessionDescription.h"
</span><span class="lines">@@ -57,7 +58,6 @@
</span><span class="cx"> namespace WebCore {
</span><span class="cx">
</span><span class="cx"> using namespace PeerConnection;
</span><del>-using namespace PeerConnectionStates;
</del><span class="cx">
</span><span class="cx"> using MediaDescriptionVector = Vector<PeerMediaDescription>;
</span><span class="cx"> using RtpTransceiverVector = Vector<RefPtr<RTCRtpTransceiver>>;
</span><span class="lines">@@ -330,7 +330,7 @@
</span><span class="cx">
</span><span class="cx"> void MediaEndpointPeerConnection::setLocalDescriptionTask(RefPtr<RTCSessionDescription>&& description)
</span><span class="cx"> {
</span><del>- if (m_peerConnection.internalSignalingState() == SignalingState::Closed)
</del><ins>+ if (m_peerConnection.signalingState() == RTCSignalingState::Closed)
</ins><span class="cx"> return;
</span><span class="cx">
</span><span class="cx"> auto result = MediaEndpointSessionDescription::create(WTFMove(description), *m_sdpProcessor);
</span><span class="lines">@@ -351,11 +351,11 @@
</span><span class="cx"> MediaEndpoint::UpdateResult result = m_mediaEndpoint->updateReceiveConfiguration(newDescription->configuration(), isInitiator);
</span><span class="cx">
</span><span class="cx"> if (result == MediaEndpoint::UpdateResult::SuccessWithIceRestart) {
</span><del>- if (m_peerConnection.internalIceGatheringState() != IceGatheringState::Gathering)
- m_peerConnection.updateIceGatheringState(IceGatheringState::Gathering);
</del><ins>+ if (m_peerConnection.iceGatheringState() != RTCIceGatheringState::Gathering)
+ m_peerConnection.updateIceGatheringState(RTCIceGatheringState::Gathering);
</ins><span class="cx">
</span><del>- if (m_peerConnection.internalIceConnectionState() != IceConnectionState::Completed)
- m_peerConnection.updateIceConnectionState(IceConnectionState::Connected);
</del><ins>+ if (m_peerConnection.iceConnectionState() != RTCIceConnectionState::Completed)
+ m_peerConnection.updateIceConnectionState(RTCIceConnectionState::Connected);
</ins><span class="cx">
</span><span class="cx"> LOG_ERROR("ICE restart is not implemented");
</span><span class="cx"> notImplemented();
</span><span class="lines">@@ -388,13 +388,13 @@
</span><span class="cx"> if (!hasUnassociatedTransceivers(transceivers))
</span><span class="cx"> clearNegotiationNeededState();
</span><span class="cx">
</span><del>- SignalingState newSignalingState;
</del><ins>+ RTCSignalingState newSignalingState;
</ins><span class="cx">
</span><span class="cx"> // Update state and local descriptions according to setLocal/RemoteDescription processing model
</span><span class="cx"> switch (newDescription->type()) {
</span><span class="cx"> case RTCSessionDescription::SdpType::Offer:
</span><span class="cx"> m_pendingLocalDescription = WTFMove(newDescription);
</span><del>- newSignalingState = SignalingState::HaveLocalOffer;
</del><ins>+ newSignalingState = RTCSignalingState::HaveLocalOffer;
</ins><span class="cx"> break;
</span><span class="cx">
</span><span class="cx"> case RTCSessionDescription::SdpType::Answer:
</span><span class="lines">@@ -402,24 +402,24 @@
</span><span class="cx"> m_currentRemoteDescription = m_pendingRemoteDescription;
</span><span class="cx"> m_pendingLocalDescription = nullptr;
</span><span class="cx"> m_pendingRemoteDescription = nullptr;
</span><del>- newSignalingState = SignalingState::Stable;
</del><ins>+ newSignalingState = RTCSignalingState::Stable;
</ins><span class="cx"> break;
</span><span class="cx">
</span><span class="cx"> case RTCSessionDescription::SdpType::Rollback:
</span><span class="cx"> m_pendingLocalDescription = nullptr;
</span><del>- newSignalingState = SignalingState::Stable;
</del><ins>+ newSignalingState = RTCSignalingState::Stable;
</ins><span class="cx"> break;
</span><span class="cx">
</span><span class="cx"> case RTCSessionDescription::SdpType::Pranswer:
</span><span class="cx"> m_pendingLocalDescription = WTFMove(newDescription);
</span><del>- newSignalingState = SignalingState::HaveLocalPrAnswer;
</del><ins>+ newSignalingState = RTCSignalingState::HaveLocalPranswer;
</ins><span class="cx"> break;
</span><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> updateSignalingState(newSignalingState);
</span><span class="cx">
</span><del>- if (m_peerConnection.internalIceGatheringState() == IceGatheringState::New && mediaDescriptions.size())
- m_peerConnection.updateIceGatheringState(IceGatheringState::Gathering);
</del><ins>+ if (m_peerConnection.iceGatheringState() == RTCIceGatheringState::New && mediaDescriptions.size())
+ m_peerConnection.updateIceGatheringState(RTCIceGatheringState::Gathering);
</ins><span class="cx">
</span><span class="cx"> markAsNeedingNegotiation();
</span><span class="cx"> setLocalDescriptionSucceeded();
</span><span class="lines">@@ -552,13 +552,13 @@
</span><span class="cx"> for (auto& event : legacyMediaStreamEvents)
</span><span class="cx"> m_peerConnection.fireEvent(*event);
</span><span class="cx">
</span><del>- SignalingState newSignalingState;
</del><ins>+ RTCSignalingState newSignalingState;
</ins><span class="cx">
</span><span class="cx"> // Update state and local descriptions according to setLocal/RemoteDescription processing model
</span><span class="cx"> switch (newDescription->type()) {
</span><span class="cx"> case RTCSessionDescription::SdpType::Offer:
</span><span class="cx"> m_pendingRemoteDescription = WTFMove(newDescription);
</span><del>- newSignalingState = SignalingState::HaveRemoteOffer;
</del><ins>+ newSignalingState = RTCSignalingState::HaveRemoteOffer;
</ins><span class="cx"> break;
</span><span class="cx">
</span><span class="cx"> case RTCSessionDescription::SdpType::Answer:
</span><span class="lines">@@ -566,17 +566,17 @@
</span><span class="cx"> m_currentLocalDescription = m_pendingLocalDescription;
</span><span class="cx"> m_pendingRemoteDescription = nullptr;
</span><span class="cx"> m_pendingLocalDescription = nullptr;
</span><del>- newSignalingState = SignalingState::Stable;
</del><ins>+ newSignalingState = RTCSignalingState::Stable;
</ins><span class="cx"> break;
</span><span class="cx">
</span><span class="cx"> case RTCSessionDescription::SdpType::Rollback:
</span><span class="cx"> m_pendingRemoteDescription = nullptr;
</span><del>- newSignalingState = SignalingState::Stable;
</del><ins>+ newSignalingState = RTCSignalingState::Stable;
</ins><span class="cx"> break;
</span><span class="cx">
</span><span class="cx"> case RTCSessionDescription::SdpType::Pranswer:
</span><span class="cx"> m_pendingRemoteDescription = WTFMove(newDescription);
</span><del>- newSignalingState = SignalingState::HaveRemotePrAnswer;
</del><ins>+ newSignalingState = RTCSignalingState::HaveRemotePranswer;
</ins><span class="cx"> break;
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -716,7 +716,7 @@
</span><span class="cx">
</span><span class="cx"> void MediaEndpointPeerConnection::replaceTrackTask(RTCRtpSender& sender, const String& mid, Ref<MediaStreamTrack>&& withTrack, DOMPromise<void>& promise)
</span><span class="cx"> {
</span><del>- if (m_peerConnection.internalSignalingState() == SignalingState::Closed)
</del><ins>+ if (m_peerConnection.signalingState() == RTCSignalingState::Closed)
</ins><span class="cx"> return;
</span><span class="cx">
</span><span class="cx"> m_mediaEndpoint->replaceSendSource(withTrack->source(), mid);
</span><span class="lines">@@ -795,18 +795,18 @@
</span><span class="cx"> RTCRtpTransceiver* notifyingTransceiver = matchTransceiverByMid(transceivers, mid);
</span><span class="cx"> ASSERT(notifyingTransceiver);
</span><span class="cx">
</span><del>- notifyingTransceiver->iceTransport().setGatheringState(RTCIceTransport::GatheringState::Complete);
</del><ins>+ notifyingTransceiver->iceTransport().setGatheringState(RTCIceGatheringState::Complete);
</ins><span class="cx">
</span><span class="cx"> // Don't notify the script if there are transceivers still gathering.
</span><span class="cx"> RTCRtpTransceiver* stillGatheringTransceiver = matchTransceiver(transceivers, [] (RTCRtpTransceiver& current) {
</span><span class="cx"> return !current.stopped() && !current.mid().isNull()
</span><del>- && current.iceTransport().gatheringState() != RTCIceTransport::GatheringState::Complete;
</del><ins>+ && current.iceTransport().gatheringState() != RTCIceGatheringState::Complete;
</ins><span class="cx"> });
</span><span class="cx"> if (!stillGatheringTransceiver)
</span><span class="cx"> PeerConnectionBackend::doneGatheringCandidates();
</span><span class="cx"> }
</span><span class="cx">
</span><del>-static RTCIceTransport::TransportState deriveAggregatedIceConnectionState(const Vector<RTCIceTransport::TransportState>& states)
</del><ins>+static RTCIceTransportState deriveAggregatedIceConnectionState(const Vector<RTCIceTransportState>& states)
</ins><span class="cx"> {
</span><span class="cx"> unsigned newCount = 0;
</span><span class="cx"> unsigned checkingCount = 0;
</span><span class="lines">@@ -818,40 +818,54 @@
</span><span class="cx">
</span><span class="cx"> for (auto& state : states) {
</span><span class="cx"> switch (state) {
</span><del>- case RTCIceTransport::TransportState::New: ++newCount; break;
- case RTCIceTransport::TransportState::Checking: ++checkingCount; break;
- case RTCIceTransport::TransportState::Connected: ++connectedCount; break;
- case RTCIceTransport::TransportState::Completed: ++completedCount; break;
- case RTCIceTransport::TransportState::Failed: ++failedCount; break;
- case RTCIceTransport::TransportState::Disconnected: ++disconnectedCount; break;
- case RTCIceTransport::TransportState::Closed: ++closedCount; break;
</del><ins>+ case RTCIceTransportState::New:
+ ++newCount;
+ break;
+ case RTCIceTransportState::Checking:
+ ++checkingCount;
+ break;
+ case RTCIceTransportState::Connected:
+ ++connectedCount;
+ break;
+ case RTCIceTransportState::Completed:
+ ++completedCount;
+ break;
+ case RTCIceTransportState::Failed:
+ ++failedCount;
+ break;
+ case RTCIceTransportState::Disconnected:
+ ++disconnectedCount;
+ break;
+ case RTCIceTransportState::Closed:
+ ++closedCount;
+ break;
</ins><span class="cx"> }
</span><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> // The aggregated RTCIceConnectionState is derived from the RTCIceTransportState of all RTCIceTransports.
</span><span class="cx"> if ((newCount > 0 && !checkingCount && !failedCount && !disconnectedCount) || (closedCount == states.size()))
</span><del>- return RTCIceTransport::TransportState::New;
</del><ins>+ return RTCIceTransportState::New;
</ins><span class="cx">
</span><span class="cx"> if (checkingCount > 0 && !failedCount && !disconnectedCount)
</span><del>- return RTCIceTransport::TransportState::Checking;
</del><ins>+ return RTCIceTransportState::Checking;
</ins><span class="cx">
</span><span class="cx"> if ((connectedCount + completedCount + closedCount) == states.size() && connectedCount > 0)
</span><del>- return RTCIceTransport::TransportState::Connected;
</del><ins>+ return RTCIceTransportState::Connected;
</ins><span class="cx">
</span><span class="cx"> if ((completedCount + closedCount) == states.size() && completedCount > 0)
</span><del>- return RTCIceTransport::TransportState::Completed;
</del><ins>+ return RTCIceTransportState::Completed;
</ins><span class="cx">
</span><span class="cx"> if (failedCount > 0)
</span><del>- return RTCIceTransport::TransportState::Failed;
</del><ins>+ return RTCIceTransportState::Failed;
</ins><span class="cx">
</span><span class="cx"> if (disconnectedCount > 0) // Any failed caught above.
</span><del>- return RTCIceTransport::TransportState::Disconnected;
</del><ins>+ return RTCIceTransportState::Disconnected;
</ins><span class="cx">
</span><span class="cx"> ASSERT_NOT_REACHED();
</span><del>- return RTCIceTransport::TransportState::New;
</del><ins>+ return RTCIceTransportState::New;
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-void MediaEndpointPeerConnection::iceTransportStateChanged(const String& mid, MediaEndpoint::IceTransportState mediaEndpointIceTransportState)
</del><ins>+void MediaEndpointPeerConnection::iceTransportStateChanged(const String& mid, RTCIceTransportState mediaEndpointIceTransportState)
</ins><span class="cx"> {
</span><span class="cx"> ASSERT(isMainThread());
</span><span class="cx">
</span><span class="lines">@@ -858,16 +872,16 @@
</span><span class="cx"> RTCRtpTransceiver* transceiver = matchTransceiverByMid(m_peerConnection.getTransceivers(), mid);
</span><span class="cx"> ASSERT(transceiver);
</span><span class="cx">
</span><del>- RTCIceTransport::TransportState transportState = static_cast<RTCIceTransport::TransportState>(mediaEndpointIceTransportState);
</del><ins>+ RTCIceTransportState transportState = static_cast<RTCIceTransportState>(mediaEndpointIceTransportState);
</ins><span class="cx"> transceiver->iceTransport().setTransportState(transportState);
</span><span class="cx">
</span><span class="cx"> // Determine if the script needs to be notified.
</span><del>- Vector<RTCIceTransport::TransportState> transportStates;
</del><ins>+ Vector<RTCIceTransportState> transportStates;
</ins><span class="cx"> for (auto& transceiver : m_peerConnection.getTransceivers())
</span><span class="cx"> transportStates.append(transceiver->iceTransport().transportState());
</span><span class="cx">
</span><del>- RTCIceTransport::TransportState derivedState = deriveAggregatedIceConnectionState(transportStates);
- m_peerConnection.updateIceConnectionState(static_cast<IceConnectionState>(derivedState));
</del><ins>+ RTCIceTransportState derivedState = deriveAggregatedIceConnectionState(transportStates);
+ m_peerConnection.updateIceConnectionState(static_cast<RTCIceConnectionState>(derivedState));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCoreModulesmediastreamMediaEndpointPeerConnectionh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/mediastream/MediaEndpointPeerConnection.h (214029 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/mediastream/MediaEndpointPeerConnection.h        2017-03-16 05:12:53 UTC (rev 214029)
+++ trunk/Source/WebCore/Modules/mediastream/MediaEndpointPeerConnection.h        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -1,5 +1,6 @@
</span><span class="cx"> /*
</span><span class="cx"> * Copyright (C) 2015, 2016 Ericsson AB. All rights reserved.
</span><ins>+ * Copyright (C) 2017 Apple Inc. All rights reserved.
</ins><span class="cx"> *
</span><span class="cx"> * Redistribution and use in source and binary forms, with or without
</span><span class="cx"> * modification, are permitted provided that the following conditions
</span><span class="lines">@@ -34,6 +35,7 @@
</span><span class="cx">
</span><span class="cx"> #include "MediaEndpoint.h"
</span><span class="cx"> #include "PeerConnectionBackend.h"
</span><ins>+#include "RTCEnums.h"
</ins><span class="cx"> #include "RTCSessionDescription.h"
</span><span class="cx"> #include <wtf/Function.h>
</span><span class="cx">
</span><span class="lines">@@ -97,7 +99,7 @@
</span><span class="cx"> void gotDtlsFingerprint(const String& fingerprint, const String& fingerprintFunction) final;
</span><span class="cx"> void gotIceCandidate(const String& mid, IceCandidate&&) final;
</span><span class="cx"> void doneGatheringCandidates(const String& mid) final;
</span><del>- void iceTransportStateChanged(const String& mid, MediaEndpoint::IceTransportState) final;
</del><ins>+ void iceTransportStateChanged(const String& mid, RTCIceTransportState) final;
</ins><span class="cx">
</span><span class="cx"> std::unique_ptr<RTCDataChannelHandler> createDataChannelHandler(const String&, const RTCDataChannelInit&) final;
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCoreModulesmediastreamPeerConnectionBackendcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/mediastream/PeerConnectionBackend.cpp (214029 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/mediastream/PeerConnectionBackend.cpp        2017-03-16 05:12:53 UTC (rev 214029)
+++ trunk/Source/WebCore/Modules/mediastream/PeerConnectionBackend.cpp        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -1,6 +1,6 @@
</span><span class="cx"> /*
</span><span class="cx"> * Copyright (C) 2015 Ericsson AB. All rights reserved.
</span><del>- * Copyright (C) 2016 Apple INC. All rights reserved.
</del><ins>+ * Copyright (C) 2016-2017 Apple Inc. All rights reserved.
</ins><span class="cx"> *
</span><span class="cx"> * Redistribution and use in source and binary forms, with or without
</span><span class="cx"> * modification, are permitted provided that the following conditions
</span><span class="lines">@@ -46,7 +46,7 @@
</span><span class="cx"> void PeerConnectionBackend::createOffer(RTCOfferOptions&& options, PeerConnection::SessionDescriptionPromise&& promise)
</span><span class="cx"> {
</span><span class="cx"> ASSERT(!m_offerAnswerPromise);
</span><del>- ASSERT(m_peerConnection.internalSignalingState() != PeerConnectionStates::SignalingState::Closed);
</del><ins>+ ASSERT(m_peerConnection.signalingState() != RTCSignalingState::Closed);
</ins><span class="cx">
</span><span class="cx"> m_offerAnswerPromise = WTFMove(promise);
</span><span class="cx"> doCreateOffer(WTFMove(options));
</span><span class="lines">@@ -56,7 +56,7 @@
</span><span class="cx"> {
</span><span class="cx"> ASSERT(isMainThread());
</span><span class="cx">
</span><del>- if (m_peerConnection.internalSignalingState() == PeerConnectionStates::SignalingState::Closed)
</del><ins>+ if (m_peerConnection.signalingState() == RTCSignalingState::Closed)
</ins><span class="cx"> return;
</span><span class="cx">
</span><span class="cx"> ASSERT(m_offerAnswerPromise);
</span><span class="lines">@@ -68,7 +68,7 @@
</span><span class="cx"> {
</span><span class="cx"> ASSERT(isMainThread());
</span><span class="cx">
</span><del>- if (m_peerConnection.internalSignalingState() == PeerConnectionStates::SignalingState::Closed)
</del><ins>+ if (m_peerConnection.signalingState() == RTCSignalingState::Closed)
</ins><span class="cx"> return;
</span><span class="cx">
</span><span class="cx"> ASSERT(m_offerAnswerPromise);
</span><span class="lines">@@ -79,7 +79,7 @@
</span><span class="cx"> void PeerConnectionBackend::createAnswer(RTCAnswerOptions&& options, PeerConnection::SessionDescriptionPromise&& promise)
</span><span class="cx"> {
</span><span class="cx"> ASSERT(!m_offerAnswerPromise);
</span><del>- ASSERT(m_peerConnection.internalSignalingState() != PeerConnectionStates::SignalingState::Closed);
</del><ins>+ ASSERT(m_peerConnection.signalingState() != RTCSignalingState::Closed);
</ins><span class="cx">
</span><span class="cx"> m_offerAnswerPromise = WTFMove(promise);
</span><span class="cx"> doCreateAnswer(WTFMove(options));
</span><span class="lines">@@ -89,7 +89,7 @@
</span><span class="cx"> {
</span><span class="cx"> ASSERT(isMainThread());
</span><span class="cx">
</span><del>- if (m_peerConnection.internalSignalingState() == PeerConnectionStates::SignalingState::Closed)
</del><ins>+ if (m_peerConnection.signalingState() == RTCSignalingState::Closed)
</ins><span class="cx"> return;
</span><span class="cx">
</span><span class="cx"> ASSERT(m_offerAnswerPromise);
</span><span class="lines">@@ -101,7 +101,7 @@
</span><span class="cx"> {
</span><span class="cx"> ASSERT(isMainThread());
</span><span class="cx">
</span><del>- if (m_peerConnection.internalSignalingState() == PeerConnectionStates::SignalingState::Closed)
</del><ins>+ if (m_peerConnection.signalingState() == RTCSignalingState::Closed)
</ins><span class="cx"> return;
</span><span class="cx">
</span><span class="cx"> ASSERT(m_offerAnswerPromise);
</span><span class="lines">@@ -109,16 +109,16 @@
</span><span class="cx"> m_offerAnswerPromise = std::nullopt;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-static inline bool isLocalDescriptionTypeValidForState(RTCSessionDescription::SdpType type, PeerConnectionStates::SignalingState state)
</del><ins>+static inline bool isLocalDescriptionTypeValidForState(RTCSessionDescription::SdpType type, RTCSignalingState state)
</ins><span class="cx"> {
</span><span class="cx"> switch (state) {
</span><del>- case PeerConnectionStates::SignalingState::Stable:
</del><ins>+ case RTCSignalingState::Stable:
</ins><span class="cx"> return type == RTCSessionDescription::SdpType::Offer;
</span><del>- case PeerConnectionStates::SignalingState::HaveLocalOffer:
</del><ins>+ case RTCSignalingState::HaveLocalOffer:
</ins><span class="cx"> return type == RTCSessionDescription::SdpType::Offer;
</span><del>- case PeerConnectionStates::SignalingState::HaveRemoteOffer:
</del><ins>+ case RTCSignalingState::HaveRemoteOffer:
</ins><span class="cx"> return type == RTCSessionDescription::SdpType::Answer || type == RTCSessionDescription::SdpType::Pranswer;
</span><del>- case PeerConnectionStates::SignalingState::HaveLocalPrAnswer:
</del><ins>+ case RTCSignalingState::HaveLocalPranswer:
</ins><span class="cx"> return type == RTCSessionDescription::SdpType::Answer || type == RTCSessionDescription::SdpType::Pranswer;
</span><span class="cx"> default:
</span><span class="cx"> return false;
</span><span class="lines">@@ -130,9 +130,9 @@
</span><span class="cx">
</span><span class="cx"> void PeerConnectionBackend::setLocalDescription(RTCSessionDescription& sessionDescription, DOMPromise<void>&& promise)
</span><span class="cx"> {
</span><del>- ASSERT(m_peerConnection.internalSignalingState() != PeerConnectionStates::SignalingState::Closed);
</del><ins>+ ASSERT(m_peerConnection.signalingState() != RTCSignalingState::Closed);
</ins><span class="cx">
</span><del>- if (!isLocalDescriptionTypeValidForState(sessionDescription.type(), m_peerConnection.internalSignalingState())) {
</del><ins>+ if (!isLocalDescriptionTypeValidForState(sessionDescription.type(), m_peerConnection.signalingState())) {
</ins><span class="cx"> promise.reject(INVALID_STATE_ERR, "Description type incompatible with current signaling state");
</span><span class="cx"> return;
</span><span class="cx"> }
</span><span class="lines">@@ -145,7 +145,7 @@
</span><span class="cx"> {
</span><span class="cx"> ASSERT(isMainThread());
</span><span class="cx">
</span><del>- if (m_peerConnection.internalSignalingState() == PeerConnectionStates::SignalingState::Closed)
</del><ins>+ if (m_peerConnection.signalingState() == RTCSignalingState::Closed)
</ins><span class="cx"> return;
</span><span class="cx">
</span><span class="cx"> ASSERT(m_setDescriptionPromise);
</span><span class="lines">@@ -158,7 +158,7 @@
</span><span class="cx"> {
</span><span class="cx"> ASSERT(isMainThread());
</span><span class="cx">
</span><del>- if (m_peerConnection.internalSignalingState() == PeerConnectionStates::SignalingState::Closed)
</del><ins>+ if (m_peerConnection.signalingState() == RTCSignalingState::Closed)
</ins><span class="cx"> return;
</span><span class="cx">
</span><span class="cx"> ASSERT(m_setDescriptionPromise);
</span><span class="lines">@@ -167,16 +167,16 @@
</span><span class="cx"> m_setDescriptionPromise = std::nullopt;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-static inline bool isRemoteDescriptionTypeValidForState(RTCSessionDescription::SdpType type, PeerConnectionStates::SignalingState state)
</del><ins>+static inline bool isRemoteDescriptionTypeValidForState(RTCSessionDescription::SdpType type, RTCSignalingState state)
</ins><span class="cx"> {
</span><span class="cx"> switch (state) {
</span><del>- case PeerConnectionStates::SignalingState::Stable:
</del><ins>+ case RTCSignalingState::Stable:
</ins><span class="cx"> return type == RTCSessionDescription::SdpType::Offer;
</span><del>- case PeerConnectionStates::SignalingState::HaveLocalOffer:
</del><ins>+ case RTCSignalingState::HaveLocalOffer:
</ins><span class="cx"> return type == RTCSessionDescription::SdpType::Answer || type == RTCSessionDescription::SdpType::Pranswer;
</span><del>- case PeerConnectionStates::SignalingState::HaveRemoteOffer:
</del><ins>+ case RTCSignalingState::HaveRemoteOffer:
</ins><span class="cx"> return type == RTCSessionDescription::SdpType::Offer;
</span><del>- case PeerConnectionStates::SignalingState::HaveRemotePrAnswer:
</del><ins>+ case RTCSignalingState::HaveRemotePranswer:
</ins><span class="cx"> return type == RTCSessionDescription::SdpType::Answer || type == RTCSessionDescription::SdpType::Pranswer;
</span><span class="cx"> default:
</span><span class="cx"> return false;
</span><span class="lines">@@ -188,9 +188,9 @@
</span><span class="cx">
</span><span class="cx"> void PeerConnectionBackend::setRemoteDescription(RTCSessionDescription& sessionDescription, DOMPromise<void>&& promise)
</span><span class="cx"> {
</span><del>- ASSERT(m_peerConnection.internalSignalingState() != PeerConnectionStates::SignalingState::Closed);
</del><ins>+ ASSERT(m_peerConnection.signalingState() != RTCSignalingState::Closed);
</ins><span class="cx">
</span><del>- if (!isRemoteDescriptionTypeValidForState(sessionDescription.type(), m_peerConnection.internalSignalingState())) {
</del><ins>+ if (!isRemoteDescriptionTypeValidForState(sessionDescription.type(), m_peerConnection.signalingState())) {
</ins><span class="cx"> promise.reject(INVALID_STATE_ERR, "Description type incompatible with current signaling state");
</span><span class="cx"> return;
</span><span class="cx"> }
</span><span class="lines">@@ -203,7 +203,7 @@
</span><span class="cx"> {
</span><span class="cx"> ASSERT(isMainThread());
</span><span class="cx">
</span><del>- if (m_peerConnection.internalSignalingState() == PeerConnectionStates::SignalingState::Closed)
</del><ins>+ if (m_peerConnection.signalingState() == RTCSignalingState::Closed)
</ins><span class="cx"> return;
</span><span class="cx">
</span><span class="cx"> ASSERT(m_setDescriptionPromise);
</span><span class="lines">@@ -216,7 +216,7 @@
</span><span class="cx"> {
</span><span class="cx"> ASSERT(isMainThread());
</span><span class="cx">
</span><del>- if (m_peerConnection.internalSignalingState() == PeerConnectionStates::SignalingState::Closed)
</del><ins>+ if (m_peerConnection.signalingState() == RTCSignalingState::Closed)
</ins><span class="cx"> return;
</span><span class="cx">
</span><span class="cx"> ASSERT(m_setDescriptionPromise);
</span><span class="lines">@@ -227,7 +227,7 @@
</span><span class="cx">
</span><span class="cx"> void PeerConnectionBackend::addIceCandidate(RTCIceCandidate& iceCandidate, DOMPromise<void>&& promise)
</span><span class="cx"> {
</span><del>- ASSERT(m_peerConnection.internalSignalingState() != PeerConnectionStates::SignalingState::Closed);
</del><ins>+ ASSERT(m_peerConnection.signalingState() != RTCSignalingState::Closed);
</ins><span class="cx">
</span><span class="cx"> if (iceCandidate.sdpMid().isNull() && !iceCandidate.sdpMLineIndex()) {
</span><span class="cx"> promise.reject(Exception { TypeError, ASCIILiteral("Trying to add a candidate that is missing both sdpMid and sdpMLineIndex") });
</span><span class="lines">@@ -241,7 +241,7 @@
</span><span class="cx"> {
</span><span class="cx"> ASSERT(isMainThread());
</span><span class="cx">
</span><del>- if (m_peerConnection.internalSignalingState() == PeerConnectionStates::SignalingState::Closed)
</del><ins>+ if (m_peerConnection.signalingState() == RTCSignalingState::Closed)
</ins><span class="cx"> return;
</span><span class="cx">
</span><span class="cx"> // FIXME: Update remote description and set ICE connection state to checking if not already done so.
</span><span class="lines">@@ -254,7 +254,7 @@
</span><span class="cx"> void PeerConnectionBackend::addIceCandidateFailed(Exception&& exception)
</span><span class="cx"> {
</span><span class="cx"> ASSERT(isMainThread());
</span><del>- if (m_peerConnection.internalSignalingState() == PeerConnectionStates::SignalingState::Closed)
</del><ins>+ if (m_peerConnection.signalingState() == RTCSignalingState::Closed)
</ins><span class="cx"> return;
</span><span class="cx">
</span><span class="cx"> ASSERT(m_addIceCandidatePromise);
</span><span class="lines">@@ -332,14 +332,14 @@
</span><span class="cx"> ASSERT(isMainThread());
</span><span class="cx">
</span><span class="cx"> m_peerConnection.fireEvent(RTCIceCandidateEvent::create(false, false, nullptr));
</span><del>- m_peerConnection.updateIceGatheringState(PeerConnectionStates::IceGatheringState::Complete);
</del><ins>+ m_peerConnection.updateIceGatheringState(RTCIceGatheringState::Complete);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-void PeerConnectionBackend::updateSignalingState(PeerConnectionStates::SignalingState newSignalingState)
</del><ins>+void PeerConnectionBackend::updateSignalingState(RTCSignalingState newSignalingState)
</ins><span class="cx"> {
</span><span class="cx"> ASSERT(isMainThread());
</span><span class="cx">
</span><del>- if (newSignalingState != m_peerConnection.internalSignalingState()) {
</del><ins>+ if (newSignalingState != m_peerConnection.signalingState()) {
</ins><span class="cx"> m_peerConnection.setSignalingState(newSignalingState);
</span><span class="cx"> m_peerConnection.fireEvent(Event::create(eventNames().signalingstatechangeEvent, false, false));
</span><span class="cx"> }
</span><span class="lines">@@ -361,7 +361,7 @@
</span><span class="cx">
</span><span class="cx"> m_negotiationNeeded = true;
</span><span class="cx">
</span><del>- if (m_peerConnection.internalSignalingState() == PeerConnectionStates::SignalingState::Stable)
</del><ins>+ if (m_peerConnection.signalingState() == RTCSignalingState::Stable)
</ins><span class="cx"> m_peerConnection.scheduleNegotiationNeededEvent();
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCoreModulesmediastreamPeerConnectionBackendh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/mediastream/PeerConnectionBackend.h (214029 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/mediastream/PeerConnectionBackend.h        2017-03-16 05:12:53 UTC (rev 214029)
+++ trunk/Source/WebCore/Modules/mediastream/PeerConnectionBackend.h        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -1,5 +1,6 @@
</span><span class="cx"> /*
</span><span class="cx"> * Copyright (C) 2015 Ericsson AB. All rights reserved.
</span><ins>+ * Copyright (C) 2017 Apple Inc. All rights reserved.
</ins><span class="cx"> *
</span><span class="cx"> * Redistribution and use in source and binary forms, with or without
</span><span class="cx"> * modification, are permitted provided that the following conditions
</span><span class="lines">@@ -33,7 +34,7 @@
</span><span class="cx"> #if ENABLE(WEB_RTC)
</span><span class="cx">
</span><span class="cx"> #include "JSDOMPromise.h"
</span><del>-#include "PeerConnectionStates.h"
</del><ins>+#include "RTCEnums.h"
</ins><span class="cx">
</span><span class="cx"> namespace WebCore {
</span><span class="cx">
</span><span class="lines">@@ -110,7 +111,7 @@
</span><span class="cx"> void fireICECandidateEvent(RefPtr<RTCIceCandidate>&&);
</span><span class="cx"> void doneGatheringCandidates();
</span><span class="cx">
</span><del>- void updateSignalingState(PeerConnectionStates::SignalingState);
</del><ins>+ void updateSignalingState(RTCSignalingState);
</ins><span class="cx">
</span><span class="cx"> void createOfferSucceeded(String&&);
</span><span class="cx"> void createOfferFailed(Exception&&);
</span></span></pre></div>
<a id="trunkSourceWebCoreModulesmediastreamRTCConfigurationh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/mediastream/RTCConfiguration.h (214029 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/mediastream/RTCConfiguration.h        2017-03-16 05:12:53 UTC (rev 214029)
+++ trunk/Source/WebCore/Modules/mediastream/RTCConfiguration.h        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -1,5 +1,6 @@
</span><span class="cx"> /*
</span><span class="cx"> * Copyright (C) 2012 Google Inc. All rights reserved.
</span><ins>+ * Copyright (C) 2017 Apple Inc. All rights reserved.
</ins><span class="cx"> *
</span><span class="cx"> * Redistribution and use in source and binary forms, with or without
</span><span class="cx"> * modification, are permitted provided that the following conditions
</span><span class="lines">@@ -32,21 +33,15 @@
</span><span class="cx">
</span><span class="cx"> #if ENABLE(WEB_RTC)
</span><span class="cx">
</span><del>-#include "PeerConnectionStates.h"
</del><ins>+#include "RTCEnums.h"
</ins><span class="cx"> #include "RTCIceServer.h"
</span><span class="cx">
</span><span class="cx"> namespace WebCore {
</span><span class="cx">
</span><del>-using RTCIceTransportPolicy = PeerConnectionStates::IceTransportPolicy;
-using RTCBundlePolicy = PeerConnectionStates::BundlePolicy;
-
</del><span class="cx"> struct RTCConfiguration {
</span><del>- using IceTransportPolicy = RTCIceTransportPolicy;
- using BundlePolicy = RTCBundlePolicy;
-
</del><span class="cx"> std::optional<Vector<RTCIceServer>> iceServers;
</span><del>- IceTransportPolicy iceTransportPolicy;
- BundlePolicy bundlePolicy;
</del><ins>+ RTCIceTransportPolicy iceTransportPolicy;
+ RTCBundlePolicy bundlePolicy;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCoreModulesmediastreamRTCConfigurationidl"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/mediastream/RTCConfiguration.idl (214029 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/mediastream/RTCConfiguration.idl        2017-03-16 05:12:53 UTC (rev 214029)
+++ trunk/Source/WebCore/Modules/mediastream/RTCConfiguration.idl        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -1,5 +1,5 @@
</span><span class="cx"> /*
</span><del>- * Copyright (C) 2014 Apple Inc. All rights reserved.
</del><ins>+ * Copyright (C) 2014-2017 Apple Inc. All rights reserved.
</ins><span class="cx"> *
</span><span class="cx"> * Redistribution and use in source and binary forms, with or without
</span><span class="cx"> * modification, are permitted provided that the following conditions
</span><span class="lines">@@ -23,14 +23,35 @@
</span><span class="cx"> * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
</span><span class="cx"> */
</span><span class="cx">
</span><del>-enum RTCIceTransportPolicy { "relay", "all" };
-enum RTCBundlePolicy { "balanced", "max-compat", "max-bundle" };
</del><ins>+[
+ Conditional=WEB_RTC,
+ EnabledAtRuntime=PeerConnection,
+ ImplementedAs=RTCIceTransportPolicy
+] enum RTCIceTransportPolicy {
+ "relay",
+ "all"
+};
</ins><span class="cx">
</span><span class="cx"> [
</span><span class="cx"> Conditional=WEB_RTC,
</span><ins>+ EnabledAtRuntime=PeerConnection,
+ ImplementedAs=RTCBundlePolicy
+] enum RTCBundlePolicy {
+ "balanced",
+ "max-compat",
+ "max-bundle"
+};
+
+[
+ Conditional=WEB_RTC,
+ EnabledAtRuntime=PeerConnection,
</ins><span class="cx"> JSGenerateToJSObject,
</span><span class="cx"> ] dictionary RTCConfiguration {
</span><span class="cx"> sequence<RTCIceServer> iceServers;
</span><span class="cx"> RTCIceTransportPolicy iceTransportPolicy = "all";
</span><span class="cx"> RTCBundlePolicy bundlePolicy = "balanced";
</span><ins>+ // FIXME 169662: missing rtcpMuxPolicy
+ // FIXME 169662: missing peerIdentity
+ // FIXME 169662: missing certificates
+ // FIXME 169662: missing iceCandidatePoolSize
</ins><span class="cx"> };
</span></span></pre></div>
<a id="trunkSourceWebCoreModulesmediastreamRTCIceConnectionStateh"></a>
<div class="addfile"><h4>Added: trunk/Source/WebCore/Modules/mediastream/RTCIceConnectionState.h (0 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/mediastream/RTCIceConnectionState.h         (rev 0)
+++ trunk/Source/WebCore/Modules/mediastream/RTCIceConnectionState.h        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -0,0 +1,28 @@
</span><ins>+/*
+ * Copyright (C) 2017 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ * THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#pragma once
+
+#include "PeerConnectionStates.h"
</ins></span></pre></div>
<a id="trunkSourceWebCoreModulesmediastreamRTCIceConnectionStateidl"></a>
<div class="addfile"><h4>Added: trunk/Source/WebCore/Modules/mediastream/RTCIceConnectionState.idl (0 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/mediastream/RTCIceConnectionState.idl         (rev 0)
+++ trunk/Source/WebCore/Modules/mediastream/RTCIceConnectionState.idl        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -0,0 +1,37 @@
</span><ins>+/*
+ * Copyright (C) 2017 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ * THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+[
+ Conditional=WEB_RTC,
+ EnabledAtRuntime=PeerConnection
+] enum RTCIceConnectionState {
+ "new",
+ "checking",
+ "connected",
+ "completed",
+ "failed",
+ "disconnected",
+ "closed"
+};
</ins></span></pre></div>
<a id="trunkSourceWebCoreModulesmediastreamRTCIceGatheringStateh"></a>
<div class="addfile"><h4>Added: trunk/Source/WebCore/Modules/mediastream/RTCIceGatheringState.h (0 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/mediastream/RTCIceGatheringState.h         (rev 0)
+++ trunk/Source/WebCore/Modules/mediastream/RTCIceGatheringState.h        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -0,0 +1,28 @@
</span><ins>+/*
+ * Copyright (C) 2017 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ * THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#pragma once
+
+#include "PeerConnectionStates.h"
</ins></span></pre></div>
<a id="trunkSourceWebCoreModulesmediastreamRTCIceGatheringStateidl"></a>
<div class="addfile"><h4>Added: trunk/Source/WebCore/Modules/mediastream/RTCIceGatheringState.idl (0 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/mediastream/RTCIceGatheringState.idl         (rev 0)
+++ trunk/Source/WebCore/Modules/mediastream/RTCIceGatheringState.idl        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -0,0 +1,33 @@
</span><ins>+/*
+ * Copyright (C) 2017 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ * THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+[
+ Conditional=WEB_RTC,
+ EnabledAtRuntime=PeerConnection
+] enum RTCIceGatheringState {
+ "new",
+ "gathering",
+ "complete"
+};
</ins></span></pre></div>
<a id="trunkSourceWebCoreModulesmediastreamRTCIceTransporth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/mediastream/RTCIceTransport.h (214029 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/mediastream/RTCIceTransport.h        2017-03-16 05:12:53 UTC (rev 214029)
+++ trunk/Source/WebCore/Modules/mediastream/RTCIceTransport.h        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -1,5 +1,6 @@
</span><span class="cx"> /*
</span><span class="cx"> * Copyright (C) 2016 Ericsson AB. All rights reserved.
</span><ins>+ * Copyright (C) 2017 Apple Inc. All rights reserved.
</ins><span class="cx"> *
</span><span class="cx"> * Redistribution and use in source and binary forms, with or without
</span><span class="cx"> * modification, are permitted provided that the following conditions
</span><span class="lines">@@ -32,7 +33,7 @@
</span><span class="cx">
</span><span class="cx"> #if ENABLE(WEB_RTC)
</span><span class="cx">
</span><del>-#include "PeerConnectionStates.h"
</del><ins>+#include "RTCEnums.h"
</ins><span class="cx"> #include "ScriptWrappable.h"
</span><span class="cx"> #include <wtf/RefCounted.h>
</span><span class="cx"> #include <wtf/RefPtr.h>
</span><span class="lines">@@ -41,10 +42,6 @@
</span><span class="cx">
</span><span class="cx"> class RTCIceTransport : public RefCounted<RTCIceTransport>, public ScriptWrappable {
</span><span class="cx"> public:
</span><del>-
- using TransportState = PeerConnectionStates::IceTransportState;
- using GatheringState = PeerConnectionStates::IceGatheringState;
-
</del><span class="cx"> static Ref<RTCIceTransport> create()
</span><span class="cx"> {
</span><span class="cx"> return adoptRef(*new RTCIceTransport());
</span><span class="lines">@@ -51,17 +48,17 @@
</span><span class="cx"> }
</span><span class="cx"> virtual ~RTCIceTransport() { }
</span><span class="cx">
</span><del>- TransportState transportState() const { return m_transportState; }
- void setTransportState(TransportState state) { m_transportState = state; }
</del><ins>+ RTCIceTransportState transportState() const { return m_transportState; }
+ void setTransportState(RTCIceTransportState state) { m_transportState = state; }
</ins><span class="cx">
</span><del>- GatheringState gatheringState() const { return m_gatheringState; }
- void setGatheringState(GatheringState state) { m_gatheringState = state; }
</del><ins>+ RTCIceGatheringState gatheringState() const { return m_gatheringState; }
+ void setGatheringState(RTCIceGatheringState state) { m_gatheringState = state; }
</ins><span class="cx">
</span><span class="cx"> private:
</span><span class="cx"> RTCIceTransport() { };
</span><span class="cx">
</span><del>- TransportState m_transportState { TransportState::New };
- GatheringState m_gatheringState { GatheringState::New };
</del><ins>+ RTCIceTransportState m_transportState { RTCIceTransportState::New };
+ RTCIceGatheringState m_gatheringState { RTCIceGatheringState::New };
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCoreModulesmediastreamRTCPeerConnectioncpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/mediastream/RTCPeerConnection.cpp (214029 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/mediastream/RTCPeerConnection.cpp        2017-03-16 05:12:53 UTC (rev 214029)
+++ trunk/Source/WebCore/Modules/mediastream/RTCPeerConnection.cpp        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -58,7 +58,6 @@
</span><span class="cx"> namespace WebCore {
</span><span class="cx">
</span><span class="cx"> using namespace PeerConnection;
</span><del>-using namespace PeerConnectionStates;
</del><span class="cx">
</span><span class="cx"> Ref<RTCPeerConnection> RTCPeerConnection::create(ScriptExecutionContext& context)
</span><span class="cx"> {
</span><span class="lines">@@ -66,7 +65,7 @@
</span><span class="cx"> peerConnection->suspendIfNeeded();
</span><span class="cx"> // RTCPeerConnection may send events at about any time during its lifetime.
</span><span class="cx"> // Let's make it uncollectable until the pc is closed by JS or the page stops it.
</span><del>- if (peerConnection->m_signalingState != SignalingState::Closed) {
</del><ins>+ if (peerConnection->m_signalingState != RTCSignalingState::Closed) {
</ins><span class="cx"> peerConnection->setPendingActivity(peerConnection.ptr());
</span><span class="cx"> peerConnection->registerToController();
</span><span class="cx"> }
</span><span class="lines">@@ -97,7 +96,7 @@
</span><span class="cx">
</span><span class="cx"> ExceptionOr<Ref<RTCRtpSender>> RTCPeerConnection::addTrack(Ref<MediaStreamTrack>&& track, const Vector<std::reference_wrapper<MediaStream>>& streams)
</span><span class="cx"> {
</span><del>- if (m_signalingState == SignalingState::Closed)
</del><ins>+ if (m_signalingState == RTCSignalingState::Closed)
</ins><span class="cx"> return Exception { INVALID_STATE_ERR };
</span><span class="cx">
</span><span class="cx"> // Require at least one stream until https://github.com/w3c/webrtc-pc/issues/288 is resolved
</span><span class="lines">@@ -153,7 +152,7 @@
</span><span class="cx">
</span><span class="cx"> ExceptionOr<void> RTCPeerConnection::removeTrack(RTCRtpSender& sender)
</span><span class="cx"> {
</span><del>- if (m_signalingState == SignalingState::Closed)
</del><ins>+ if (m_signalingState == RTCSignalingState::Closed)
</ins><span class="cx"> return Exception { INVALID_STATE_ERR };
</span><span class="cx">
</span><span class="cx"> bool shouldAbort = true;
</span><span class="lines">@@ -174,7 +173,7 @@
</span><span class="cx">
</span><span class="cx"> ExceptionOr<Ref<RTCRtpTransceiver>> RTCPeerConnection::addTransceiver(Ref<MediaStreamTrack>&& track, const RTCRtpTransceiverInit& init)
</span><span class="cx"> {
</span><del>- if (m_signalingState == SignalingState::Closed)
</del><ins>+ if (m_signalingState == RTCSignalingState::Closed)
</ins><span class="cx"> return Exception { INVALID_STATE_ERR };
</span><span class="cx">
</span><span class="cx"> String transceiverMid = RTCRtpTransceiver::getNextMid();
</span><span class="lines">@@ -192,7 +191,7 @@
</span><span class="cx">
</span><span class="cx"> ExceptionOr<Ref<RTCRtpTransceiver>> RTCPeerConnection::addTransceiver(const String& kind, const RTCRtpTransceiverInit& init)
</span><span class="cx"> {
</span><del>- if (m_signalingState == SignalingState::Closed)
</del><ins>+ if (m_signalingState == RTCSignalingState::Closed)
</ins><span class="cx"> return Exception { INVALID_STATE_ERR };
</span><span class="cx">
</span><span class="cx"> if (kind != "audio" && kind != "video")
</span><span class="lines">@@ -220,7 +219,7 @@
</span><span class="cx">
</span><span class="cx"> void RTCPeerConnection::queuedCreateOffer(RTCOfferOptions&& options, SessionDescriptionPromise&& promise)
</span><span class="cx"> {
</span><del>- if (m_signalingState == SignalingState::Closed) {
</del><ins>+ if (m_signalingState == RTCSignalingState::Closed) {
</ins><span class="cx"> promise.reject(INVALID_STATE_ERR);
</span><span class="cx"> return;
</span><span class="cx"> }
</span><span class="lines">@@ -230,7 +229,7 @@
</span><span class="cx">
</span><span class="cx"> void RTCPeerConnection::queuedCreateAnswer(RTCAnswerOptions&& options, SessionDescriptionPromise&& promise)
</span><span class="cx"> {
</span><del>- if (m_signalingState == SignalingState::Closed) {
</del><ins>+ if (m_signalingState == RTCSignalingState::Closed) {
</ins><span class="cx"> promise.reject(INVALID_STATE_ERR);
</span><span class="cx"> return;
</span><span class="cx"> }
</span><span class="lines">@@ -240,7 +239,7 @@
</span><span class="cx">
</span><span class="cx"> void RTCPeerConnection::queuedSetLocalDescription(RTCSessionDescription& description, DOMPromise<void>&& promise)
</span><span class="cx"> {
</span><del>- if (m_signalingState == SignalingState::Closed) {
</del><ins>+ if (m_signalingState == RTCSignalingState::Closed) {
</ins><span class="cx"> promise.reject(INVALID_STATE_ERR);
</span><span class="cx"> return;
</span><span class="cx"> }
</span><span class="lines">@@ -265,7 +264,7 @@
</span><span class="cx">
</span><span class="cx"> void RTCPeerConnection::queuedSetRemoteDescription(RTCSessionDescription& description, DOMPromise<void>&& promise)
</span><span class="cx"> {
</span><del>- if (m_signalingState == SignalingState::Closed) {
</del><ins>+ if (m_signalingState == RTCSignalingState::Closed) {
</ins><span class="cx"> promise.reject(INVALID_STATE_ERR);
</span><span class="cx"> return;
</span><span class="cx"> }
</span><span class="lines">@@ -290,7 +289,7 @@
</span><span class="cx">
</span><span class="cx"> void RTCPeerConnection::queuedAddIceCandidate(RTCIceCandidate& rtcCandidate, DOMPromise<void>&& promise)
</span><span class="cx"> {
</span><del>- if (m_signalingState == SignalingState::Closed) {
</del><ins>+ if (m_signalingState == RTCSignalingState::Closed) {
</ins><span class="cx"> promise.reject(INVALID_STATE_ERR);
</span><span class="cx"> return;
</span><span class="cx"> }
</span><span class="lines">@@ -298,68 +297,9 @@
</span><span class="cx"> m_backend->addIceCandidate(rtcCandidate, WTFMove(promise));
</span><span class="cx"> }
</span><span class="cx">
</span><del>-String RTCPeerConnection::signalingState() const
-{
- switch (m_signalingState) {
- case SignalingState::Stable:
- return ASCIILiteral("stable");
- case SignalingState::HaveLocalOffer:
- return ASCIILiteral("have-local-offer");
- case SignalingState::HaveRemoteOffer:
- return ASCIILiteral("have-remote-offer");
- case SignalingState::HaveLocalPrAnswer:
- return ASCIILiteral("have-local-pranswer");
- case SignalingState::HaveRemotePrAnswer:
- return ASCIILiteral("have-remote-pranswer");
- case SignalingState::Closed:
- return ASCIILiteral("closed");
- }
-
- ASSERT_NOT_REACHED();
- return String();
-}
-
-String RTCPeerConnection::iceGatheringState() const
-{
- switch (m_iceGatheringState) {
- case IceGatheringState::New:
- return ASCIILiteral("new");
- case IceGatheringState::Gathering:
- return ASCIILiteral("gathering");
- case IceGatheringState::Complete:
- return ASCIILiteral("complete");
- }
-
- ASSERT_NOT_REACHED();
- return String();
-}
-
-String RTCPeerConnection::iceConnectionState() const
-{
- switch (m_iceConnectionState) {
- case IceConnectionState::New:
- return ASCIILiteral("new");
- case IceConnectionState::Checking:
- return ASCIILiteral("checking");
- case IceConnectionState::Connected:
- return ASCIILiteral("connected");
- case IceConnectionState::Completed:
- return ASCIILiteral("completed");
- case IceConnectionState::Failed:
- return ASCIILiteral("failed");
- case IceConnectionState::Disconnected:
- return ASCIILiteral("disconnected");
- case IceConnectionState::Closed:
- return ASCIILiteral("closed");
- }
-
- ASSERT_NOT_REACHED();
- return String();
-}
-
</del><span class="cx"> ExceptionOr<void> RTCPeerConnection::setConfiguration(RTCConfiguration&& configuration)
</span><span class="cx"> {
</span><del>- if (m_signalingState == SignalingState::Closed)
</del><ins>+ if (m_signalingState == RTCSignalingState::Closed)
</ins><span class="cx"> return Exception { INVALID_STATE_ERR };
</span><span class="cx">
</span><span class="cx"> Vector<MediaEndpointConfiguration::IceServerInfo> servers;
</span><span class="lines">@@ -398,7 +338,7 @@
</span><span class="cx">
</span><span class="cx"> ExceptionOr<Ref<RTCDataChannel>> RTCPeerConnection::createDataChannel(ScriptExecutionContext& context, String&& label, RTCDataChannelInit&& options)
</span><span class="cx"> {
</span><del>- if (m_signalingState == SignalingState::Closed)
</del><ins>+ if (m_signalingState == RTCSignalingState::Closed)
</ins><span class="cx"> return Exception { INVALID_STATE_ERR };
</span><span class="cx">
</span><span class="cx"> // FIXME: Check options
</span><span class="lines">@@ -411,13 +351,13 @@
</span><span class="cx">
</span><span class="cx"> void RTCPeerConnection::close()
</span><span class="cx"> {
</span><del>- if (m_signalingState == SignalingState::Closed)
</del><ins>+ if (m_signalingState == RTCSignalingState::Closed)
</ins><span class="cx"> return;
</span><span class="cx">
</span><span class="cx"> m_backend->stop();
</span><span class="cx">
</span><del>- m_iceConnectionState = IceConnectionState::Closed;
- m_signalingState = SignalingState::Closed;
</del><ins>+ m_iceConnectionState = RTCIceConnectionState::Closed;
+ m_signalingState = RTCSignalingState::Closed;
</ins><span class="cx">
</span><span class="cx"> for (RTCRtpSender& sender : m_transceiverSet->senders())
</span><span class="cx"> sender.stop();
</span><span class="lines">@@ -470,15 +410,15 @@
</span><span class="cx"> m_transceiverSet->append(WTFMove(transceiver));
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void RTCPeerConnection::setSignalingState(SignalingState newState)
</del><ins>+void RTCPeerConnection::setSignalingState(RTCSignalingState newState)
</ins><span class="cx"> {
</span><span class="cx"> m_signalingState = newState;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void RTCPeerConnection::updateIceGatheringState(IceGatheringState newState)
</del><ins>+void RTCPeerConnection::updateIceGatheringState(RTCIceGatheringState newState)
</ins><span class="cx"> {
</span><span class="cx"> scriptExecutionContext()->postTask([protectedThis = makeRef(*this), newState](ScriptExecutionContext&) {
</span><del>- if (protectedThis->m_signalingState == SignalingState::Closed || protectedThis->m_iceGatheringState == newState)
</del><ins>+ if (protectedThis->m_signalingState == RTCSignalingState::Closed || protectedThis->m_iceGatheringState == newState)
</ins><span class="cx"> return;
</span><span class="cx">
</span><span class="cx"> protectedThis->m_iceGatheringState = newState;
</span><span class="lines">@@ -486,10 +426,10 @@
</span><span class="cx"> });
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void RTCPeerConnection::updateIceConnectionState(IceConnectionState newState)
</del><ins>+void RTCPeerConnection::updateIceConnectionState(RTCIceConnectionState newState)
</ins><span class="cx"> {
</span><span class="cx"> scriptExecutionContext()->postTask([protectedThis = makeRef(*this), newState](ScriptExecutionContext&) {
</span><del>- if (protectedThis->m_signalingState == SignalingState::Closed || protectedThis->m_iceConnectionState == newState)
</del><ins>+ if (protectedThis->m_signalingState == RTCSignalingState::Closed || protectedThis->m_iceConnectionState == newState)
</ins><span class="cx"> return;
</span><span class="cx">
</span><span class="cx"> protectedThis->m_iceConnectionState = newState;
</span><span class="lines">@@ -500,7 +440,7 @@
</span><span class="cx"> void RTCPeerConnection::scheduleNegotiationNeededEvent()
</span><span class="cx"> {
</span><span class="cx"> scriptExecutionContext()->postTask([protectedThis = makeRef(*this)](ScriptExecutionContext&) {
</span><del>- if (protectedThis->m_signalingState == SignalingState::Closed)
</del><ins>+ if (protectedThis->m_signalingState == RTCSignalingState::Closed)
</ins><span class="cx"> return;
</span><span class="cx"> if (!protectedThis->m_backend->isNegotiationNeeded())
</span><span class="cx"> return;
</span></span></pre></div>
<a id="trunkSourceWebCoreModulesmediastreamRTCPeerConnectionh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/mediastream/RTCPeerConnection.h (214029 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/mediastream/RTCPeerConnection.h        2017-03-16 05:12:53 UTC (rev 214029)
+++ trunk/Source/WebCore/Modules/mediastream/RTCPeerConnection.h        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -38,11 +38,9 @@
</span><span class="cx"> #include "ActiveDOMObject.h"
</span><span class="cx"> #include "EventTarget.h"
</span><span class="cx"> #include "MediaStream.h"
</span><del>-#include "RTCAnswerOptions.h"
</del><span class="cx"> #include "RTCConfiguration.h"
</span><span class="cx"> #include "RTCDataChannel.h"
</span><span class="cx"> #include "RTCEnums.h"
</span><del>-#include "RTCOfferOptions.h"
</del><span class="cx"> #include "RTCRtpTransceiver.h"
</span><span class="cx">
</span><span class="cx"> namespace WebCore {
</span><span class="lines">@@ -55,6 +53,8 @@
</span><span class="cx"> class RTCSessionDescription;
</span><span class="cx"> class RTCStatsCallback;
</span><span class="cx">
</span><ins>+struct RTCAnswerOptions;
+struct RTCOfferOptions;
</ins><span class="cx"> struct RTCRtpTransceiverInit {
</span><span class="cx"> RTCRtpTransceiverDirection direction;
</span><span class="cx"> };
</span><span class="lines">@@ -64,10 +64,7 @@
</span><span class="cx"> static Ref<RTCPeerConnection> create(ScriptExecutionContext&);
</span><span class="cx"> virtual ~RTCPeerConnection();
</span><span class="cx">
</span><del>- using AnswerOptions = RTCAnswerOptions;
</del><span class="cx"> using DataChannelInit = RTCDataChannelInit;
</span><del>- using OfferAnswerOptions = RTCOfferAnswerOptions;
- using OfferOptions = RTCOfferOptions;
</del><span class="cx">
</span><span class="cx"> ExceptionOr<void> initializeWith(Document&, RTCConfiguration&&);
</span><span class="cx">
</span><span class="lines">@@ -97,12 +94,12 @@
</span><span class="cx"> RefPtr<RTCSessionDescription> currentRemoteDescription() const;
</span><span class="cx"> RefPtr<RTCSessionDescription> pendingRemoteDescription() const;
</span><span class="cx">
</span><del>- String signalingState() const;
</del><ins>+ RTCSignalingState signalingState() const { return m_signalingState; }
</ins><span class="cx">
</span><span class="cx"> void queuedAddIceCandidate(RTCIceCandidate&, DOMPromise<void>&&);
</span><span class="cx">
</span><del>- String iceGatheringState() const;
- String iceConnectionState() const;
</del><ins>+ RTCIceGatheringState iceGatheringState() const { return m_iceGatheringState; }
+ RTCIceConnectionState iceConnectionState() const { return m_iceConnectionState; }
</ins><span class="cx">
</span><span class="cx"> const RTCConfiguration& getConfiguration() const { return m_configuration; }
</span><span class="cx"> ExceptionOr<void> setConfiguration(RTCConfiguration&&);
</span><span class="lines">@@ -125,17 +122,14 @@
</span><span class="cx">
</span><span class="cx"> // API used by PeerConnectionBackend and relatives
</span><span class="cx"> void addTransceiver(Ref<RTCRtpTransceiver>&&);
</span><del>- void setSignalingState(PeerConnectionStates::SignalingState);
- void updateIceGatheringState(PeerConnectionStates::IceGatheringState);
- void updateIceConnectionState(PeerConnectionStates::IceConnectionState);
</del><ins>+ void setSignalingState(RTCSignalingState);
+ void updateIceGatheringState(RTCIceGatheringState);
+ void updateIceConnectionState(RTCIceConnectionState);
</ins><span class="cx">
</span><span class="cx"> void scheduleNegotiationNeededEvent();
</span><span class="cx">
</span><span class="cx"> RTCRtpSenderClient& senderClient() { return *this; }
</span><span class="cx"> void fireEvent(Event&);
</span><del>- PeerConnectionStates::SignalingState internalSignalingState() const { return m_signalingState; }
- PeerConnectionStates::IceGatheringState internalIceGatheringState() const { return m_iceGatheringState; }
- PeerConnectionStates::IceConnectionState internalIceConnectionState() const { return m_iceConnectionState; }
</del><span class="cx">
</span><span class="cx"> void disableICECandidateFiltering() { m_backend->disableICECandidateFiltering(); }
</span><span class="cx"> void enableICECandidateFiltering() { m_backend->enableICECandidateFiltering(); }
</span><span class="lines">@@ -161,9 +155,9 @@
</span><span class="cx"> // RTCRtpSenderClient
</span><span class="cx"> void replaceTrack(RTCRtpSender&, Ref<MediaStreamTrack>&&, DOMPromise<void>&&) final;
</span><span class="cx">
</span><del>- PeerConnectionStates::SignalingState m_signalingState { PeerConnectionStates::SignalingState::Stable };
- PeerConnectionStates::IceGatheringState m_iceGatheringState { PeerConnectionStates::IceGatheringState::New };
- PeerConnectionStates::IceConnectionState m_iceConnectionState { PeerConnectionStates::IceConnectionState::New };
</del><ins>+ RTCSignalingState m_signalingState { RTCSignalingState::Stable };
+ RTCIceGatheringState m_iceGatheringState { RTCIceGatheringState::New };
+ RTCIceConnectionState m_iceConnectionState { RTCIceConnectionState::New };
</ins><span class="cx">
</span><span class="cx"> std::unique_ptr<RtpTransceiverSet> m_transceiverSet { std::unique_ptr<RtpTransceiverSet>(new RtpTransceiverSet()) };
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCoreModulesmediastreamRTCPeerConnectionidl"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/mediastream/RTCPeerConnection.idl (214029 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/mediastream/RTCPeerConnection.idl        2017-03-16 05:12:53 UTC (rev 214029)
+++ trunk/Source/WebCore/Modules/mediastream/RTCPeerConnection.idl        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -92,12 +92,9 @@
</span><span class="cx"> // FIXME 169644: update parameter to (RTCIceCandidateInit or RTCIceCandidate)
</span><span class="cx"> [JSBuiltin] Promise<void> addIceCandidate(RTCIceCandidate candidate);
</span><span class="cx">
</span><del>- // FIXME 169644: convert to enum
- readonly attribute DOMString signalingState;
- // FIXME 169644: convert to enum
- readonly attribute DOMString iceGatheringState;
- // FIXME 169644: convert to enum
- readonly attribute DOMString iceConnectionState;
</del><ins>+ readonly attribute RTCSignalingState signalingState;
+ readonly attribute RTCIceGatheringState iceGatheringState;
+ readonly attribute RTCIceConnectionState iceConnectionState;
</ins><span class="cx">
</span><span class="cx"> // FIXME 169644: missing connectionState
</span><span class="cx"> // FIXME 169644: missing canTrickleIceCandidates
</span></span></pre></div>
<a id="trunkSourceWebCoreModulesmediastreamRTCSignalingStateh"></a>
<div class="addfile"><h4>Added: trunk/Source/WebCore/Modules/mediastream/RTCSignalingState.h (0 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/mediastream/RTCSignalingState.h         (rev 0)
+++ trunk/Source/WebCore/Modules/mediastream/RTCSignalingState.h        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -0,0 +1,28 @@
</span><ins>+/*
+ * Copyright (C) 2017 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ * THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#pragma once
+
+#include "PeerConnectionStates.h"
</ins></span></pre></div>
<a id="trunkSourceWebCoreModulesmediastreamRTCSignalingStateidl"></a>
<div class="addfile"><h4>Added: trunk/Source/WebCore/Modules/mediastream/RTCSignalingState.idl (0 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/mediastream/RTCSignalingState.idl         (rev 0)
+++ trunk/Source/WebCore/Modules/mediastream/RTCSignalingState.idl        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -0,0 +1,35 @@
</span><ins>+/*
+ * Copyright (C) 2017 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ * THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+[
+ Conditional=WEB_RTC,
+ EnabledAtRuntime=PeerConnection
+] enum RTCSignalingState {
+ "stable",
+ "have-local-offer",
+ "have-remote-offer",
+ "have-local-pranswer",
+ "have-remote-pranswer"
+};
</ins></span></pre></div>
<a id="trunkSourceWebCoreModulesmediastreamlibwebrtcLibWebRTCMediaEndpointcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.cpp (214029 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.cpp        2017-03-16 05:12:53 UTC (rev 214029)
+++ trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.cpp        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -1,5 +1,5 @@
</span><span class="cx"> /*
</span><del>- * Copyright (C) 2017 Apple Inc.
</del><ins>+ * Copyright (C) 2017 Apple Inc. All rights reserved.
</ins><span class="cx"> *
</span><span class="cx"> * Redistribution and use in source and binary forms, with or without
</span><span class="cx"> * modification, are permitted provided that the following conditions
</span><span class="lines">@@ -38,6 +38,7 @@
</span><span class="cx"> #include "PlatformStrategies.h"
</span><span class="cx"> #include "RTCDataChannel.h"
</span><span class="cx"> #include "RTCDataChannelEvent.h"
</span><ins>+#include "RTCEnums.h"
</ins><span class="cx"> #include "RTCPeerConnection.h"
</span><span class="cx"> #include "RTCSessionDescription.h"
</span><span class="cx"> #include "RTCStatsReport.h"
</span><span class="lines">@@ -348,21 +349,21 @@
</span><span class="cx"> });
</span><span class="cx"> }
</span><span class="cx">
</span><del>-static PeerConnectionStates::SignalingState signalingState(webrtc::PeerConnectionInterface::SignalingState state)
</del><ins>+static RTCSignalingState signalingState(webrtc::PeerConnectionInterface::SignalingState state)
</ins><span class="cx"> {
</span><span class="cx"> switch (state) {
</span><span class="cx"> case webrtc::PeerConnectionInterface::kStable:
</span><del>- return PeerConnectionStates::SignalingState::Stable;
</del><ins>+ return RTCSignalingState::Stable;
</ins><span class="cx"> case webrtc::PeerConnectionInterface::kHaveLocalOffer:
</span><del>- return PeerConnectionStates::SignalingState::HaveLocalOffer;
</del><ins>+ return RTCSignalingState::HaveLocalOffer;
</ins><span class="cx"> case webrtc::PeerConnectionInterface::kHaveLocalPrAnswer:
</span><del>- return PeerConnectionStates::SignalingState::HaveLocalPrAnswer;
</del><ins>+ return RTCSignalingState::HaveLocalPranswer;
</ins><span class="cx"> case webrtc::PeerConnectionInterface::kHaveRemoteOffer:
</span><del>- return PeerConnectionStates::SignalingState::HaveRemoteOffer;
</del><ins>+ return RTCSignalingState::HaveRemoteOffer;
</ins><span class="cx"> case webrtc::PeerConnectionInterface::kHaveRemotePrAnswer:
</span><del>- return PeerConnectionStates::SignalingState::HaveRemotePrAnswer;
</del><ins>+ return RTCSignalingState::HaveRemotePranswer;
</ins><span class="cx"> case webrtc::PeerConnectionInterface::kClosed:
</span><del>- return PeerConnectionStates::SignalingState::Closed;
</del><ins>+ return RTCSignalingState::Closed;
</ins><span class="cx"> }
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -495,36 +496,36 @@
</span><span class="cx"> });
</span><span class="cx"> }
</span><span class="cx">
</span><del>-static inline PeerConnectionStates::IceConnectionState iceConnectionState(webrtc::PeerConnectionInterface::IceConnectionState state)
</del><ins>+static inline RTCIceConnectionState toRTCIceConnectionState(webrtc::PeerConnectionInterface::IceConnectionState state)
</ins><span class="cx"> {
</span><span class="cx"> switch (state) {
</span><span class="cx"> case webrtc::PeerConnectionInterface::kIceConnectionNew:
</span><del>- return PeerConnectionStates::IceConnectionState::New;
</del><ins>+ return RTCIceConnectionState::New;
</ins><span class="cx"> case webrtc::PeerConnectionInterface::kIceConnectionChecking:
</span><del>- return PeerConnectionStates::IceConnectionState::Checking;
</del><ins>+ return RTCIceConnectionState::Checking;
</ins><span class="cx"> case webrtc::PeerConnectionInterface::kIceConnectionConnected:
</span><del>- return PeerConnectionStates::IceConnectionState::Connected;
</del><ins>+ return RTCIceConnectionState::Connected;
</ins><span class="cx"> case webrtc::PeerConnectionInterface::kIceConnectionCompleted:
</span><del>- return PeerConnectionStates::IceConnectionState::Completed;
</del><ins>+ return RTCIceConnectionState::Completed;
</ins><span class="cx"> case webrtc::PeerConnectionInterface::kIceConnectionFailed:
</span><del>- return PeerConnectionStates::IceConnectionState::Failed;
</del><ins>+ return RTCIceConnectionState::Failed;
</ins><span class="cx"> case webrtc::PeerConnectionInterface::kIceConnectionDisconnected:
</span><del>- return PeerConnectionStates::IceConnectionState::Disconnected;
</del><ins>+ return RTCIceConnectionState::Disconnected;
</ins><span class="cx"> case webrtc::PeerConnectionInterface::kIceConnectionClosed:
</span><del>- return PeerConnectionStates::IceConnectionState::Closed;
</del><ins>+ return RTCIceConnectionState::Closed;
</ins><span class="cx"> case webrtc::PeerConnectionInterface::kIceConnectionMax:
</span><span class="cx"> ASSERT_NOT_REACHED();
</span><del>- return PeerConnectionStates::IceConnectionState::New;
</del><ins>+ return RTCIceConnectionState::New;
</ins><span class="cx"> }
</span><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> void LibWebRTCMediaEndpoint::OnIceConnectionChange(webrtc::PeerConnectionInterface::IceConnectionState state)
</span><span class="cx"> {
</span><del>- auto connectionState = iceConnectionState(state);
</del><ins>+ auto connectionState = toRTCIceConnectionState(state);
</ins><span class="cx"> callOnMainThread([protectedThis = makeRef(*this), connectionState] {
</span><span class="cx"> if (protectedThis->isStopped())
</span><span class="cx"> return;
</span><del>- if (protectedThis->m_peerConnectionBackend.connection().internalIceConnectionState() != connectionState)
</del><ins>+ if (protectedThis->m_peerConnectionBackend.connection().iceConnectionState() != connectionState)
</ins><span class="cx"> protectedThis->m_peerConnectionBackend.connection().updateIceConnectionState(connectionState);
</span><span class="cx"> });
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCoreModulesmediastreamlibwebrtcLibWebRTCPeerConnectionBackendcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.cpp (214029 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.cpp        2017-03-16 05:12:53 UTC (rev 214029)
+++ trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.cpp        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -73,7 +73,7 @@
</span><span class="cx"> {
</span><span class="cx"> webrtc::PeerConnectionInterface::RTCConfiguration rtcConfiguration;
</span><span class="cx">
</span><del>- if (configuration.iceTransportPolicy == PeerConnectionStates::IceTransportPolicy::Relay)
</del><ins>+ if (configuration.iceTransportPolicy == RTCIceTransportPolicy::Relay)
</ins><span class="cx"> rtcConfiguration.type = webrtc::PeerConnectionInterface::kRelay;
</span><span class="cx">
</span><span class="cx"> // FIXME: Support PeerConnectionStates::BundlePolicy::MaxBundle.
</span><span class="lines">@@ -80,7 +80,7 @@
</span><span class="cx"> // LibWebRTC does not like it and will fail to set any configuration field otherwise.
</span><span class="cx"> // See https://bugs.webkit.org/show_bug.cgi?id=169389.
</span><span class="cx">
</span><del>- if (configuration.bundlePolicy == PeerConnectionStates::BundlePolicy::MaxCompat)
</del><ins>+ if (configuration.bundlePolicy == RTCBundlePolicy::MaxCompat)
</ins><span class="cx"> rtcConfiguration.bundle_policy = webrtc::PeerConnectionInterface::kBundlePolicyMaxCompat;
</span><span class="cx">
</span><span class="cx"> for (auto& server : configuration.iceServers) {
</span></span></pre></div>
<a id="trunkSourceWebCoreWebCorexcodeprojprojectpbxproj"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj (214029 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj        2017-03-16 05:12:53 UTC (rev 214029)
+++ trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -1426,6 +1426,15 @@
</span><span class="cx">                 316DCB221E78CA55001B5F87 /* JSRTCRtpTransceiverDirection.h in Headers */ = {isa = PBXBuildFile; fileRef = 316DCB1C1E78CA55001B5F87 /* JSRTCRtpTransceiverDirection.h */; };
</span><span class="cx">                 316DCB311E78FB6C001B5F87 /* JSRTCAnswerOptions.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 316DCB2D1E78F496001B5F87 /* JSRTCAnswerOptions.cpp */; };
</span><span class="cx">                 316DCB321E78FB70001B5F87 /* JSRTCOfferOptions.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 316DCB2F1E78F496001B5F87 /* JSRTCOfferOptions.cpp */; };
</span><ins>+                316DCB371E790E1B001B5F87 /* RTCIceGatheringState.h in Headers */ = {isa = PBXBuildFile; fileRef = 316DCB341E790E1B001B5F87 /* RTCIceGatheringState.h */; };
+                316DCB3D1E790E2C001B5F87 /* RTCIceConnectionState.h in Headers */ = {isa = PBXBuildFile; fileRef = 316DCB3A1E790E2C001B5F87 /* RTCIceConnectionState.h */; };
+                316DCB431E790E3C001B5F87 /* RTCSignalingState.h in Headers */ = {isa = PBXBuildFile; fileRef = 316DCB401E790E3C001B5F87 /* RTCSignalingState.h */; };
+                316DCB4B1E7910A6001B5F87 /* JSRTCIceConnectionState.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 316DCB451E7910A6001B5F87 /* JSRTCIceConnectionState.cpp */; };
+                316DCB4C1E7910A6001B5F87 /* JSRTCIceConnectionState.h in Headers */ = {isa = PBXBuildFile; fileRef = 316DCB461E7910A6001B5F87 /* JSRTCIceConnectionState.h */; };
+                316DCB4D1E7910A6001B5F87 /* JSRTCIceGatheringState.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 316DCB471E7910A6001B5F87 /* JSRTCIceGatheringState.cpp */; };
+                316DCB4E1E7910A6001B5F87 /* JSRTCIceGatheringState.h in Headers */ = {isa = PBXBuildFile; fileRef = 316DCB481E7910A6001B5F87 /* JSRTCIceGatheringState.h */; };
+                316DCB4F1E7910A6001B5F87 /* JSRTCSignalingState.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 316DCB491E7910A6001B5F87 /* JSRTCSignalingState.cpp */; };
+                316DCB501E7910A6001B5F87 /* JSRTCSignalingState.h in Headers */ = {isa = PBXBuildFile; fileRef = 316DCB4A1E7910A6001B5F87 /* JSRTCSignalingState.h */; };
</ins><span class="cx">                 316FE0710E6CCBEE00BF6088 /* JSCSSKeyframeRule.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 316FE06D0E6CCBEE00BF6088 /* JSCSSKeyframeRule.cpp */; };
</span><span class="cx">                 316FE0720E6CCBEE00BF6088 /* JSCSSKeyframeRule.h in Headers */ = {isa = PBXBuildFile; fileRef = 316FE06E0E6CCBEE00BF6088 /* JSCSSKeyframeRule.h */; };
</span><span class="cx">                 316FE0730E6CCBEE00BF6088 /* JSCSSKeyframesRule.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 316FE06F0E6CCBEE00BF6088 /* JSCSSKeyframesRule.cpp */; };
</span><span class="lines">@@ -8918,6 +8927,18 @@
</span><span class="cx">                 316DCB2E1E78F496001B5F87 /* JSRTCAnswerOptions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSRTCAnswerOptions.h; sourceTree = "<group>"; };
</span><span class="cx">                 316DCB2F1E78F496001B5F87 /* JSRTCOfferOptions.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSRTCOfferOptions.cpp; sourceTree = "<group>"; };
</span><span class="cx">                 316DCB301E78F496001B5F87 /* JSRTCOfferOptions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSRTCOfferOptions.h; sourceTree = "<group>"; };
</span><ins>+                316DCB341E790E1B001B5F87 /* RTCIceGatheringState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RTCIceGatheringState.h; sourceTree = "<group>"; };
+                316DCB351E790E1B001B5F87 /* RTCIceGatheringState.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = RTCIceGatheringState.idl; sourceTree = "<group>"; };
+                316DCB3A1E790E2C001B5F87 /* RTCIceConnectionState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RTCIceConnectionState.h; sourceTree = "<group>"; };
+                316DCB3B1E790E2C001B5F87 /* RTCIceConnectionState.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = RTCIceConnectionState.idl; sourceTree = "<group>"; };
+                316DCB401E790E3C001B5F87 /* RTCSignalingState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RTCSignalingState.h; sourceTree = "<group>"; };
+                316DCB411E790E3C001B5F87 /* RTCSignalingState.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = RTCSignalingState.idl; sourceTree = "<group>"; };
+                316DCB451E7910A6001B5F87 /* JSRTCIceConnectionState.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSRTCIceConnectionState.cpp; sourceTree = "<group>"; };
+                316DCB461E7910A6001B5F87 /* JSRTCIceConnectionState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSRTCIceConnectionState.h; sourceTree = "<group>"; };
+                316DCB471E7910A6001B5F87 /* JSRTCIceGatheringState.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSRTCIceGatheringState.cpp; sourceTree = "<group>"; };
+                316DCB481E7910A6001B5F87 /* JSRTCIceGatheringState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSRTCIceGatheringState.h; sourceTree = "<group>"; };
+                316DCB491E7910A6001B5F87 /* JSRTCSignalingState.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSRTCSignalingState.cpp; sourceTree = "<group>"; };
+                316DCB4A1E7910A6001B5F87 /* JSRTCSignalingState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSRTCSignalingState.h; sourceTree = "<group>"; };
</ins><span class="cx">                 316FE06D0E6CCBEE00BF6088 /* JSCSSKeyframeRule.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSCSSKeyframeRule.cpp; sourceTree = "<group>"; };
</span><span class="cx">                 316FE06E0E6CCBEE00BF6088 /* JSCSSKeyframeRule.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSCSSKeyframeRule.h; sourceTree = "<group>"; };
</span><span class="cx">                 316FE06F0E6CCBEE00BF6088 /* JSCSSKeyframesRule.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSCSSKeyframesRule.cpp; sourceTree = "<group>"; };
</span><span class="lines">@@ -15884,6 +15905,10 @@
</span><span class="cx">                                 07221B7417CEC32700848E51 /* RTCIceCandidateEvent.cpp */,
</span><span class="cx">                                 07221B7517CEC32700848E51 /* RTCIceCandidateEvent.h */,
</span><span class="cx">                                 07221B7617CEC32700848E51 /* RTCIceCandidateEvent.idl */,
</span><ins>+                                316DCB3A1E790E2C001B5F87 /* RTCIceConnectionState.h */,
+                                316DCB3B1E790E2C001B5F87 /* RTCIceConnectionState.idl */,
+                                316DCB341E790E1B001B5F87 /* RTCIceGatheringState.h */,
+                                316DCB351E790E1B001B5F87 /* RTCIceGatheringState.idl */,
</ins><span class="cx">                                 07AB996718DA3C010018771E /* RTCIceServer.h */,
</span><span class="cx">                                 07AB996818DA3C010018771E /* RTCIceServer.idl */,
</span><span class="cx">                                 5E6653091DA437BF00FDD84C /* RTCIceTransport.h */,
</span><span class="lines">@@ -15911,6 +15936,8 @@
</span><span class="cx">                                 07221B7A17CEC32700848E51 /* RTCSessionDescription.cpp */,
</span><span class="cx">                                 07221B7B17CEC32700848E51 /* RTCSessionDescription.h */,
</span><span class="cx">                                 07221B7C17CEC32700848E51 /* RTCSessionDescription.idl */,
</span><ins>+                                316DCB401E790E3C001B5F87 /* RTCSignalingState.h */,
+                                316DCB411E790E3C001B5F87 /* RTCSignalingState.idl */,
</ins><span class="cx">                                 07221B8417CEC32700848E51 /* RTCStatsReport.h */,
</span><span class="cx">                                 07221B8517CEC32700848E51 /* RTCStatsReport.idl */,
</span><span class="cx">                                 5E2C43641BCEE3720001E2BC /* RTCTrackEvent.cpp */,
</span><span class="lines">@@ -16106,6 +16133,10 @@
</span><span class="cx">                                 07969D9C17D14151007FF842 /* JSRTCIceCandidate.h */,
</span><span class="cx">                                 07969D9D17D14151007FF842 /* JSRTCIceCandidateEvent.cpp */,
</span><span class="cx">                                 07969D9E17D14151007FF842 /* JSRTCIceCandidateEvent.h */,
</span><ins>+                                316DCB451E7910A6001B5F87 /* JSRTCIceConnectionState.cpp */,
+                                316DCB461E7910A6001B5F87 /* JSRTCIceConnectionState.h */,
+                                316DCB471E7910A6001B5F87 /* JSRTCIceGatheringState.cpp */,
+                                316DCB481E7910A6001B5F87 /* JSRTCIceGatheringState.h */,
</ins><span class="cx">                                 073794E919EE341E00E5A045 /* JSRTCIceServer.cpp */,
</span><span class="cx">                                 073794EA19EE341E00E5A045 /* JSRTCIceServer.h */,
</span><span class="cx">                                 316DCB191E78CA55001B5F87 /* JSRTCOfferAnswerOptions.cpp */,
</span><span class="lines">@@ -16124,6 +16155,8 @@
</span><span class="cx">                                 316DCB1C1E78CA55001B5F87 /* JSRTCRtpTransceiverDirection.h */,
</span><span class="cx">                                 07969DA117D14151007FF842 /* JSRTCSessionDescription.cpp */,
</span><span class="cx">                                 07969DA217D14151007FF842 /* JSRTCSessionDescription.h */,
</span><ins>+                                316DCB491E7910A6001B5F87 /* JSRTCSignalingState.cpp */,
+                                316DCB4A1E7910A6001B5F87 /* JSRTCSignalingState.h */,
</ins><span class="cx">                                 07969DA717D14151007FF842 /* JSRTCStatsReport.cpp */,
</span><span class="cx">                                 07969DA817D14151007FF842 /* JSRTCStatsReport.h */,
</span><span class="cx">                                 5E2C43691BCF05C80001E2BC /* JSRTCTrackEvent.cpp */,
</span><span class="lines">@@ -26121,6 +26154,7 @@
</span><span class="cx">                                 93309DD9099E64920056E581 /* ApplyStyleCommand.h in Headers */,
</span><span class="cx">                                 512DD8F60D91E6AF000F89EE /* Archive.h in Headers */,
</span><span class="cx">                                 512DD8FD0D91E6AF000F89EE /* ArchiveFactory.h in Headers */,
</span><ins>+                                316DCB4E1E7910A6001B5F87 /* JSRTCIceGatheringState.h in Headers */,
</ins><span class="cx">                                 512DD8FC0D91E6AF000F89EE /* ArchiveResource.h in Headers */,
</span><span class="cx">                                 512DD8F80D91E6AF000F89EE /* ArchiveResourceCollection.h in Headers */,
</span><span class="cx">                                 FD5686CA13AC180200B69C68 /* AsyncAudioDecoder.h in Headers */,
</span><span class="lines">@@ -27193,6 +27227,7 @@
</span><span class="cx">                                 5185FCA71BB4C4E80012898F /* IDBRecordIdentifier.h in Headers */,
</span><span class="cx">                                 5185FCA91BB4C4E80012898F /* IDBRequest.h in Headers */,
</span><span class="cx">                                 514129991C6976900059E714 /* IDBRequestCompletionEvent.h in Headers */,
</span><ins>+                                316DCB3D1E790E2C001B5F87 /* RTCIceConnectionState.h in Headers */,
</ins><span class="cx">                                 510A58FA1BACC7F200C19282 /* IDBRequestData.h in Headers */,
</span><span class="cx">                                 5145B10A1BC48E2E00E86219 /* IDBResourceIdentifier.h in Headers */,
</span><span class="cx">                                 51D7236D1BB6174900478CA3 /* IDBResultData.h in Headers */,
</span><span class="lines">@@ -27733,6 +27768,7 @@
</span><span class="cx">                                 65DF320009D1CC60000BE325 /* JSProcessingInstruction.h in Headers */,
</span><span class="cx">                                 E44613EE0CD681BB00FADA75 /* JSProgressEvent.h in Headers */,
</span><span class="cx">                                 077664FD183E6B5C00133B92 /* JSQuickTimePluginReplacement.h in Headers */,
</span><ins>+                                316DCB371E790E1B001B5F87 /* RTCIceGatheringState.h in Headers */,
</ins><span class="cx">                                 B658FFA21522EF3A00DD5595 /* JSRadioNodeList.h in Headers */,
</span><span class="cx">                                 65DF320209D1CC60000BE325 /* JSRange.h in Headers */,
</span><span class="cx">                                 6C4C96DF1AD4483500363F64 /* JSReadableByteStreamController.h in Headers */,
</span><span class="lines">@@ -28042,6 +28078,7 @@
</span><span class="cx">                                 1AE00D59182DAC8D00087DD7 /* KeyedCoding.h in Headers */,
</span><span class="cx">                                 517A63C51B74318F00E7DCDC /* KeyedDecoderCF.h in Headers */,
</span><span class="cx">                                 517A63C61B74319200E7DCDC /* KeyedEncoderCF.h in Headers */,
</span><ins>+                                316DCB4C1E7910A6001B5F87 /* JSRTCIceConnectionState.h in Headers */,
</ins><span class="cx">                                 A513B3D7114B1666001C429B /* KeyEventCocoa.h in Headers */,
</span><span class="cx">                                 265541391489811C000DFC5D /* KeyEventCodesIOS.h in Headers */,
</span><span class="cx">                                 316FE11A0E6E1DA700BF6088 /* KeyframeAnimation.h in Headers */,
</span><span class="lines">@@ -28707,6 +28744,7 @@
</span><span class="cx">                                 436708D512D9CA4B00044234 /* RenderSVGResourceFilterPrimitive.h in Headers */,
</span><span class="cx">                                 436708D712D9CA4B00044234 /* RenderSVGResourceGradient.h in Headers */,
</span><span class="cx">                                 436708D912D9CA4B00044234 /* RenderSVGResourceLinearGradient.h in Headers */,
</span><ins>+                                316DCB431E790E3C001B5F87 /* RTCSignalingState.h in Headers */,
</ins><span class="cx">                                 436708DB12D9CA4B00044234 /* RenderSVGResourceMarker.h in Headers */,
</span><span class="cx">                                 436708DD12D9CA4B00044234 /* RenderSVGResourceMasker.h in Headers */,
</span><span class="cx">                                 436708DF12D9CA4B00044234 /* RenderSVGResourcePattern.h in Headers */,
</span><span class="lines">@@ -29287,6 +29325,7 @@
</span><span class="cx">                                 088A0E0A126EF1DB00978F7A /* SVGProperty.h in Headers */,
</span><span class="cx">                                 081DD49C13BA1A6000DC7627 /* SVGPropertyInfo.h in Headers */,
</span><span class="cx">                                 088A0E0B126EF1DB00978F7A /* SVGPropertyTearOff.h in Headers */,
</span><ins>+                                316DCB501E7910A6001B5F87 /* JSRTCSignalingState.h in Headers */,
</ins><span class="cx">                                 088A0E0C126EF1DB00978F7A /* SVGPropertyTraits.h in Headers */,
</span><span class="cx">                                 B2227A9A0D00BF220071B782 /* SVGRadialGradientElement.h in Headers */,
</span><span class="cx">                                 08EDE19F12A50B8E00B95797 /* SVGRect.h in Headers */,
</span><span class="lines">@@ -30950,6 +30989,7 @@
</span><span class="cx">                                 B2A015AA0AF6CD53006BCE0E /* GraphicsTypes.cpp in Sources */,
</span><span class="cx">                                 E112F4711E3A861200D6CDFD /* Grid.cpp in Sources */,
</span><span class="cx">                                 CDF7483E18FEBCEC0006ECC0 /* GridPositionsResolver.cpp in Sources */,
</span><ins>+                                316DCB4B1E7910A6001B5F87 /* JSRTCIceConnectionState.cpp in Sources */,
</ins><span class="cx">                                 E12DE7171E4B749C00F9ACCF /* GridTrackSizingAlgorithm.cpp in Sources */,
</span><span class="cx">                                 F55B3DBF1251F12D003EF269 /* HiddenInputType.cpp in Sources */,
</span><span class="cx">                                 515BE19B1D54F6C100DD7C68 /* HIDGamepad.cpp in Sources */,
</span><span class="lines">@@ -30985,6 +31025,7 @@
</span><span class="cx">                                 D359D789129CA2710006E5D2 /* HTMLDetailsElement.cpp in Sources */,
</span><span class="cx">                                 A8EA79F90A1916DF00A8EF5F /* HTMLDirectoryElement.cpp in Sources */,
</span><span class="cx">                                 A8EA7CB10A192B9C00A8EF5F /* HTMLDivElement.cpp in Sources */,
</span><ins>+                                316DCB4F1E7910A6001B5F87 /* JSRTCSignalingState.cpp in Sources */,
</ins><span class="cx">                                 A8EA79F50A1916DF00A8EF5F /* HTMLDListElement.cpp in Sources */,
</span><span class="cx">                                 93F19A9108245E59001E9ABC /* HTMLDocument.cpp in Sources */,
</span><span class="cx">                                 977B3866122883E900B81FF8 /* HTMLDocumentParser.cpp in Sources */,
</span><span class="lines">@@ -31327,6 +31368,7 @@
</span><span class="cx">                                 94E839551DFB2BC4007BC6A7 /* JSCSSNamespaceRule.cpp in Sources */,
</span><span class="cx">                                 BC46C2020C0DDC8F0020CFC3 /* JSCSSPageRule.cpp in Sources */,
</span><span class="cx">                                 14CF7B3309F6ECD700EB3665 /* JSCSSRule.cpp in Sources */,
</span><ins>+                                316DCB4D1E7910A6001B5F87 /* JSRTCIceGatheringState.cpp in Sources */,
</ins><span class="cx">                                 BC46C1EE0C0DDBDF0020CFC3 /* JSCSSRuleCustom.cpp in Sources */,
</span><span class="cx">                                 A8D05FA70A23B301005E7203 /* JSCSSRuleList.cpp in Sources */,
</span><span class="cx">                                 9392262F10321084006E7D5D /* JSCSSRuleListCustom.cpp in Sources */,
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformmediastreamMediaEndpointh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/mediastream/MediaEndpoint.h (214029 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/mediastream/MediaEndpoint.h        2017-03-16 05:12:53 UTC (rev 214029)
+++ trunk/Source/WebCore/platform/mediastream/MediaEndpoint.h        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -1,5 +1,6 @@
</span><span class="cx"> /*
</span><span class="cx"> * Copyright (C) 2015 Ericsson AB. All rights reserved.
</span><ins>+ * Copyright (C) 2017 Apple Inc. All rights reserved.
</ins><span class="cx"> *
</span><span class="cx"> * Redistribution and use in source and binary forms, with or without
</span><span class="cx"> * modification, are permitted provided that the following conditions
</span><span class="lines">@@ -66,8 +67,6 @@
</span><span class="cx"> Failed
</span><span class="cx"> };
</span><span class="cx">
</span><del>- using IceTransportState = PeerConnectionStates::IceTransportState;
-
</del><span class="cx"> virtual void setConfiguration(MediaEndpointConfiguration&&) = 0;
</span><span class="cx">
</span><span class="cx"> virtual void generateDtlsInfo() = 0;
</span><span class="lines">@@ -98,7 +97,7 @@
</span><span class="cx"> virtual void gotDtlsFingerprint(const String& fingerprint, const String& fingerprintFunction) = 0;
</span><span class="cx"> virtual void gotIceCandidate(const String& mid, IceCandidate&&) = 0;
</span><span class="cx"> virtual void doneGatheringCandidates(const String& mid) = 0;
</span><del>- virtual void iceTransportStateChanged(const String& mid, MediaEndpoint::IceTransportState) = 0;
</del><ins>+ virtual void iceTransportStateChanged(const String& mid, RTCIceTransportState) = 0;
</ins><span class="cx">
</span><span class="cx"> virtual ~MediaEndpointClient() { }
</span><span class="cx"> };
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformmediastreamMediaEndpointConfigurationcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/mediastream/MediaEndpointConfiguration.cpp (214029 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/mediastream/MediaEndpointConfiguration.cpp        2017-03-16 05:12:53 UTC (rev 214029)
+++ trunk/Source/WebCore/platform/mediastream/MediaEndpointConfiguration.cpp        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -1,5 +1,6 @@
</span><span class="cx"> /*
</span><span class="cx"> * Copyright (C) 2015 Ericsson AB. All rights reserved.
</span><ins>+ * Copyright (C) 2017 Apple Inc. All rights reserved.
</ins><span class="cx"> *
</span><span class="cx"> * Redistribution and use in source and binary forms, with or without
</span><span class="cx"> * modification, are permitted provided that the following conditions
</span><span class="lines">@@ -35,7 +36,7 @@
</span><span class="cx">
</span><span class="cx"> namespace WebCore {
</span><span class="cx">
</span><del>-MediaEndpointConfiguration::MediaEndpointConfiguration(Vector<IceServerInfo>&& iceServers, IceTransportPolicy iceTransportPolicy, BundlePolicy bundlePolicy)
</del><ins>+MediaEndpointConfiguration::MediaEndpointConfiguration(Vector<IceServerInfo>&& iceServers, RTCIceTransportPolicy iceTransportPolicy, RTCBundlePolicy bundlePolicy)
</ins><span class="cx"> : iceServers(WTFMove(iceServers))
</span><span class="cx"> , iceTransportPolicy(iceTransportPolicy)
</span><span class="cx"> , bundlePolicy(bundlePolicy)
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformmediastreamMediaEndpointConfigurationh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/mediastream/MediaEndpointConfiguration.h (214029 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/mediastream/MediaEndpointConfiguration.h        2017-03-16 05:12:53 UTC (rev 214029)
+++ trunk/Source/WebCore/platform/mediastream/MediaEndpointConfiguration.h        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -1,5 +1,6 @@
</span><span class="cx"> /*
</span><span class="cx"> * Copyright (C) 2015 Ericsson AB. All rights reserved.
</span><ins>+ * Copyright (C) 2017 Apple Inc. All rights reserved.
</ins><span class="cx"> *
</span><span class="cx"> * Redistribution and use in source and binary forms, with or without
</span><span class="cx"> * modification, are permitted provided that the following conditions
</span><span class="lines">@@ -32,7 +33,7 @@
</span><span class="cx">
</span><span class="cx"> #if ENABLE(WEB_RTC)
</span><span class="cx">
</span><del>-#include "PeerConnectionStates.h"
</del><ins>+#include "RTCEnums.h"
</ins><span class="cx"> #include "URL.h"
</span><span class="cx"> #include <wtf/Vector.h>
</span><span class="cx"> #include <wtf/text/WTFString.h>
</span><span class="lines">@@ -49,14 +50,11 @@
</span><span class="cx"> IceServerInfo(Vector<URL>&&, const String&, const String&);
</span><span class="cx"> };
</span><span class="cx">
</span><del>- using IceTransportPolicy = PeerConnectionStates::IceTransportPolicy;
- using BundlePolicy = PeerConnectionStates::BundlePolicy;
</del><ins>+ MediaEndpointConfiguration(Vector<IceServerInfo>&&, RTCIceTransportPolicy, RTCBundlePolicy);
</ins><span class="cx">
</span><del>- MediaEndpointConfiguration(Vector<IceServerInfo>&&, IceTransportPolicy, BundlePolicy);
-
</del><span class="cx"> Vector<IceServerInfo> iceServers;
</span><del>- IceTransportPolicy iceTransportPolicy;
- BundlePolicy bundlePolicy;
</del><ins>+ RTCIceTransportPolicy iceTransportPolicy;
+ RTCBundlePolicy bundlePolicy;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformmediastreamPeerConnectionStatesh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/mediastream/PeerConnectionStates.h (214029 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/mediastream/PeerConnectionStates.h        2017-03-16 05:12:53 UTC (rev 214029)
+++ trunk/Source/WebCore/platform/mediastream/PeerConnectionStates.h        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -1,5 +1,6 @@
</span><span class="cx"> /*
</span><span class="cx"> * Copyright (C) 2015, 2016 Ericsson AB. All rights reserved.
</span><ins>+ * Copyright (C) 2017 Apple Inc. All rights reserved.
</ins><span class="cx"> *
</span><span class="cx"> * Redistribution and use in source and binary forms, with or without
</span><span class="cx"> * modification, are permitted provided that the following conditions
</span><span class="lines">@@ -34,54 +35,63 @@
</span><span class="cx">
</span><span class="cx"> namespace WebCore {
</span><span class="cx">
</span><del>-namespace PeerConnectionStates {
-
-enum class SignalingState {
- Stable = 1,
- HaveLocalOffer = 2,
- HaveRemoteOffer = 3,
- HaveLocalPrAnswer = 4,
- HaveRemotePrAnswer = 5,
- Closed = 6
</del><ins>+enum class RTCSignalingState {
+ Stable,
+ HaveLocalOffer,
+ HaveRemoteOffer,
+ HaveLocalPranswer,
+ HaveRemotePranswer,
+ Closed
</ins><span class="cx"> };
</span><span class="cx">
</span><del>-enum class IceConnectionState {
- New = 1,
- Checking = 2,
- Connected = 3,
- Completed = 4,
- Failed = 5,
- Disconnected = 6,
- Closed = 7
</del><ins>+enum class RTCIceConnectionState {
+ New,
+ Checking,
+ Connected,
+ Completed,
+ Failed,
+ Disconnected,
+ Closed
</ins><span class="cx"> };
</span><span class="cx">
</span><del>-enum class IceGatheringState {
- New = 1,
- Gathering = 2,
- Complete = 3
</del><ins>+enum class RTCIceGatheringState {
+ New,
+ Gathering,
+ Complete
</ins><span class="cx"> };
</span><span class="cx">
</span><del>-enum class IceTransportState {
- New = 1,
- Checking = 2,
- Connected = 3,
- Completed = 4,
- Failed = 5,
- Disconnected = 6,
- Closed = 7
</del><ins>+enum class RTCIceTransportState {
+ New,
+ Checking,
+ Connected,
+ Completed,
+ Failed,
+ Disconnected,
+ Closed
</ins><span class="cx"> };
</span><span class="cx">
</span><del>-enum class IceTransportPolicy {
</del><ins>+enum class RTCIceTransportPolicy {
</ins><span class="cx"> Relay,
</span><span class="cx"> All
</span><span class="cx"> };
</span><span class="cx">
</span><del>-enum class BundlePolicy {
</del><ins>+enum class RTCBundlePolicy {
</ins><span class="cx"> Balanced,
</span><span class="cx"> MaxCompat,
</span><span class="cx"> MaxBundle
</span><span class="cx"> };
</span><span class="cx">
</span><ins>+
+// FIXME: Remove once older code is upgraded
+namespace PeerConnectionStates {
+
+using SignalingState = RTCSignalingState;
+using IceConnectionState = RTCIceConnectionState;
+using IceGatheringState = RTCIceGatheringState;
+using IceTransportState = RTCIceTransportState;
+using IceTransportPolicy = RTCIceTransportPolicy;
+using BundlePolicy = RTCBundlePolicy;
+
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformmediastreamopenwebrtcMediaEndpointOwrcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/mediastream/openwebrtc/MediaEndpointOwr.cpp (214029 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/mediastream/openwebrtc/MediaEndpointOwr.cpp        2017-03-16 05:12:53 UTC (rev 214029)
+++ trunk/Source/WebCore/platform/mediastream/openwebrtc/MediaEndpointOwr.cpp        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -445,19 +445,19 @@
</span><span class="cx"> if (owrIceState == OWR_ICE_STATE_READY && !transceiver.gotEndOfRemoteCandidates())
</span><span class="cx"> return;
</span><span class="cx">
</span><del>- MediaEndpoint::IceTransportState transportState;
</del><ins>+ RTCIceTransportState transportState;
</ins><span class="cx"> switch (owrIceState) {
</span><span class="cx"> case OWR_ICE_STATE_CONNECTING:
</span><del>- transportState = MediaEndpoint::IceTransportState::Checking;
</del><ins>+ transportState = RTCIceTransportState::Checking;
</ins><span class="cx"> break;
</span><span class="cx"> case OWR_ICE_STATE_CONNECTED:
</span><del>- transportState = MediaEndpoint::IceTransportState::Connected;
</del><ins>+ transportState = RTCIceTransportState::Connected;
</ins><span class="cx"> break;
</span><span class="cx"> case OWR_ICE_STATE_READY:
</span><del>- transportState = MediaEndpoint::IceTransportState::Completed;
</del><ins>+ transportState = RTCIceTransportState::Completed;
</ins><span class="cx"> break;
</span><span class="cx"> case OWR_ICE_STATE_FAILED:
</span><del>- transportState = MediaEndpoint::IceTransportState::Failed;
</del><ins>+ transportState = RTCIceTransportState::Failed;
</ins><span class="cx"> break;
</span><span class="cx"> default:
</span><span class="cx"> return;
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformmockMockMediaEndpointcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/mock/MockMediaEndpoint.cpp (214029 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/mock/MockMediaEndpoint.cpp        2017-03-16 05:12:53 UTC (rev 214029)
+++ trunk/Source/WebCore/platform/mock/MockMediaEndpoint.cpp        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -1,5 +1,6 @@
</span><span class="cx"> /*
</span><span class="cx"> * Copyright (C) 2015 Ericsson AB. All rights reserved.
</span><ins>+ * Copyright (C) 2017 Apple Inc. All rights reserved.
</ins><span class="cx"> *
</span><span class="cx"> * Redistribution and use in source and binary forms, with or without
</span><span class="cx"> * modification, are permitted provided that the following conditions
</span><span class="lines">@@ -277,27 +278,27 @@
</span><span class="cx">
</span><span class="cx"> // Should go to:
</span><span class="cx"> // 'checking'
</span><del>- m_iceTransportStateChanges.append(std::make_pair(m_mids[0], MediaEndpoint::IceTransportState::Checking));
- m_iceTransportStateChanges.append(std::make_pair(m_mids[1], MediaEndpoint::IceTransportState::Checking));
- m_iceTransportStateChanges.append(std::make_pair(m_mids[2], MediaEndpoint::IceTransportState::Checking));
</del><ins>+ m_iceTransportStateChanges.append(std::make_pair(m_mids[0], RTCIceTransportState::Checking));
+ m_iceTransportStateChanges.append(std::make_pair(m_mids[1], RTCIceTransportState::Checking));
+ m_iceTransportStateChanges.append(std::make_pair(m_mids[2], RTCIceTransportState::Checking));
</ins><span class="cx">
</span><span class="cx"> // 'connected'
</span><del>- m_iceTransportStateChanges.append(std::make_pair(m_mids[0], MediaEndpoint::IceTransportState::Connected));
- m_iceTransportStateChanges.append(std::make_pair(m_mids[1], MediaEndpoint::IceTransportState::Completed));
- m_iceTransportStateChanges.append(std::make_pair(m_mids[2], MediaEndpoint::IceTransportState::Closed));
</del><ins>+ m_iceTransportStateChanges.append(std::make_pair(m_mids[0], RTCIceTransportState::Connected));
+ m_iceTransportStateChanges.append(std::make_pair(m_mids[1], RTCIceTransportState::Completed));
+ m_iceTransportStateChanges.append(std::make_pair(m_mids[2], RTCIceTransportState::Closed));
</ins><span class="cx">
</span><span class="cx"> // 'completed'
</span><del>- m_iceTransportStateChanges.append(std::make_pair(m_mids[0], MediaEndpoint::IceTransportState::Completed));
</del><ins>+ m_iceTransportStateChanges.append(std::make_pair(m_mids[0], RTCIceTransportState::Completed));
</ins><span class="cx">
</span><span class="cx"> // 'failed'
</span><del>- m_iceTransportStateChanges.append(std::make_pair(m_mids[0], MediaEndpoint::IceTransportState::Failed));
</del><ins>+ m_iceTransportStateChanges.append(std::make_pair(m_mids[0], RTCIceTransportState::Failed));
</ins><span class="cx">
</span><span class="cx"> // 'disconnected'
</span><del>- m_iceTransportStateChanges.append(std::make_pair(m_mids[1], MediaEndpoint::IceTransportState::Disconnected));
- m_iceTransportStateChanges.append(std::make_pair(m_mids[0], MediaEndpoint::IceTransportState::Closed));
</del><ins>+ m_iceTransportStateChanges.append(std::make_pair(m_mids[1], RTCIceTransportState::Disconnected));
+ m_iceTransportStateChanges.append(std::make_pair(m_mids[0], RTCIceTransportState::Closed));
</ins><span class="cx">
</span><span class="cx"> // 'new'
</span><del>- m_iceTransportStateChanges.append(std::make_pair(m_mids[1], MediaEndpoint::IceTransportState::Closed));
</del><ins>+ m_iceTransportStateChanges.append(std::make_pair(m_mids[1], RTCIceTransportState::Closed));
</ins><span class="cx">
</span><span class="cx"> // Reverse order to use takeLast() while keeping the above order
</span><span class="cx"> m_iceTransportStateChanges.reverse();
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformmockMockMediaEndpointh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/mock/MockMediaEndpoint.h (214029 => 214030)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/mock/MockMediaEndpoint.h        2017-03-16 05:12:53 UTC (rev 214029)
+++ trunk/Source/WebCore/platform/mock/MockMediaEndpoint.h        2017-03-16 06:10:34 UTC (rev 214030)
</span><span class="lines">@@ -1,5 +1,6 @@
</span><span class="cx"> /*
</span><span class="cx"> * Copyright (C) 2015 Ericsson AB. All rights reserved.
</span><ins>+ * Copyright (C) 2017 Apple Inc. All rights reserved.
</ins><span class="cx"> *
</span><span class="cx"> * Redistribution and use in source and binary forms, with or without
</span><span class="cx"> * modification, are permitted provided that the following conditions
</span><span class="lines">@@ -33,6 +34,7 @@
</span><span class="cx"> #if ENABLE(WEB_RTC)
</span><span class="cx">
</span><span class="cx"> #include "MediaEndpoint.h"
</span><ins>+#include "RTCEnums.h"
</ins><span class="cx"> #include "Timer.h"
</span><span class="cx">
</span><span class="cx"> namespace WebCore {
</span><span class="lines">@@ -85,7 +87,7 @@
</span><span class="cx"> Vector<IceCandidate> m_fakeIceCandidates;
</span><span class="cx"> Timer m_iceCandidateTimer;
</span><span class="cx">
</span><del>- Vector<std::pair<String, MediaEndpoint::IceTransportState>> m_iceTransportStateChanges;
</del><ins>+ Vector<std::pair<String, RTCIceTransportState>> m_iceTransportStateChanges;
</ins><span class="cx"> Timer m_iceTransportTimer;
</span><span class="cx">
</span><span class="cx"> Vector<String> m_midsOfSourcesToUnmute;
</span></span></pre>
</div>
</div>
</body>
</html>