From d2d5878e3e78ec456ba571fd8970eb8403089681 Mon Sep 17 00:00:00 2001 From: JLChen <551775569@qq.com> Date: 星期一, 22 六月 2020 09:43:26 +0800 Subject: [PATCH] 2020-06-22 1.更新 --- xamarin/Shared.IOS.ESVideoPhoneSDK/Library/libESVideoPhoneSDKXamarin.a | 0 ESVideoPhoneSDKDemo1.2/ESVideoPhoneSDKDemo/ESVideoPhoneSDKDemo/ViewController.mm | 2 ESVideoPhoneSDKZigbee/ESVideoPhoneSDKDemo/ZigBee/ESVideoMonitorViewController.m | 16 ++-- ESVideoPhoneSDKZigbee/ESVideoPhoneSDKDemo/ZigBee/ESvideoVideoIntercomViewController.m | 39 ++++++++++--- xamarin/Shared.IOS.ESVideoPhoneSDK/Shared.IOS.ESVideoPhoneSDK.sln | 17 +++++ ESVideoPhoneSDKZigbee/ESVideoPhoneSDKDemo/ZigBee/OpenViewController.m | 30 +++++---- xamarin/ESVideoPhoneSDKXamarin/ESVideoPhoneSDKXamarin/ESvideoVideoIntercomViewController.m | 32 ++++++++-- 7 files changed, 97 insertions(+), 39 deletions(-) diff --git a/ESVideoPhoneSDKDemo1.2/ESVideoPhoneSDKDemo/ESVideoPhoneSDKDemo/ViewController.mm b/ESVideoPhoneSDKDemo1.2/ESVideoPhoneSDKDemo/ESVideoPhoneSDKDemo/ViewController.mm index 8a46522..8a04139 100644 --- a/ESVideoPhoneSDKDemo1.2/ESVideoPhoneSDKDemo/ESVideoPhoneSDKDemo/ViewController.mm +++ b/ESVideoPhoneSDKDemo1.2/ESVideoPhoneSDKDemo/ESVideoPhoneSDKDemo/ViewController.mm @@ -60,7 +60,7 @@ // _mCallOrAccept.enabled = NO; // _monitorBtn.enabled = NO; // _uIDTextField.text = @"JJY000016YWECG";//@"JJY000007FSEYX" 榛樿闂ㄥ彛鏈虹殑ID - _uIDTextField.text = @"JJY000017XLUXX";//@"JJY000007FSEYX" 榛樿闂ㄥ彛鏈虹殑ID + _uIDTextField.text = @"JJY000003UYRBK";//@"JJY000007FSEYX" 榛樿闂ㄥ彛鏈虹殑ID // _uIDTextField.text = @"JJY000016YWECG";//@"JJY000016YWECG" 榛樿闂ㄥ彛鏈虹殑ID _uIDTextField.delegate = self; //鈿狅笍杩欓噷蹇呴』瑕佹鏌ユ槸鍚﹀凡缁忔巿鏉冨惁鍒欎細澶辫触锛屽垵濮嬪寲瑙嗛闊抽閲囬泦 diff --git a/ESVideoPhoneSDKZigbee/ESVideoPhoneSDKDemo/ZigBee/ESVideoMonitorViewController.m b/ESVideoPhoneSDKZigbee/ESVideoPhoneSDKDemo/ZigBee/ESVideoMonitorViewController.m index fbddd12..74b4448 100644 --- a/ESVideoPhoneSDKZigbee/ESVideoPhoneSDKDemo/ZigBee/ESVideoMonitorViewController.m +++ b/ESVideoPhoneSDKZigbee/ESVideoPhoneSDKDemo/ZigBee/ESVideoMonitorViewController.m @@ -140,7 +140,7 @@ -(void)backAction{ [self.navigationController popViewControllerAnimated:true]; -// [self dismissViewControllerAnimated:YES completion:NULL]; + // [self dismissViewControllerAnimated:YES completion:NULL]; } - (UIButton *)moreButton{ @@ -164,7 +164,7 @@ - (void)initCentetView { [self.view addSubview:self.centerView]; - [self.centerView addSubview:self.collectButton]; + // [self.centerView addSubview:self.collectButton]; [self.centerView addSubview:self.homeView]; [self.centerView addSubview:self.screenshotImgBtn]; [self.centerView addSubview:self.screenshotTextBtn]; @@ -487,9 +487,9 @@ UIAlertController *alertController = [UIAlertController alertControllerWithTitle:tipStr message:mes preferredStyle:UIAlertControllerStyleAlert]; [alertController addAction:[UIAlertAction actionWithTitle:okStr style:UIAlertActionStyleDefault handler:^(UIAlertAction * _Nonnull action) { [self backAction]; - }]]; + }]]; - [self presentViewController:alertController animated:YES completion:nil]; + [self presentViewController:alertController animated:YES completion:nil]; } @@ -561,12 +561,12 @@ [self speaker:nil]; // [_mCallOrAccept setTitle:@"閫氳瘽涓�..." forState:UIControlStateNormal]; }else if([phoneEventStr isEqual:@"EVT_HangUp"]){ - -// [CBToast showToastAction:endOfMonitoringStr]; + + // [CBToast showToastAction:endOfMonitoringStr]; [self showUIAlertViewWithBack:endOfMonitoringStr]; -// [self backAction]; - + // [self backAction]; + // [_mCallOrAccept setTitle:@"鍙嶅懠" forState:UIControlStateNormal]; diff --git a/ESVideoPhoneSDKZigbee/ESVideoPhoneSDKDemo/ZigBee/ESvideoVideoIntercomViewController.m b/ESVideoPhoneSDKZigbee/ESVideoPhoneSDKDemo/ZigBee/ESvideoVideoIntercomViewController.m index d9e7ae3..7bdb545 100644 --- a/ESVideoPhoneSDKZigbee/ESVideoPhoneSDKDemo/ZigBee/ESvideoVideoIntercomViewController.m +++ b/ESVideoPhoneSDKZigbee/ESVideoPhoneSDKDemo/ZigBee/ESvideoVideoIntercomViewController.m @@ -80,6 +80,7 @@ NSString * refuseStr; NSString * answerStr; NSString * unlockSuccessfullyStr; + NSString * callingStr; // int openDoorTimeout; //鍏ㄥ眬鍙橀噺 SystemSoundID sound; @@ -92,10 +93,11 @@ [self initTopBarView]; [self initCentetView]; [self initData]; - [self setAnswerBtnEnable:NO]; + // [self setAnswerBtnEnable:NO]; [self initESVideo]; //寮�濮嬪弽鍛� [self StartReverseCall]; + [self ShowCalltimeBtn:callingStr]; // Do any additional setup after loading the view. } @@ -112,6 +114,7 @@ refuseStr = @"鎷掔粷"; answerStr = @"鎺ュ惉"; unlockSuccessfullyStr = @"寮�閿佹垚鍔�"; + callingStr = @"鏉ョ數涓�..."; }else{ tipStr = @"Prompt"; okStr = @"OK"; @@ -120,6 +123,8 @@ refuseStr = @"Refuse"; answerStr = @"Answer"; unlockSuccessfullyStr = @"Unlock successfully"; + callingStr = @"Incoming call"; + } } @@ -151,8 +156,8 @@ -(void)backAction{ [self.navigationController popViewControllerAnimated:true]; -// [self dismissViewControllerAnimated:YES completion:NULL]; - + // [self dismissViewControllerAnimated:YES completion:NULL]; + } - (UIButton *)moreButton{ @@ -173,7 +178,7 @@ - (void)initCentetView { [self.view addSubview:self.centerView]; - [self.centerView addSubview:self.collectButton]; + // [self.centerView addSubview:self.collectButton]; [self.centerView addSubview:self.homeView]; [self.centerView addSubview:self.unlockView]; [self.unlockView addSubview:self.screenshotImgBtn]; @@ -425,18 +430,34 @@ return _calltimeBtn; } + + + -(void)ShowTime:(int)nowTime { if(_calltimeBtn.hidden) _calltimeBtn.hidden = NO; NSString *timeStr = [self timeFormatted:nowTime]; - [self setCalltimeButtonText:timeStr]; + [self setCalltimeButtonText:timeStr isTime:YES]; +} + +-(void)ShowCalltimeBtn:(NSString*) mesStr { + if(_calltimeBtn.hidden) _calltimeBtn.hidden = NO; + + [self setCalltimeButtonText:mesStr isTime:NO]; + + } /* 鏍规嵁鏂囧瓧璋冩暣鎸夐挳瀹� */ --(void)setCalltimeButtonText:(NSString*) mesStr { +-(void)setCalltimeButtonText:(NSString*) mesStr isTime:(BOOL)isTime +{ [_calltimeBtn setTitle:mesStr forState:UIControlStateNormal]; - _calltimeBtn.frame = CGRectMake(0, 0, 100, 30); + if(isTime){ + _calltimeBtn.frame = CGRectMake(0, 0, 80, 30); + }else{ + _calltimeBtn.frame = CGRectMake(0, 0, 115, 30); + } _calltimeBtn.center = CGPointMake(APP_SCREEN_WIDTH/2, 397); } @@ -663,8 +684,8 @@ [alertController addAction:[UIAlertAction actionWithTitle:okStr style:UIAlertActionStyleCancel handler:nil]]; [self presentViewController:alertController animated:YES completion:nil]; -// UIAlertView *alertView1 = [[UIAlertView alloc] initWithTitle:tipStr message:mes delegate:self cancelButtonTitle:okStr otherButtonTitles:nil, nil]; -// [alertView1 show]; + // UIAlertView *alertView1 = [[UIAlertView alloc] initWithTitle:tipStr message:mes delegate:self cancelButtonTitle:okStr otherButtonTitles:nil, nil]; + // [alertView1 show]; } diff --git a/ESVideoPhoneSDKZigbee/ESVideoPhoneSDKDemo/ZigBee/OpenViewController.m b/ESVideoPhoneSDKZigbee/ESVideoPhoneSDKDemo/ZigBee/OpenViewController.m index 8805112..e08f37f 100644 --- a/ESVideoPhoneSDKZigbee/ESVideoPhoneSDKDemo/ZigBee/OpenViewController.m +++ b/ESVideoPhoneSDKZigbee/ESVideoPhoneSDKDemo/ZigBee/OpenViewController.m @@ -40,8 +40,10 @@ [self.view addSubview:self.monitorBtn]; [self.view addSubview:self.calledBtn]; - DEVICEID = @"JJY000017XLUXX"; -// DEVICEID = @"JJY000016YWECG"; + // DEVICEID = @"JJY000017XLUXX"; + DEVICEID = @"JJY000003UYRBK"; + + // DEVICEID = @"JJY000016YWECG"; } @@ -68,16 +70,16 @@ -(void)monitorAction{ ESVideoMonitorViewController *mVc = [[ESVideoMonitorViewController alloc] init]; -// mVc.modalPresentationStyle = UIModalPresentationFullScreen; -// mVc.edgesForExtendedLayout = YES; + // mVc.modalPresentationStyle = UIModalPresentationFullScreen; + // mVc.edgesForExtendedLayout = YES; mVc.deviceName = @"瀹ゅ鏈�"; mVc.roomName = @"2鏍�108"; mVc.mESRoomID = 888; - + // mVc.mESVideoID = @"JJY000007FSEYX"; -// mVc.mESVideoID = @"JJY000016YWECG"; -// mVc.mESVideoID = @"JJY000016YWECG"; - mVc.mESVideoID = DEVICEID; + // mVc.mESVideoID = @"JJY000016YWECG"; + // mVc.mESVideoID = @"JJY000016YWECG"; + mVc.mESVideoID = DEVICEID; mVc.isCollect = self.isCollect; @@ -94,7 +96,7 @@ NSLog(@"CallBack%@",str); }; -// [self presentViewController:mVc animated:YES completion:nil]; + // [self presentViewController:mVc animated:YES completion:nil]; [self.navigationController pushViewController:mVc animated:YES]; @@ -127,13 +129,13 @@ -(void)calledAction{ ESvideoVideoIntercomViewController *mVc = [[ESvideoVideoIntercomViewController alloc] init]; -// mVc.modalPresentationStyle = UIModalPresentationFullScreen; -// mVc.edgesForExtendedLayout = YES; + // mVc.modalPresentationStyle = UIModalPresentationFullScreen; + // mVc.edgesForExtendedLayout = YES; mVc.deviceName = @"瀹ゅ鏈�2"; mVc.roomName = @"3鏍�808"; mVc.mESRoomID = 888; // mVc.mESVideoID = @"JJY000007FSEYX"; -// mVc.mESVideoID = @"JJY000016YWECG"; + // mVc.mESVideoID = @"JJY000016YWECG"; mVc.mESVideoID = DEVICEID; mVc.isCollect = self.isCollect; @@ -149,8 +151,8 @@ NSLog(@"CallBack%@",str); }; -// [self presentViewController:mVc animated:YES completion:nil]; - [self.navigationController pushViewController:mVc animated:YES]; + // [self presentViewController:mVc animated:YES completion:nil]; + [self.navigationController pushViewController:mVc animated:YES]; } diff --git a/xamarin/ESVideoPhoneSDKXamarin/ESVideoPhoneSDKXamarin/ESvideoVideoIntercomViewController.m b/xamarin/ESVideoPhoneSDKXamarin/ESVideoPhoneSDKXamarin/ESvideoVideoIntercomViewController.m index 6d8b1d5..63df999 100644 --- a/xamarin/ESVideoPhoneSDKXamarin/ESVideoPhoneSDKXamarin/ESvideoVideoIntercomViewController.m +++ b/xamarin/ESVideoPhoneSDKXamarin/ESVideoPhoneSDKXamarin/ESvideoVideoIntercomViewController.m @@ -92,10 +92,11 @@ [self initTopBarView]; [self initCentetView]; [self initData]; - [self setAnswerBtnEnable:NO]; +// [self setAnswerBtnEnable:NO]; [self initESVideo]; //寮�濮嬪弽鍛� [self StartReverseCall]; + [self ShowCalltimeBtn:@"瀹ゅ鏈烘潵鐢典腑..."]; // Do any additional setup after loading the view. } @@ -151,7 +152,8 @@ -(void)backAction{ [self.navigationController popViewControllerAnimated:true]; - // [self dismissViewControllerAnimated:YES completion:NULL]; +// [self dismissViewControllerAnimated:YES completion:NULL]; + } - (UIButton *)moreButton{ @@ -424,18 +426,34 @@ return _calltimeBtn; } + + + -(void)ShowTime:(int)nowTime { if(_calltimeBtn.hidden) _calltimeBtn.hidden = NO; NSString *timeStr = [self timeFormatted:nowTime]; - [self setCalltimeButtonText:timeStr]; + [self setCalltimeButtonText:timeStr isTime:YES]; +} + +-(void)ShowCalltimeBtn:(NSString*) mesStr { + if(_calltimeBtn.hidden) _calltimeBtn.hidden = NO; + + [self setCalltimeButtonText:mesStr isTime:NO]; + + } /* 鏍规嵁鏂囧瓧璋冩暣鎸夐挳瀹� */ --(void)setCalltimeButtonText:(NSString*) mesStr { +-(void)setCalltimeButtonText:(NSString*) mesStr isTime:(BOOL)isTime +{ [_calltimeBtn setTitle:mesStr forState:UIControlStateNormal]; - _calltimeBtn.frame = CGRectMake(0, 0, 100, 30); + if(isTime){ + _calltimeBtn.frame = CGRectMake(0, 0, 100, 30); + }else{ + _calltimeBtn.frame = CGRectMake(0, 0, 150, 30); + } _calltimeBtn.center = CGPointMake(APP_SCREEN_WIDTH/2, 397); } @@ -662,8 +680,8 @@ [alertController addAction:[UIAlertAction actionWithTitle:okStr style:UIAlertActionStyleCancel handler:nil]]; [self presentViewController:alertController animated:YES completion:nil]; - // UIAlertView *alertView1 = [[UIAlertView alloc] initWithTitle:tipStr message:mes delegate:self cancelButtonTitle:okStr otherButtonTitles:nil, nil]; - // [alertView1 show]; +// UIAlertView *alertView1 = [[UIAlertView alloc] initWithTitle:tipStr message:mes delegate:self cancelButtonTitle:okStr otherButtonTitles:nil, nil]; +// [alertView1 show]; } diff --git a/xamarin/Shared.IOS.ESVideoPhoneSDK/Library/libESVideoPhoneSDKXamarin.a b/xamarin/Shared.IOS.ESVideoPhoneSDK/Library/libESVideoPhoneSDKXamarin.a index 49eda5e..7a90b67 100644 --- a/xamarin/Shared.IOS.ESVideoPhoneSDK/Library/libESVideoPhoneSDKXamarin.a +++ b/xamarin/Shared.IOS.ESVideoPhoneSDK/Library/libESVideoPhoneSDKXamarin.a Binary files differ diff --git a/xamarin/Shared.IOS.ESVideoPhoneSDK/Shared.IOS.ESVideoPhoneSDK.sln b/xamarin/Shared.IOS.ESVideoPhoneSDK/Shared.IOS.ESVideoPhoneSDK.sln new file mode 100644 index 0000000..9475097 --- /dev/null +++ b/xamarin/Shared.IOS.ESVideoPhoneSDK/Shared.IOS.ESVideoPhoneSDK.sln @@ -0,0 +1,17 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio 15 +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Shared.IOS.ESVideoPhoneSDK", "Shared.IOS.ESVideoPhoneSDK.csproj", "{7953874A-23FD-4619-9F31-D8AE312DAC3C}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {7953874A-23FD-4619-9F31-D8AE312DAC3C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {7953874A-23FD-4619-9F31-D8AE312DAC3C}.Debug|Any CPU.Build.0 = Debug|Any CPU + {7953874A-23FD-4619-9F31-D8AE312DAC3C}.Release|Any CPU.ActiveCfg = Release|Any CPU + {7953874A-23FD-4619-9F31-D8AE312DAC3C}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection +EndGlobal -- Gitblit v1.8.0