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

Side by Side Diff: Source/WebCore/Modules/mediastream/RTCPeerConnection.cpp

Issue 10969068: Merge 128982 - MediaStream API: Rename the RTCIceServer uri parameter to url. (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/1271/
Patch Set: Created 8 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « LayoutTests/fast/mediastream/constructors-expected.txt ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2012 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
76 RefPtr<RTCConfiguration> rtcConfiguration = RTCConfiguration::create(); 76 RefPtr<RTCConfiguration> rtcConfiguration = RTCConfiguration::create();
77 77
78 for (size_t i = 0; i < numberOfServers; ++i) { 78 for (size_t i = 0; i < numberOfServers; ++i) {
79 Dictionary iceServer; 79 Dictionary iceServer;
80 ok = iceServers.get(i, iceServer); 80 ok = iceServers.get(i, iceServer);
81 if (!ok) { 81 if (!ok) {
82 ec = TYPE_MISMATCH_ERR; 82 ec = TYPE_MISMATCH_ERR;
83 return 0; 83 return 0;
84 } 84 }
85 85
86 String uri, credential; 86 String urlString, credential;
87 ok = iceServer.get("uri", uri); 87 ok = iceServer.get("url", urlString);
88 if (!ok) { 88 if (!ok) {
89 ec = TYPE_MISMATCH_ERR; 89 ec = TYPE_MISMATCH_ERR;
90 return 0; 90 return 0;
91 } 91 }
92 KURL url(KURL(), uri); 92 KURL url(KURL(), urlString);
93 if (!url.isValid() || !(url.protocolIs("turn") || url.protocolIs("stun") )) { 93 if (!url.isValid() || !(url.protocolIs("turn") || url.protocolIs("stun") )) {
94 ec = TYPE_MISMATCH_ERR; 94 ec = TYPE_MISMATCH_ERR;
95 return 0; 95 return 0;
96 } 96 }
97 97
98 iceServer.get("credential", credential); 98 iceServer.get("credential", credential);
99 99
100 rtcConfiguration->appendServer(RTCIceServer::create(url, credential)); 100 rtcConfiguration->appendServer(RTCIceServer::create(url, credential));
101 } 101 }
102 102
(...skipping 406 matching lines...) Expand 10 before | Expand all | Expand 10 after
509 if (iceState == m_iceState || m_readyState == ReadyStateClosed) 509 if (iceState == m_iceState || m_readyState == ReadyStateClosed)
510 return; 510 return;
511 511
512 m_iceState = iceState; 512 m_iceState = iceState;
513 dispatchEvent(Event::create(eventNames().icechangeEvent, false, false)); 513 dispatchEvent(Event::create(eventNames().icechangeEvent, false, false));
514 } 514 }
515 515
516 } // namespace WebCore 516 } // namespace WebCore
517 517
518 #endif // ENABLE(MEDIA_STREAM) 518 #endif // ENABLE(MEDIA_STREAM)
OLDNEW
« no previous file with comments | « LayoutTests/fast/mediastream/constructors-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698