ソースを参照

1.同步 ---1.我的页面修改

huangxiaodong 6 ヶ月 前
コミット
b2b242a874
共有1 個のファイルを変更した43 個の追加39 個の削除を含む
  1. 43 39
      创维盒子/双子星云手机/mine/mineViewController.m

+ 43 - 39
创维盒子/双子星云手机/mine/mineViewController.m

@@ -1,8 +1,8 @@
 //
 //  mineViewController.m
-//  双子星云手机
 //
-//  Created by xd h on 2024/6/21.
+//
+//  Created David on 2024/6/21.
 //
 
 #import "mineViewController.h"
@@ -13,15 +13,11 @@
 #import "clearCacheAlretViewController.h"
 #import "inputPWDViewController.h"
 #import "customerServiceViewController.h"
-#import "customDownloadCacheManager.h"
 #import "CustomerWebViewController.h"
-
-#import "audioPlayingView.h"
-#import "DFPlayer.h"
-#import "audioPlayerViewController.h"
 #import "scanToPCLoginViewController.h"
 #import "PCLoginViewController.h"
 #import "cloudPhoneModelViewController.h"
+#import "audioPlayerViewController.h"
 
 @interface mineViewController ()
 @property(nonatomic,strong)UIButton *netButton;
@@ -65,7 +61,7 @@
 //    pcScanButton.tag = 100;
 //    [pcScanButton addTarget:self action:@selector(didClickButtonFun:) forControlEvents:UIControlEventTouchUpInside];
 //    [self.view addSubview:pcScanButton];
-//    
+//
 //    [pcScanButton mas_makeConstraints:^(MASConstraintMaker *make) {
 //        make.top.mas_equalTo(50);
 //        make.right.mas_equalTo(-15);
@@ -101,21 +97,6 @@
         make.height.mas_equalTo(20);
     }];
     
-//    UITapGestureRecognizer *tap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(copySnFun)];
-//    [_snLabel addGestureRecognizer:tap];
-    
-    _snCopyButton = [[UIButton alloc] init];
-    _snCopyButton.tag = 1;
-    [_snCopyButton addTarget:self action:@selector(didClickButtonFun:) forControlEvents:UIControlEventTouchUpInside];
-    [self.view addSubview:_snCopyButton];
-    //_snCopyButton.backgroundColor = [UIColor redColor];
-    
-    [_snCopyButton mas_makeConstraints:^(MASConstraintMaker *make) {
-        make.left.mas_equalTo(_snLabel.mas_left);
-        make.top.equalTo(_snLabel.mas_top).offset(-5);
-        make.right.mas_equalTo(_snLabel.mas_right);
-        make.bottom.equalTo(_snLabel.mas_bottom).offset(2);
-    }];
     
     
     _netButton = [[UIButton alloc] init];
@@ -141,6 +122,28 @@
     }];
     
  
+    NSString *SNRightStr = NSLocalizedString(@"common_copy_sn",nil);
+    _snCopyButton = [[UIButton alloc] init];
+    [_snCopyButton setTitle:SNRightStr forState:UIControlStateNormal];
+    [_snCopyButton setTitleColor:[UIColor hwColor:@"#058DFB"] forState:UIControlStateNormal];
+    _snCopyButton.titleLabel.font = [UIFont systemFontOfSize:12.0];
+    _snCopyButton.tag = 1;
+    [_snCopyButton addTarget:self action:@selector(didClickButtonFun:) forControlEvents:UIControlEventTouchUpInside];
+    [self.view addSubview:_snCopyButton];
+    //_snCopyButton.backgroundColor = [UIColor redColor];
+    
+    _snCopyButton.layer.cornerRadius = 12;
+    _snCopyButton.layer.borderWidth = 1.5;
+    _snCopyButton.layer.borderColor = [UIColor hwColor:@"#058DFB"].CGColor;
+    _snCopyButton.layer.masksToBounds = YES;
+    
+    [_snCopyButton mas_makeConstraints:^(MASConstraintMaker *make) {
+        make.width.mas_equalTo(70);
+        make.height.mas_equalTo(24);
+        make.left.equalTo(_netButton.mas_right).offset(10);
+        make.bottom.mas_equalTo(TipImageV.mas_bottom).offset(0);
+    }];
+    
     //常用功能
     _MineCommonUsedV = [[MineCommonUsedView alloc] init];
     [self.view addSubview:_MineCommonUsedV];
@@ -493,22 +496,22 @@
 - (void)setDataFun
 {
     NSString *SNLeftStr = [[NSString alloc] initWithFormat:@"SN:%@",ksharedAppDelegate.DeviceThirdIdMod.data.changeSn];
-    NSString *SNMidStr = @"  |  ";
-    NSString *SNRightStr = NSLocalizedString(@"common_copy",nil);
-    
-    NSString *fullTitle = [[NSString alloc] initWithFormat:@"%@%@%@",SNLeftStr,SNMidStr,SNRightStr];
-    NSMutableAttributedString *attrStr = [[NSMutableAttributedString alloc] initWithString:fullTitle];
-    
-    NSRange midRange = NSMakeRange([fullTitle rangeOfString:SNMidStr].location, [fullTitle rangeOfString:SNMidStr].length);
-    UIColor *midColor =[UIColor hwColor:@"#828D9A" alpha:1.0];
-    [attrStr addAttribute:NSForegroundColorAttributeName value:midColor range:midRange];
-    
-    NSRange rightRange = NSMakeRange([fullTitle rangeOfString:SNRightStr].location, [fullTitle rangeOfString:SNRightStr].length);
-    UIColor *rightColor =[UIColor hwColor:@"#058DFB" alpha:1.0];
-    [attrStr addAttribute:NSForegroundColorAttributeName value:rightColor range:rightRange];
-    
-    _snLabel.attributedText = attrStr;
-    
+//    NSString *SNMidStr = @"  |  ";
+//    NSString *SNRightStr = NSLocalizedString(@"common_copy",nil);
+//
+//    NSString *fullTitle = [[NSString alloc] initWithFormat:@"%@%@%@",SNLeftStr,SNMidStr,SNRightStr];
+//    NSMutableAttributedString *attrStr = [[NSMutableAttributedString alloc] initWithString:fullTitle];
+//
+//    NSRange midRange = NSMakeRange([fullTitle rangeOfString:SNMidStr].location, [fullTitle rangeOfString:SNMidStr].length);
+//    UIColor *midColor =[UIColor hwColor:@"#828D9A" alpha:1.0];
+//    [attrStr addAttribute:NSForegroundColorAttributeName value:midColor range:midRange];
+//
+//    NSRange rightRange = NSMakeRange([fullTitle rangeOfString:SNRightStr].location, [fullTitle rangeOfString:SNRightStr].length);
+//    UIColor *rightColor =[UIColor hwColor:@"#058DFB" alpha:1.0];
+//    [attrStr addAttribute:NSForegroundColorAttributeName value:rightColor range:rightRange];
+//
+//    _snLabel.attributedText = attrStr;
+    _snLabel.text = SNLeftStr;
     
     NSString *NetButText = NSLocalizedString(@"mine_net_LAN",nil);
     if(![pingManager shareManager].isPingOk){
@@ -635,6 +638,7 @@
     
     NSString *tipStr  = NSLocalizedString(@"sn_copy_suc",nil);
     [[iToast makeText:tipStr] show];
+    [[webRtcManager shareManager] updateCopydata];;
 }
 
 #pragma mark PC 获取码登录