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

Side by Side Diff: Source/modules/mediastream/RTCIceCandidate.cpp

Issue 18548003: Rename ExceptionCode constants to use the names in the spec (2/3) (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 5 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 | Annotate | Revision Log
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 25 matching lines...) Expand all
36 #include "core/dom/ExceptionCode.h" 36 #include "core/dom/ExceptionCode.h"
37 #include "public/platform/WebRTCICECandidate.h" 37 #include "public/platform/WebRTCICECandidate.h"
38 38
39 namespace WebCore { 39 namespace WebCore {
40 40
41 PassRefPtr<RTCIceCandidate> RTCIceCandidate::create(const Dictionary& dictionary , ExceptionCode& ec) 41 PassRefPtr<RTCIceCandidate> RTCIceCandidate::create(const Dictionary& dictionary , ExceptionCode& ec)
42 { 42 {
43 String candidate; 43 String candidate;
44 bool ok = dictionary.get("candidate", candidate); 44 bool ok = dictionary.get("candidate", candidate);
45 if (!ok || !candidate.length()) { 45 if (!ok || !candidate.length()) {
46 ec = TYPE_MISMATCH_ERR; 46 ec = TypeMismatchError;
47 return 0; 47 return 0;
48 } 48 }
49 49
50 String sdpMid; 50 String sdpMid;
51 dictionary.get("sdpMid", sdpMid); 51 dictionary.get("sdpMid", sdpMid);
52 52
53 unsigned short sdpMLineIndex = 0; 53 unsigned short sdpMLineIndex = 0;
54 dictionary.get("sdpMLineIndex", sdpMLineIndex); 54 dictionary.get("sdpMLineIndex", sdpMLineIndex);
55 55
56 return adoptRef(new RTCIceCandidate(WebKit::WebRTCICECandidate(candidate, sd pMid, sdpMLineIndex))); 56 return adoptRef(new RTCIceCandidate(WebKit::WebRTCICECandidate(candidate, sd pMid, sdpMLineIndex)));
(...skipping 28 matching lines...) Expand all
85 { 85 {
86 return m_webCandidate.sdpMLineIndex(); 86 return m_webCandidate.sdpMLineIndex();
87 } 87 }
88 88
89 WebKit::WebRTCICECandidate RTCIceCandidate::webCandidate() 89 WebKit::WebRTCICECandidate RTCIceCandidate::webCandidate()
90 { 90 {
91 return m_webCandidate; 91 return m_webCandidate;
92 } 92 }
93 93
94 } // namespace WebCore 94 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/modules/mediastream/RTCDataChannel.cpp ('k') | Source/modules/mediastream/RTCPeerConnection.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698