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

Side by Side Diff: webrtc/examples/objc/AppRTCDemo/mac/APPRTCViewController.m

Issue 2294913003: Update iOS AppRTCDemo to use level controller. (Closed)
Patch Set: Remove blank line. Created 4 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
OLDNEW
1 /* 1 /*
2 * Copyright 2014 The WebRTC Project Authors. All rights reserved. 2 * Copyright 2014 The WebRTC Project Authors. All rights reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 266 matching lines...) Expand 10 before | Expand all | Expand 10 after
277 - (void)appClient:(ARDAppClient *)client 277 - (void)appClient:(ARDAppClient *)client
278 didGetStats:(NSArray *)stats { 278 didGetStats:(NSArray *)stats {
279 } 279 }
280 280
281 #pragma mark - APPRTCMainViewDelegate 281 #pragma mark - APPRTCMainViewDelegate
282 282
283 - (void)appRTCMainView:(APPRTCMainView*)mainView 283 - (void)appRTCMainView:(APPRTCMainView*)mainView
284 didEnterRoomId:(NSString*)roomId { 284 didEnterRoomId:(NSString*)roomId {
285 [_client disconnect]; 285 [_client disconnect];
286 ARDAppClient *client = [[ARDAppClient alloc] initWithDelegate:self]; 286 ARDAppClient *client = [[ARDAppClient alloc] initWithDelegate:self];
287 [client connectToRoomWithId:roomId isLoopback:NO isAudioOnly:NO shouldMakeAecD ump:NO]; 287 [client connectToRoomWithId:roomId
288 isLoopback:NO
289 isAudioOnly:NO
290 shouldMakeAecDump:NO
291 shouldUseLevelControl:NO];
288 _client = client; 292 _client = client;
289 } 293 }
290 294
291 #pragma mark - Private 295 #pragma mark - Private
292 296
293 - (APPRTCMainView*)mainView { 297 - (APPRTCMainView*)mainView {
294 return (APPRTCMainView*)self.view; 298 return (APPRTCMainView*)self.view;
295 } 299 }
296 300
297 - (void)showAlertWithMessage:(NSString*)message { 301 - (void)showAlertWithMessage:(NSString*)message {
298 NSAlert* alert = [[NSAlert alloc] init]; 302 NSAlert* alert = [[NSAlert alloc] init];
299 [alert setMessageText:message]; 303 [alert setMessageText:message];
300 [alert runModal]; 304 [alert runModal];
301 } 305 }
302 306
303 - (void)resetUI { 307 - (void)resetUI {
304 [_remoteVideoTrack removeRenderer:self.mainView.remoteVideoView]; 308 [_remoteVideoTrack removeRenderer:self.mainView.remoteVideoView];
305 _remoteVideoTrack = nil; 309 _remoteVideoTrack = nil;
306 [self.mainView.remoteVideoView renderFrame:nil]; 310 [self.mainView.remoteVideoView renderFrame:nil];
307 } 311 }
308 312
309 - (void)disconnect { 313 - (void)disconnect {
310 [self resetUI]; 314 [self resetUI];
311 [_client disconnect]; 315 [_client disconnect];
312 } 316 }
313 317
314 @end 318 @end
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698