From 6a99d9bf65aa5878cb409945ed2bdbdcb916d047 Mon Sep 17 00:00:00 2001 From: chenqiyang <1406175257@qq.com> Date: 星期五, 02 九月 2022 14:56:40 +0800 Subject: [PATCH] 更新linphone sdk --- HDLLinPhoneSDK(OC)/HDLLinPhoneSDK/HDLLinPhoneSDK.m | 40 ++++++++++++++++++++++++++++++++++++---- 1 files changed, 36 insertions(+), 4 deletions(-) diff --git "a/HDLLinPhoneSDK\357\274\210OC\357\274\211/HDLLinPhoneSDK/HDLLinPhoneSDK.m" "b/HDLLinPhoneSDK\357\274\210OC\357\274\211/HDLLinPhoneSDK/HDLLinPhoneSDK.m" index 75db80f..d8c9735 100644 --- "a/HDLLinPhoneSDK\357\274\210OC\357\274\211/HDLLinPhoneSDK/HDLLinPhoneSDK.m" +++ "b/HDLLinPhoneSDK\357\274\210OC\357\274\211/HDLLinPhoneSDK/HDLLinPhoneSDK.m" @@ -126,11 +126,11 @@ UIViewController *topVC=[HDLLinPhoneCommon topMostController]; if ([topVC isKindOfClass:[HDLLPOnMonitorViewController class]]) { [topVC dismissViewControllerAnimated:NO completion:^{ - [weakSelf toLinphoneIntercomVC:titleName]; + [weakSelf toLinphoneIntercomVC:titleName deviceType:HDLLPType_Default userName:@""]; }]; }else if ([topVC isKindOfClass:[HDLLinphoneIntercomVC class]]) { [topVC dismissViewControllerAnimated:NO completion:^{ - [weakSelf toLinphoneIntercomVC:titleName]; + [weakSelf toLinphoneIntercomVC:titleName deviceType:HDLLPType_Default userName:@""]; }]; } }]; @@ -142,7 +142,7 @@ return; } - [self toLinphoneIntercomVC:titleName]; + [self toLinphoneIntercomVC:titleName deviceType:HDLLPType_Default userName:@""]; // if (self.presentingIntercomVC) { // __weak typeof(self) weakSelf = self; @@ -170,7 +170,37 @@ // }]; } --(void)toLinphoneIntercomVC:(NSString*)titleName{ +/** +* 璺宠浆鑷爺鍛煎彨椤甸潰 +* +* @param titleName 鏍囬 +*/ +-(void)gotoHDLSRLinphoneIntercomVC:(NSString*)titleName userName:(NSString*)username{ + if ([HDLLinPhoneCommon rootPresentVCContent:[HDLLinphoneIntercomVC class]]||[HDLLinPhoneCommon rootPresentVCContent:[HDLLPOnMonitorViewController class]]) { + if ([[HDLLinPhoneCommon topMostController] isKindOfClass:[UIAlertController class]]) { + NSLog(@"椤跺眰瑙嗗浘鏄棰戦�氳瘽椤�"); + __weak typeof(self) weakSelf = self; + + [[HDLLinPhoneCommon topMostController] dismissViewControllerAnimated:NO completion:^{ + UIViewController *topVC=[HDLLinPhoneCommon topMostController]; + if ([topVC isKindOfClass:[HDLLPOnMonitorViewController class]]) { + [topVC dismissViewControllerAnimated:NO completion:^{ + [weakSelf toLinphoneIntercomVC:titleName deviceType:HDLLPType_HDLSR userName:username]; + }]; + }else if ([topVC isKindOfClass:[HDLLinphoneIntercomVC class]]) { + [topVC dismissViewControllerAnimated:NO completion:^{ + [weakSelf toLinphoneIntercomVC:titleName deviceType:HDLLPType_HDLSR userName:username]; + }]; + } + }]; + } + return; + } + + [self toLinphoneIntercomVC:titleName deviceType:HDLLPType_HDLSR userName:username]; +} + +-(void)toLinphoneIntercomVC:(NSString*)titleName deviceType:(HDLLPType)deviceType userName:(NSString *)userName{ HDLLinphoneIntercomVC *vc=[[HDLLinphoneIntercomVC alloc]init]; // vc.CallId=callId; vc.hasVideo=YES; @@ -178,6 +208,8 @@ if (titleName) { vc.titleName=titleName; } + vc.deviceType=deviceType; + vc.userName=userName; vc.modalPresentationStyle = UIModalPresentationFullScreen; // self.presentingIntercomVC=vc; [[HDLLinPhoneCommon topMostController] presentViewController:vc animated:YES completion:^{ -- Gitblit v1.8.0