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

Side by Side Diff: talk/app/webrtc/objc/RTCPeerConnection.mm

Issue 2035473004: RTCPeerConnectionInterface.mm createNativeConfiguration and other clean-up. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Fixed presubmit warnings (lines longer than) Created 4 years, 6 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 | « no previous file | talk/app/webrtc/objc/RTCPeerConnectionFactory.mm » ('j') | 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 * libjingle 2 * libjingle
3 * Copyright 2013 Google Inc. 3 * Copyright 2013 Google Inc.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are met: 6 * modification, are permitted provided that the following conditions are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright notice, 8 * 1. Redistributions of source code must retain the above copyright notice,
9 * this list of conditions and the following disclaimer. 9 * this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright notice, 10 * 2. Redistributions in binary form must reproduce the above copyright notice,
(...skipping 193 matching lines...) Expand 10 before | Expand all | Expand 10 after
204 - (void)setRemoteDescriptionWithDelegate: 204 - (void)setRemoteDescriptionWithDelegate:
205 (id<RTCSessionDescriptionDelegate>)delegate 205 (id<RTCSessionDescriptionDelegate>)delegate
206 sessionDescription:(RTCSessionDescription*)sdp { 206 sessionDescription:(RTCSessionDescription*)sdp {
207 rtc::scoped_refptr<webrtc::RTCSetSessionDescriptionObserver> observer( 207 rtc::scoped_refptr<webrtc::RTCSetSessionDescriptionObserver> observer(
208 new rtc::RefCountedObject<webrtc::RTCSetSessionDescriptionObserver>( 208 new rtc::RefCountedObject<webrtc::RTCSetSessionDescriptionObserver>(
209 delegate, self)); 209 delegate, self));
210 self.peerConnection->SetRemoteDescription(observer, sdp.sessionDescription); 210 self.peerConnection->SetRemoteDescription(observer, sdp.sessionDescription);
211 } 211 }
212 212
213 - (BOOL)setConfiguration:(RTCConfiguration *)configuration { 213 - (BOOL)setConfiguration:(RTCConfiguration *)configuration {
214 return self.peerConnection->SetConfiguration( 214 std::unique_ptr<webrtc::PeerConnectionInterface::RTCConfiguration> config(
215 configuration.nativeConfiguration); 215 [configuration createNativeConfiguration]);
216 if (!config) {
217 return NO;
218 }
219 return self.peerConnection->SetConfiguration(*config);
216 } 220 }
217 221
218 - (RTCSessionDescription*)localDescription { 222 - (RTCSessionDescription*)localDescription {
219 const webrtc::SessionDescriptionInterface* sdi = 223 const webrtc::SessionDescriptionInterface* sdi =
220 self.peerConnection->local_description(); 224 self.peerConnection->local_description();
221 return sdi ? [[RTCSessionDescription alloc] initWithSessionDescription:sdi] 225 return sdi ? [[RTCSessionDescription alloc] initWithSessionDescription:sdi]
222 : nil; 226 : nil;
223 } 227 }
224 228
225 - (NSArray*)localStreams { 229 - (NSArray*)localStreams {
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
298 _delegate = delegate; 302 _delegate = delegate;
299 } 303 }
300 return self; 304 return self;
301 } 305 }
302 306
303 - (rtc::scoped_refptr<webrtc::PeerConnectionInterface>)peerConnection { 307 - (rtc::scoped_refptr<webrtc::PeerConnectionInterface>)peerConnection {
304 return _peerConnection; 308 return _peerConnection;
305 } 309 }
306 310
307 @end 311 @end
OLDNEW
« no previous file with comments | « no previous file | talk/app/webrtc/objc/RTCPeerConnectionFactory.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698