Sfoglia il codice sorgente

1.云机连接不上时弹框 提示5

huangxiaodong 7 mesi fa
parent
commit
131ac06e76

+ 7 - 1
创维盒子/双子星云手机/NAS/view/errorAlertTool.m

@@ -136,7 +136,13 @@ static errorAlertTool *shareInstance = nil;
                 self->curDidClickButFun(1);
             }
         } didClickCancel:^{
-            exit(0);
+            if(type == 5){
+                self->curDidClickButFun(5);
+            }
+            else{
+                exit(0);
+            }
+            
         } didClickOther:^{//重启云机
             [weakSelf needToRebootFun];
             

+ 1 - 0
创维盒子/双子星云手机/webRtc/webRtcPlayerViewController.h

@@ -14,6 +14,7 @@
 #import "RcGameWQKeyChain.h"
 #import "ComontAlretViewController.h"
 #import "UIInterface+HXRotation.h"
+#import "errorAlertTool.h"
 
 NS_ASSUME_NONNULL_BEGIN
 

+ 16 - 0
创维盒子/双子星云手机/webRtc/webRtcPlayerViewController.m

@@ -342,6 +342,7 @@
                 if(tryRelinkNum == 6){
                     _didReportWebRtcType = YES;
                     [[webRtcManager shareManager] reportWebRtcRePoportTypeIsChannel:YES withStats:nil];
+                    [self showLinkPhoneErrorFun];
                 }
             }
             
@@ -350,6 +351,21 @@
     }
 }
 
+#pragma mark 云机连接不上
+- (void)showLinkPhoneErrorFun
+{
+    KWeakSelf
+    [[errorAlertTool shareInstance] showNetErrorAlertFun:5 didClickBut:^(NSInteger tag) {
+        if(tag == 1){
+            [weakSelf relinkWebRtcFun];
+        }
+        else if(tag == 5){
+            [weakSelf exitCloudPhoneFun];
+        }
+    }];
+}
+
+
 #pragma mark 控制按钮点击事件
 - (void)controlBtnPressed:(UIButton*)but
 {