mirror of
https://github.com/mollyim/webrtc.git
synced 2025-05-14 22:30:40 +01:00

When user touches switch camera it takes a while for camera to switch. So disabled switch camera button on touch and enabled it back when switch camera is done. It also gives visual feedback to user. Did same change for route change button as well. Route change operation is relatively fast but making this change make it robust in case the operation takes time. Also changed image color and background color highlight color for touch highlight. Bug: webrtc:11778 Change-Id: I037b830f7a02b49bf292b8838bd245db585dbd22 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/179041 Commit-Queue: Kári Helgason <kthelgason@webrtc.org> Reviewed-by: Kári Helgason <kthelgason@webrtc.org> Cr-Commit-Position: refs/heads/master@{#31910}
26 lines
925 B
Objective-C
26 lines
925 B
Objective-C
/*
|
|
* Copyright 2017 The WebRTC Project Authors. All rights reserved.
|
|
*
|
|
* Use of this source code is governed by a BSD-style license
|
|
* that can be found in the LICENSE file in the root of the source
|
|
* tree. An additional intellectual property rights grant can be found
|
|
* in the file PATENTS. All contributing project authors may
|
|
* be found in the AUTHORS file in the root of the source tree.
|
|
*/
|
|
|
|
#import <WebRTC/RTCCameraVideoCapturer.h>
|
|
|
|
@class ARDSettingsModel;
|
|
|
|
// Controls the camera. Handles starting the capture, switching cameras etc.
|
|
@interface ARDCaptureController : NSObject
|
|
|
|
- (instancetype)initWithCapturer:(RTC_OBJC_TYPE(RTCCameraVideoCapturer) *)capturer
|
|
settings:(ARDSettingsModel *)settings;
|
|
- (void)startCapture;
|
|
- (void)startCapture:(void (^)(NSError *))completion;
|
|
- (void)stopCapture;
|
|
- (void)switchCamera;
|
|
- (void)switchCamera:(void (^)(NSError *))completion;
|
|
|
|
@end
|