瀏覽代碼

链接点击跳转

zwp 5 月之前
父節點
當前提交
8280c434a6
共有 1 個文件被更改,包括 10 次插入3 次删除
  1. 10 3
      AIIM/Controller/chat/chetCell/chatCellView.m

+ 10 - 3
AIIM/Controller/chat/chetCell/chatCellView.m

@@ -19,6 +19,8 @@
 #import "ChatRecordController.h"
 #import "QuoteDetailController.h"
 #import "UILabel+YBAttributeTextTapAction.h"
+#import <SafariServices/SFSafariViewController.h>
+
 
 // 定义一些常量
 static const CGFloat kTextVerticalMargin = 10.0f;        //  内容垂直边距
@@ -346,14 +348,14 @@ static const CGFloat kMediaCornerRadius = 4.0f;
 //        make.centerY.equalTo(_callContentView);
 //        make.width.height.mas_equalTo(20);
 //    }];
-//    
+//
 //    [callLabel mas_makeConstraints:^(MASConstraintMaker *make) {
 //        make.left.equalTo(callIcon.mas_right).offset(8);
 //        make.top.equalTo(_callContentView).offset(8);
 ////        make.width.mas_lessThanOrEqualTo(70);
 ////        make.right.equalTo(_callContentView).offset(-8);
 //    }];
-//    
+//
 //    [durationLabel mas_makeConstraints:^(MASConstraintMaker *make) {
 //        make.left.equalTo(callLabel.mas_right).offset(8);
 //        make.top.equalTo(callLabel);
@@ -699,7 +701,12 @@ static const CGFloat kMediaCornerRadius = 4.0f;
             NSTextCheckingResult *match=self->_matchesArray[index];
 //            [[UIApplication sharedApplication] openURL:match.URL options:@{} completionHandler:nil];
             // 点击后的操作
-            [FilePreviewer.shared previewFileWithLocalPath:@"" remoteURL:match.URL fromViewController:self.parentViewController];
+           
+            SFSafariViewController *svc = [[SFSafariViewController alloc] initWithURL:match.URL];
+            [self.parentViewController presentViewController:svc animated:YES completion:nil];
+
+            
+//            [FilePreviewer.shared previewFileWithLocalPath:@"" remoteURL:match.URL fromViewController:self.parentViewController];
         }];
     }
     else{