From 413b74eb37fa6b9e7ae38b22e8d777a74bd7a972 Mon Sep 17 00:00:00 2001
From: Davin <591807572@qq.com>
Date: 星期三, 21 六月 2023 15:09:03 +0800
Subject: [PATCH] feature 门锁历史记录UI调整
---
EZSDK/EZSDK/EZ/UIViewControllers/EZLivePlayViewController.m | 309 ++++++++++++++++++++++++++++++++++++++++++++++-----
1 files changed, 279 insertions(+), 30 deletions(-)
diff --git a/EZSDK/EZSDK/EZ/UIViewControllers/EZLivePlayViewController.m b/EZSDK/EZSDK/EZ/UIViewControllers/EZLivePlayViewController.m
index 2167f96..35c1a4c 100644
--- a/EZSDK/EZSDK/EZ/UIViewControllers/EZLivePlayViewController.m
+++ b/EZSDK/EZSDK/EZ/UIViewControllers/EZLivePlayViewController.m
@@ -24,6 +24,7 @@
#import "MBProgressHUD.h"
#import <EZOpenSDKFramework/EZPMPlayPrivateTokenInfo.h>
#import "HDLEZAlertInputView.h"
+#import "HDLEZOPButton.h"
#define MinimumZoomScale 1.0
#define MaximumZoomScale 4.0
@@ -32,6 +33,7 @@
{
NSOperation *op;
BOOL _isPressed;
+ BOOL _landscape; // 鏄惁鏃嬭浆
}
@property (nonatomic) BOOL isOpenSound;
@@ -88,11 +90,21 @@
@property (nonatomic, strong) EZCameraInfo *cameraInfo;
@property (weak, nonatomic) IBOutlet UILabel *streamTypeLabel;
@property (weak, nonatomic) IBOutlet UIScrollView *scrollView;
+@property (weak, nonatomic) IBOutlet NSLayoutConstraint *scrollViewTopMargin;
@property (weak, nonatomic) IBOutlet UILabel *zoomSizeLabel;
-
+@property (weak, nonatomic) IBOutlet NSLayoutConstraint *scrollViewWHRatio; // 婊氬姩瑙嗗浘瀹介珮姣�
@property (nonatomic, strong) HDLEZButton *unlockButton;//寮�閿佹寜閽�
@property (nonatomic, copy) NSString *streamToken;
+
+@property (nonatomic, strong) UIView *doorPlayerView;//闂ㄩ攣鎾斁view
+
+// 鍛煎彨瑙嗗浘鐩稿叧鎺т欢
+@property (weak, nonatomic) IBOutlet UIView *videoCallOutView; // 鍛煎彨寮规
+@property (weak, nonatomic) IBOutlet UILabel *callOutAlertLabel; // 鎻愮ず璇█
+@property (weak, nonatomic) IBOutlet HDLEZOPButton *hangUpButton; // 鎸傛柇鎸夐挳
+@property (weak, nonatomic) IBOutlet HDLEZOPButton *ignoreButton; // 蹇界暐鎸夐挳
+@property (weak, nonatomic) IBOutlet HDLEZOPButton *answerButton; // 鎺ュ惉鎸夐挳
@end
@@ -113,6 +125,7 @@
self.isStartingTalk = NO;
self.ptzView.hidden = YES;
self.talkView.hidden = YES;
+ _landscape = NO;
if (!self.deviceInfo) {//濡傛灉娌℃湁浼燿eviceInfo,闇�涓诲姩鑾峰彇
[self getDeviceInfo];
@@ -240,6 +253,21 @@
// }
}
+/*娣诲姞闂ㄩ攣鎾斁view
+ */
+-(UIView*)doorPlayerView{
+ if (!_doorPlayerView) {
+ _doorPlayerView=[[UIView alloc] init];
+ [_playerView addSubview:_doorPlayerView];
+ [_doorPlayerView mas_makeConstraints:^(MASConstraintMaker *make) {
+ make.centerX.equalTo(_playerView.mas_centerX);
+ make.top.bottom.equalTo(_playerView);
+ make.width.mas_equalTo(_doorPlayerView.mas_height).multipliedBy(1);
+ }];
+ }
+ return _doorPlayerView;
+}
+
- (void)viewDidAppear:(BOOL)animated {
[super viewDidAppear:animated];
self.navigationController.navigationBar.hidden = NO;//2021-02-01
@@ -288,11 +316,15 @@
/*鑾峰彇璁惧淇℃伅
*/
-(void)getDeviceInfo{
+ __weak __typeof(self)weakSelf = self;
//鑾峰彇璁惧淇℃伅
[EZOpenSDK getDeviceInfo:self.deviceSerial completion:^(EZDeviceInfo *deviceInfo, NSError *error) {
if(error)
{
- NSLog(@"EZ 鏌ヨ璁惧淇℃伅澶辫触");
+ NSLog(@"EZ 鏌ヨ璁惧淇℃伅澶辫触:%@",error);
+ [weakSelf.view makeToast:error.userInfo[@"NSLocalizedDescription"]
+ duration:1.5
+ position:@"center"];
return;
}
if (deviceInfo) {
@@ -310,6 +342,8 @@
self.captureButton.enabled = NO;
self.localRecordButton.enabled = NO;
self.streamPlayBtn.hidden = YES;
+ self.isShowAlert = YES;
+ NSLog(@"#####鍒濆鍖栨柟娉曞睍绀�");
if (_url)
{
@@ -372,7 +406,11 @@
[_player setPlayVerifyCode:verifyCode];
[_talkPlayer setPlayVerifyCode:verifyCode];
}
- [_player setPlayerView:_playerView];
+// if ([GlobalKit shareKit].deviceType==HDLEZDeviceType_Door) {//涓洪棬閿佹椂
+ [_player setPlayerView:self.doorPlayerView];
+// }else{
+// [_player setPlayerView:_playerView];
+// }
BOOL hdStatus = [[NSUserDefaults standardUserDefaults] boolForKey:[NSString stringWithFormat:@"EZVideoPlayHardDecodingStatus_%@", self.deviceInfo.deviceSerial]];
[_player setHDPriority:hdStatus];
[_player startRealPlay];
@@ -437,6 +475,17 @@
// [self.controlButton setImage:[UIImage imageNamed:@"hdl_ez_ic_unlock"] forState:UIControlStateNormal];
// [self.controlButton setTitle:NSLocalizedString(@"device_open", @"寮�闂�") forState:UIControlStateNormal];
}
+
+ self.callOutAlertLabel.text = HDLEZLocallizedString(@"device_callout_alert_message");
+ [self.hangUpButton setTitle:HDLEZLocallizedString(@"device_callout_hang_up") forState:UIControlStateNormal];
+ self.hangUpButton.imagePosition = HDLEZOPButtonImagePositionTop;
+ self.hangUpButton.spacingBetweenImageAndTitle = 12.;
+ [self.ignoreButton setTitle:HDLEZLocallizedString(@"device_callout_ignore") forState:UIControlStateNormal];
+ self.ignoreButton.imagePosition = HDLEZOPButtonImagePositionTop;
+ self.ignoreButton.spacingBetweenImageAndTitle = 12.;
+ [self.answerButton setTitle:HDLEZLocallizedString(@"device_callout_answer") forState:UIControlStateNormal];
+ self.answerButton.imagePosition = HDLEZOPButtonImagePositionTop;
+ self.answerButton.spacingBetweenImageAndTitle = 12.;
}
/*寮�閿�
@@ -450,7 +499,7 @@
__weak __typeof(self)weakSelf = self;
[[EZHttpUtil sharedManager] authLockByHDL:content deviceId:self.deviceId completion:^(ResponseData * _Nonnull responseData) {
if (responseData.success) {
- [[EZHttpUtil sharedManager] remoteOpenByHDL:self.streamToken deviceId:self.deviceId completion:^(ResponseData * _Nonnull responseData) {
+ [[EZHttpUtil sharedManager] remoteOpenByHDL:weakSelf.streamToken deviceId:weakSelf.deviceId completion:^(ResponseData * _Nonnull responseData) {
[MBProgressHUD hideHUDForView:weakSelf.view animated:YES];
if (responseData.success) {
[weakSelf.view makeToast:HDLEZLocallizedString(@"device_open_success")
@@ -503,29 +552,68 @@
}
}
-- (UIInterfaceOrientationMask)supportedInterfaceOrientations
-{
- return UIInterfaceOrientationMaskAllButUpsideDown;
+//- (UIInterfaceOrientationMask)supportedInterfaceOrientations
+//{
+// return UIInterfaceOrientationMaskAllButUpsideDown;
+//}
+- (UIInterfaceOrientationMask)supportedInterfaceOrientations {
+ if (@available(iOS 16.0, *)) {
+ if (_landscape && !self.isVideoDoorLock) {
+ //妯睆
+ return UIInterfaceOrientationMaskLandscape;
+ } else {
+ //绔栧睆
+ return UIInterfaceOrientationMaskPortrait;
+ }
+ } else {
+ return UIInterfaceOrientationMaskAllButUpsideDown;
+ }
}
- (void)willRotateToInterfaceOrientation:(UIInterfaceOrientation)toInterfaceOrientation
duration:(NSTimeInterval)duration
{
+ if (self.isVideoDoorLock) return;
self.navigationController.navigationBarHidden = NO;
self.toolBar.hidden = NO;
self.largeBackButton.hidden = YES;
self.bottomView.hidden = NO;
self.largeTitleLabel.hidden = YES;
self.localRecrodContraint.constant = 10;
+
+ [self.scrollView setTranslatesAutoresizingMaskIntoConstraints:NO];
+ [self.toolBar setTranslatesAutoresizingMaskIntoConstraints:NO];
+ [NSLayoutConstraint deactivateConstraints:@[self.scrollViewWHRatio]];
+ self.scrollViewWHRatio = [NSLayoutConstraint constraintWithItem:self.scrollView attribute:NSLayoutAttributeWidth relatedBy:NSLayoutRelationEqual toItem:self.scrollView attribute:NSLayoutAttributeHeight multiplier:16/9. constant:0];
+ [NSLayoutConstraint activateConstraints:@[self.scrollViewWHRatio]];
+ dispatch_async(dispatch_get_main_queue(), ^{
+ [self.scrollView layoutIfNeeded];
+ [self.toolBar layoutIfNeeded];
+ });
+
if(toInterfaceOrientation == UIInterfaceOrientationLandscapeLeft ||
toInterfaceOrientation == UIInterfaceOrientationLandscapeRight)
{
self.navigationController.navigationBarHidden = YES;
self.localRecrodContraint.constant = 50;
- self.toolBar.hidden = YES;
+// self.toolBar.hidden = YES;
self.largeTitleLabel.hidden = NO;
self.largeBackButton.hidden = NO;
self.bottomView.hidden = YES;
+
+ CGFloat tureScreenW = HDLEZ_APP_SCREEN_WIDTH > HDLEZ_APP_SCREEN_HEIGHT ? HDLEZ_APP_SCREEN_HEIGHT : HDLEZ_APP_SCREEN_WIDTH;
+ CGFloat tureScreenH = HDLEZ_APP_SCREEN_WIDTH < HDLEZ_APP_SCREEN_HEIGHT ? HDLEZ_APP_SCREEN_HEIGHT : HDLEZ_APP_SCREEN_WIDTH;
+
+
+ [self.scrollView setTranslatesAutoresizingMaskIntoConstraints:NO];
+ [self.toolBar setTranslatesAutoresizingMaskIntoConstraints:NO];
+ [NSLayoutConstraint deactivateConstraints:@[self.scrollViewWHRatio]];
+ self.scrollViewWHRatio = [NSLayoutConstraint constraintWithItem:self.scrollView attribute:NSLayoutAttributeWidth relatedBy:NSLayoutRelationEqual toItem:self.scrollView attribute:NSLayoutAttributeHeight multiplier:tureScreenH/(tureScreenW - 37) constant:0];
+ [NSLayoutConstraint activateConstraints:@[self.scrollViewWHRatio]];
+ dispatch_async(dispatch_get_main_queue(), ^{
+ [self.scrollView layoutIfNeeded];
+ [self.toolBar layoutIfNeeded];
+ });
}
}
@@ -581,21 +669,25 @@
}
-///**
-// * 鏀跺埌鐨勭敾闈㈤暱瀹藉��
-// *
-// * @param player 鎾斁鍣ㄥ璞�
-// * @param height 楂樺害
-// * @param width 瀹藉害
-// */
-//- (void)player:(EZPlayer *)player didReceivedDisplayHeight:(NSInteger)height displayWidth:(NSInteger)width{
+/**
+ * 鏀跺埌鐨勭敾闈㈤暱瀹藉��
+ *
+ * @param player 鎾斁鍣ㄥ璞�
+ * @param height 楂樺害
+ * @param width 瀹藉害
+ */
+- (void)player:(EZPlayer *)player didReceivedDisplayHeight:(NSInteger)height displayWidth:(NSInteger)width{
// HDLEZLog(@"鐢婚潰闀匡細%ld锛屽锛�%ld",(long)height,(long)width);
-// CGFloat playerVH=self.playerView.frame.size.height;
-// CGFloat playerVW=playerVH*(width/height);
-// self.playerView.frame=CGRectMake(0, 0, 50, 50);
-// HDLEZLog(@"playerView鐨刦rame锛�%f",self.playerView.frame.size.width);
-//
-//}
+ CGFloat playerVH=self.playerView.frame.size.height;
+// HDLEZLog(@"楂橈細%ld",(long)playerVH);
+ CGFloat ratio=((CGFloat)width)/((CGFloat)height);
+// HDLEZLog(@"姣斾緥锛�%f",ratio);
+ CGFloat playerVW=playerVH*ratio;
+// HDLEZLog(@"瀹斤細%ld",(long)playerVW);
+ [self.doorPlayerView mas_updateConstraints:^(MASConstraintMaker *make) {
+ make.width.mas_equalTo(_doorPlayerView.mas_height).multipliedBy(ratio);
+ }];
+}
- (void)player:(EZPlayer *)player didPlayFailed:(NSError *)error
@@ -790,14 +882,100 @@
- (IBAction)large:(id)sender
{
- NSNumber *value = [NSNumber numberWithInt:UIInterfaceOrientationLandscapeLeft];
- [[UIDevice currentDevice] setValue:value forKey:@"orientation"];
+ if (_landscape == YES) {
+ [self largeBack:self.largeBackButton];
+ return;
+ }
+ _landscape = YES;
+ if (self.isVideoDoorLock) {
+ self.navigationController.navigationBarHidden = YES;
+ self.localRecrodContraint.constant = 50;
+ self.toolBar.hidden = NO;
+ self.largeTitleLabel.hidden = NO;
+ self.largeBackButton.hidden = YES;
+ self.bottomView.hidden = YES;
+ self.videoCallOutView.hidden = YES;
+
+ [self.scrollView setTranslatesAutoresizingMaskIntoConstraints:NO];
+ [self.toolBar setTranslatesAutoresizingMaskIntoConstraints:NO];
+ [NSLayoutConstraint deactivateConstraints:@[self.scrollViewTopMargin, self.scrollViewWHRatio]];
+ self.scrollViewTopMargin = [NSLayoutConstraint constraintWithItem:self.scrollView attribute:NSLayoutAttributeTop relatedBy:NSLayoutRelationEqual toItem:self.topLayoutGuide attribute:NSLayoutAttributeBottom multiplier:1.0 constant:-HDLEZ_APP_STATUS_BAR_HEIGHT];
+ self.scrollViewWHRatio = [NSLayoutConstraint constraintWithItem:self.scrollView attribute:NSLayoutAttributeWidth relatedBy:NSLayoutRelationEqual toItem:self.scrollView attribute:NSLayoutAttributeHeight multiplier:HDLEZ_APP_SCREEN_WIDTH/(HDLEZ_APP_SCREEN_HEIGHT - 37.) constant:0];
+ [NSLayoutConstraint activateConstraints:@[self.scrollViewTopMargin, self.scrollViewWHRatio]];
+ dispatch_async(dispatch_get_main_queue(), ^{
+ [self.scrollView layoutIfNeeded];
+ [self.toolBar layoutIfNeeded];
+ });
+ return;
+ }
+ if (@available(iOS 16.0, *)) {
+ if (self.navigationController) {
+ dispatch_async(dispatch_get_main_queue(), ^{
+ [self.navigationController setNeedsUpdateOfSupportedInterfaceOrientations];
+ });
+ } else {
+ dispatch_async(dispatch_get_main_queue(), ^{
+ [self setNeedsUpdateOfSupportedInterfaceOrientations];
+ });
+ }
+ NSArray *array = [[[UIApplication sharedApplication] connectedScenes] allObjects];
+ UIWindowScene *ws = (UIWindowScene *)array.firstObject;
+ UIWindowSceneGeometryPreferencesIOS *geometryPreferences = [[UIWindowSceneGeometryPreferencesIOS alloc] init];
+ geometryPreferences.interfaceOrientations = UIInterfaceOrientationMaskLandscape;
+ [ws requestGeometryUpdateWithPreferences:geometryPreferences errorHandler:^(NSError * _Nonnull error) {
+ NSLog(@"iOS 16 Error: %@",error);
+ }];
+ } else {
+ NSNumber *value = [NSNumber numberWithInt:UIInterfaceOrientationLandscapeLeft];
+ [[UIDevice currentDevice] setValue:value forKey:@"orientation"];
+ }
}
- (IBAction)largeBack:(id)sender
{
- NSNumber *value = [NSNumber numberWithInt:UIInterfaceOrientationPortrait];
- [[UIDevice currentDevice] setValue:value forKey:@"orientation"];
+ _landscape = NO;
+ if (self.isVideoDoorLock) {
+ self.navigationController.navigationBarHidden = NO;
+ self.toolBar.hidden = NO;
+ self.largeBackButton.hidden = YES;
+ self.bottomView.hidden = NO;
+ self.largeTitleLabel.hidden = YES;
+ self.localRecrodContraint.constant = 10;
+ self.videoCallOutView.hidden = !self.isShowAlert;
+
+ [self.scrollView setTranslatesAutoresizingMaskIntoConstraints:NO];
+ [self.toolBar setTranslatesAutoresizingMaskIntoConstraints:NO];
+ [NSLayoutConstraint deactivateConstraints:@[self.scrollViewTopMargin,self.scrollViewWHRatio]];
+ self.scrollViewTopMargin = [NSLayoutConstraint constraintWithItem:self.scrollView attribute:NSLayoutAttributeTop relatedBy:NSLayoutRelationEqual toItem:self.topLayoutGuide attribute:NSLayoutAttributeBottom multiplier:1.0 constant:0];
+ self.scrollViewWHRatio = [NSLayoutConstraint constraintWithItem:self.scrollView attribute:NSLayoutAttributeWidth relatedBy:NSLayoutRelationEqual toItem:self.scrollView attribute:NSLayoutAttributeHeight multiplier:16/9. constant:0];
+ [NSLayoutConstraint activateConstraints:@[self.scrollViewTopMargin,self.scrollViewWHRatio]];
+ dispatch_async(dispatch_get_main_queue(), ^{
+ [self.scrollView layoutIfNeeded];
+ [self.toolBar layoutIfNeeded];
+ });
+ return;
+ }
+ if (@available(iOS 16.0, *)) {
+ if (self.navigationController) {
+ dispatch_async(dispatch_get_main_queue(), ^{
+ [self.navigationController setNeedsUpdateOfSupportedInterfaceOrientations];
+ });
+ } else {
+ dispatch_async(dispatch_get_main_queue(), ^{
+ [self setNeedsUpdateOfSupportedInterfaceOrientations];
+ });
+ }
+ NSArray *array = [[[UIApplication sharedApplication] connectedScenes] allObjects];
+ UIWindowScene *ws = (UIWindowScene *)array.firstObject;
+ UIWindowSceneGeometryPreferencesIOS *geometryPreferences = [[UIWindowSceneGeometryPreferencesIOS alloc] init];
+ geometryPreferences.interfaceOrientations = UIInterfaceOrientationMaskPortrait;
+ [ws requestGeometryUpdateWithPreferences:geometryPreferences errorHandler:^(NSError * _Nonnull error) {
+ NSLog(@"iOS 16 Error: %@",error);
+ }];
+ } else {
+ NSNumber *value = [NSNumber numberWithInt:UIInterfaceOrientationPortrait];
+ [[UIDevice currentDevice] setValue:value forKey:@"orientation"];
+ }
}
- (IBAction)capture:(id)sender
@@ -1177,6 +1355,38 @@
_isPressed = !_isPressed;
}
+- (IBAction)clickCalloutHangupAction:(id)sender {
+ [UIView dd_showMessage:@"鎸傛柇寮�鍙戜腑..."];
+ self.isShowAlert = NO;
+}
+
+- (IBAction)clickCalloutIgnoreAction:(id)sender {
+ [UIView dd_showMessage:@"蹇界暐寮�鍙戜腑..."];
+ self.isShowAlert = NO;
+}
+
+- (IBAction)clickCalloutAnswerAction:(id)sender {
+ [UIView dd_showMessage:@"鎺ュ惉寮�鍙戜腑..."];
+ self.isShowAlert = NO;
+ [self talkButtonClicked:self.talkButton];
+}
+
+
+#pragma mark - Publish Methods
+/// 灞曠ず鍛煎彨寮规
+- (void)showCallOutAlertView {
+ self.videoCallOutView.hidden = NO;
+ [UIView dd_showMessage:@"灞曠ず鍛煎彨寮规"];
+ NSLog(@"灞曠ず鍛煎彨寮规");
+}
+
+/// 闅愯棌鍛煎彨寮规
+- (void)hiddenCallOutAlertView {
+ self.videoCallOutView.hidden = YES;
+ [UIView dd_showMessage:@"闅愯棌鍛煎彨寮规"];
+ NSLog(@"闅愯棌鍛煎彨寮规");
+}
+
#pragma mark - Private Methods
- (void) checkMicPermissionResult:(void(^)(BOOL enable)) retCb
@@ -1297,17 +1507,41 @@
}
CGFloat averageWidth = [UIScreen mainScreen].bounds.size.width/5.0;
UIImageView *lineImageView1 = [UIView dd_instanceVerticalLine:20 color:[UIColor grayColor]];
- lineImageView1.frame = CGRectMake(averageWidth, 7, lineImageView1.frame.size.width, lineImageView1.frame.size.height);
+// lineImageView1.frame = CGRectMake(averageWidth, 7, lineImageView1.frame.size.width, lineImageView1.frame.size.height);
[self.toolBar addSubview:lineImageView1];
+ [lineImageView1 mas_makeConstraints:^(MASConstraintMaker *make) {
+ make.left.mas_equalTo(self.playButton.mas_right);
+ make.centerY.mas_equalTo(self.playButton.mas_centerY);
+ make.width.mas_equalTo(lineImageView1.frame.size.width);
+ make.height.mas_equalTo(lineImageView1.frame.size.height);
+ }];
UIImageView *lineImageView2 = [UIView dd_instanceVerticalLine:20 color:[UIColor grayColor]];
- lineImageView2.frame = CGRectMake(averageWidth * 2, 7, lineImageView2.frame.size.width, lineImageView2.frame.size.height);
+// lineImageView2.frame = CGRectMake(averageWidth * 2, 7, lineImageView2.frame.size.width, lineImageView2.frame.size.height);
[self.toolBar addSubview:lineImageView2];
+ [lineImageView2 mas_makeConstraints:^(MASConstraintMaker *make) {
+ make.left.mas_equalTo(self.voiceButton.mas_right);
+ make.centerY.mas_equalTo(self.voiceButton.mas_centerY);
+ make.width.mas_equalTo(lineImageView2.frame.size.width);
+ make.height.mas_equalTo(lineImageView2.frame.size.height);
+ }];
UIImageView *lineImageView3 = [UIView dd_instanceVerticalLine:20 color:[UIColor grayColor]];
- lineImageView3.frame = CGRectMake(averageWidth * 3, 7, lineImageView3.frame.size.width, lineImageView3.frame.size.height);
+// lineImageView3.frame = CGRectMake(averageWidth * 3, 7, lineImageView3.frame.size.width, lineImageView3.frame.size.height);
[self.toolBar addSubview:lineImageView3];
+ [lineImageView3 mas_makeConstraints:^(MASConstraintMaker *make) {
+ make.left.mas_equalTo(self.qualityButton.mas_right);
+ make.centerY.mas_equalTo(self.qualityButton.mas_centerY);
+ make.width.mas_equalTo(lineImageView3.frame.size.width);
+ make.height.mas_equalTo(lineImageView3.frame.size.height);
+ }];
UIImageView *lineImageView4 = [UIView dd_instanceVerticalLine:20 color:[UIColor grayColor]];
- lineImageView4.frame = CGRectMake(averageWidth * 4, 7, lineImageView4.frame.size.width, lineImageView4.frame.size.height);
+// lineImageView4.frame = CGRectMake(averageWidth * 4, 7, lineImageView4.frame.size.width, lineImageView4.frame.size.height);
[self.toolBar addSubview:lineImageView4];
+ [lineImageView4 mas_makeConstraints:^(MASConstraintMaker *make) {
+ make.left.mas_equalTo(self.emptyButton.mas_right);
+ make.centerY.mas_equalTo(self.emptyButton.mas_centerY);
+ make.width.mas_equalTo(lineImageView4.frame.size.width);
+ make.height.mas_equalTo(lineImageView4.frame.size.height);
+ }];
}
@@ -1408,5 +1642,20 @@
}
}
+#pragma Setter
+- (void)setIsShowAlert:(BOOL)isShowAlert {
+ _isShowAlert = isShowAlert;
+ if (isShowAlert) {
+ NSLog(@"#####set鏂规硶灞曠ず");
+ [self showCallOutAlertView];
+ } else {
+ NSLog(@"#####set鏂规硶闅愯棌");
+ [self hiddenCallOutAlertView];
+ }
+}
+
+- (BOOL)prefersHomeIndicatorAutoHidden {
+ return YES;
+}
@end
--
Gitblit v1.8.0