Przeglądaj źródła

1.云机内设置页面UI改版本

huangxiaodong 1 tydzień temu
rodzic
commit
7c73c6387c

+ 22 - 0
创维盒子/code/Assets.xcassets/cloudPhone/cloudPhone_set_app_upload.imageset/Contents.json

@@ -0,0 +1,22 @@
+{
+  "images" : [
+    {
+      "idiom" : "universal",
+      "scale" : "1x"
+    },
+    {
+      "filename" : "cloudPhone_set_app_upload@2x.png",
+      "idiom" : "universal",
+      "scale" : "2x"
+    },
+    {
+      "filename" : "cloudPhone_set_app_upload@3x.png",
+      "idiom" : "universal",
+      "scale" : "3x"
+    }
+  ],
+  "info" : {
+    "author" : "xcode",
+    "version" : 1
+  }
+}

BIN
创维盒子/code/Assets.xcassets/cloudPhone/cloudPhone_set_app_upload.imageset/cloudPhone_set_app_upload@2x.png


BIN
创维盒子/code/Assets.xcassets/cloudPhone/cloudPhone_set_app_upload.imageset/cloudPhone_set_app_upload@3x.png


+ 22 - 0
创维盒子/code/Assets.xcassets/cloudPhone/cloudPhone_set_copy.imageset/Contents.json

@@ -0,0 +1,22 @@
+{
+  "images" : [
+    {
+      "idiom" : "universal",
+      "scale" : "1x"
+    },
+    {
+      "filename" : "cloudPhone_set_copy@2x.png",
+      "idiom" : "universal",
+      "scale" : "2x"
+    },
+    {
+      "filename" : "cloudPhone_set_copy@3x.png",
+      "idiom" : "universal",
+      "scale" : "3x"
+    }
+  ],
+  "info" : {
+    "author" : "xcode",
+    "version" : 1
+  }
+}

BIN
创维盒子/code/Assets.xcassets/cloudPhone/cloudPhone_set_copy.imageset/cloudPhone_set_copy@2x.png


BIN
创维盒子/code/Assets.xcassets/cloudPhone/cloudPhone_set_copy.imageset/cloudPhone_set_copy@3x.png


+ 28 - 0
创维盒子/code/CloudPlayer/View/customSwitchButton.h

@@ -0,0 +1,28 @@
+//
+//  customSwitchButton.h
+//  双子星云手机
+//
+//  Created by xd h on 2026/1/5.
+//
+
+#import <UIKit/UIKit.h>
+
+NS_ASSUME_NONNULL_BEGIN
+
+@interface customSwitchButton : UIView
+
+@property (nonatomic, assign, getter=isOn) BOOL on;
+
+@property (nonatomic, assign, getter=isEnabled) BOOL enabled;
+
+@property (nonatomic,copy) void (^didClickSwitchButtonFun)(BOOL isOn);
+
+// 初始化方法
+- (instancetype)initWithFrame:(CGRect)frame
+                     onText:(NSString *)onText
+                    offText:(NSString *)offText;
+
+
+@end
+
+NS_ASSUME_NONNULL_END

+ 285 - 0
创维盒子/code/CloudPlayer/View/customSwitchButton.m

@@ -0,0 +1,285 @@
+//
+//  customSwitchButton.m
+//  双子星云手机
+//
+//  Created by xd h on 2026/1/5.
+//
+
+#import "customSwitchButton.h"
+
+@interface customSwitchButton ()
+
+@property (nonatomic, strong) NSArray<UIColor *> *thumbGradientColors; // 滑块渐变色数组
+
+@property (nonatomic, copy) NSString *onText;   // 打开状态文字
+@property (nonatomic, copy) NSString *offText;  // 关闭状态文字
+@property (nonatomic, strong) UIColor *textColor; // 文字颜色
+@property (nonatomic, strong) UIFont *textFont;   // 文字字体
+
+// 视图组件
+@property (nonatomic, strong) UIView *backgroundView;//整体背景
+@property (nonatomic, strong) UILabel *onLabel;//开提示语
+@property (nonatomic, strong) UILabel *offLabel;//关提示语
+@property (nonatomic, strong) UIView *thumbView;//滑块
+@property (nonatomic, strong) UILabel *thumbLabel;//滑块
+@property (nonatomic, strong) CAGradientLayer *gradientLayer;
+
+
+@property (nonatomic, strong) UIButton *curButton;//处理点击事件
+
+
+@property (nonatomic, assign) BOOL didClickType;   // 用户点击
+@end
+
+@implementation customSwitchButton
+
+// 初始化方法
+- (instancetype)initWithFrame:(CGRect)frame
+                     onText:(NSString *)onText
+                    offText:(NSString *)offText
+{
+    self = [super initWithFrame:frame];
+    if (self) {
+        // 默认值
+        _on = NO;
+
+        _textColor = [UIColor whiteColor];
+        _textFont = [UIFont systemFontOfSize:12.0];
+        
+        // 设置文字
+        _onText = onText ?: @"ON";
+        _offText = offText ?: @"OFF";
+        
+        // 设置渐变色
+        // 默认渐变色:蓝到紫
+        _thumbGradientColors = @[
+            [UIColor hwColor:@"#0CDEFD" alpha:1.0],
+            [UIColor hwColor:@"#058DFB" alpha:1.0]
+        ];
+        
+        [self setupUI];
+        
+    }
+    return self;
+}
+
+- (void)setupUI {
+    // 背景视图
+    self.backgroundView = [[UIView alloc] init];
+    self.backgroundView.layer.cornerRadius = 6;
+    self.backgroundView.layer.masksToBounds = YES;
+    self.backgroundView.backgroundColor = [UIColor hwColor:@"#43536B" alpha:1.0];
+    [self addSubview:self.backgroundView];
+    
+    // 打开状态文字
+    self.onLabel = [[UILabel alloc] init];
+    self.onLabel.text = self.onText;
+    self.onLabel.textColor = self.textColor;
+    self.onLabel.font = self.textFont;
+    self.onLabel.textAlignment = NSTextAlignmentCenter;
+    self.onLabel.alpha = 1.0;
+    [self.backgroundView addSubview:self.onLabel];
+    
+    // 关闭状态文字
+    self.offLabel = [[UILabel alloc] init];
+    self.offLabel.text = self.offText;
+    self.offLabel.textColor = self.textColor;
+    self.offLabel.font = self.textFont;
+    self.offLabel.textAlignment = NSTextAlignmentCenter;
+    self.offLabel.alpha = 1.0;
+    [self.backgroundView addSubview:self.offLabel];
+    
+    // 滑块视图
+   self.thumbView = [[UIView alloc] init];
+   self.thumbView.layer.cornerRadius = 6.0;
+   self.thumbView.layer.masksToBounds = YES;
+   [self addSubview:self.thumbView];
+    
+    
+    // 滑块渐变色层
+    self.gradientLayer = [CAGradientLayer layer];
+    self.gradientLayer.cornerRadius = 6.0;
+    self.gradientLayer.masksToBounds = YES;
+    // 设置渐变方向为左上到右下
+    self.gradientLayer.startPoint = CGPointMake(0, 0.5);
+    self.gradientLayer.endPoint = CGPointMake(0.97, 0.5);
+    
+    // 设置渐变色
+    NSMutableArray *cgColors = [NSMutableArray array];
+    for (UIColor *color in self.thumbGradientColors) {
+        [cgColors addObject:(id)color.CGColor];
+    }
+    self.gradientLayer.colors = cgColors;
+    
+    [self.thumbView.layer insertSublayer:self.gradientLayer atIndex:0];
+    
+    // 滑块上的文字
+    self.thumbLabel = [[UILabel alloc] init];
+    //self.thumbLabel.text = self.offText;
+    self.thumbLabel.textColor = self.textColor;
+    self.thumbLabel.font = self.textFont;
+    self.thumbLabel.textAlignment = NSTextAlignmentCenter;
+    [self.thumbView addSubview:self.thumbLabel];
+    
+    if (_on) {
+        self.thumbLabel.text = self.onText;
+    }
+    else{
+        self.thumbLabel.text = self.offText;
+    }
+    
+    self.curButton = [[UIButton alloc] init];
+    [self.curButton addTarget:self action:@selector(didClickButtonFun:) forControlEvents:UIControlEventTouchUpInside];
+    [self addSubview:self.curButton];
+}
+
+
+
+- (void)layoutSubviews {
+    [super layoutSubviews];
+    
+    // 设置背景视图
+    self.backgroundView.frame = self.bounds;
+    
+    // 设置文字标签位置
+    CGFloat labelWidth = self.frame.size.width/2.0;
+    self.onLabel.frame = CGRectMake(0, 0, labelWidth, self.frame.size.height);
+    self.offLabel.frame = CGRectMake(labelWidth, 0, labelWidth, self.frame.size.height);
+    
+    // 设置滑块位置
+    if (_on) {
+        self.thumbView.frame = self.onLabel.frame;
+    }
+    else{
+        self.thumbView.frame = self.offLabel.frame;
+    }
+    
+    // 设置渐变色层
+    self.gradientLayer.frame = self.thumbView.bounds;
+    
+    // 设置滑块文字
+    self.thumbLabel.frame = self.thumbView.bounds;
+    
+    self.curButton.frame = self.bounds;
+}
+
+#pragma mark - 点击处理
+- (void)didClickButtonFun:(UIButton*)button
+{
+    _didClickType = YES;
+    self.on = !self.on;
+}
+
+
+
+#pragma mark - 公共方法
+
+- (void)setOn:(BOOL)on {
+    [self setOn:on animated:NO];
+}
+
+- (void)setOn:(BOOL)on animated:(BOOL)animated {
+    //if (_on == on) return;
+    
+    _on = on;
+    self.thumbLabel.text = on ? self.onText : self.offText;
+    
+    if (animated) {
+//        self.isAnimating = YES;
+//        [UIView animateWithDuration:0.25 delay:0 options:UIViewAnimationOptionCurveEaseInOut animations:^{
+//            self.thumbView.frame = on ? self.thumbOnPosition : self.thumbOffPosition;
+//            self.backgroundView.backgroundColor = on ? self.onTintColor : self.offTintColor;
+//            self.onLabel.alpha = on ? 1.0 : 0.0;
+//            self.offLabel.alpha = on ? 0.0 : 1.0;
+//        } completion:^(BOOL finished) {
+//            self.isAnimating = NO;
+//        }];
+    } else {
+        self.thumbView.frame = on ? self.onLabel.frame : self.offLabel.frame;
+        //self.backgroundView.backgroundColor = on ? self.onTintColor : self.offTintColor;
+        self.onLabel.alpha = on ? 0.0 : 1.0;
+        self.offLabel.alpha = on ? 1.0 : 0.0;
+    }
+    
+    if(_didClickSwitchButtonFun && _didClickType){
+        _didClickSwitchButtonFun(_on);
+    }
+    _didClickType = NO;
+}
+
+- (void)setOnText:(NSString *)onText {
+    _onText = onText;
+    self.onLabel.text = onText;
+    if (self.isOn) {
+        self.thumbLabel.text = onText;
+    }
+}
+
+- (void)setOffText:(NSString *)offText {
+    _offText = offText;
+    self.offLabel.text = offText;
+    if (!self.isOn) {
+        self.thumbLabel.text = offText;
+    }
+}
+
+- (void)setEnabled:(BOOL)enabled
+{
+    if (enabled) {
+        self.textColor = [UIColor hwColor:@"#FFFFFF" alpha:1.0];
+        
+        // 设置渐变色
+        self.gradientLayer.colors = @[(__bridge NSString *)[UIColor hwColor:@"#0CDEFD" alpha:1.0].CGColor, (__bridge NSString *)[UIColor hwColor:@"#058DFB" alpha:1.0].CGColor];
+        
+    }
+    else{
+        self.textColor = [UIColor hwColor:@"#FFFFFF" alpha:0.2];
+        
+        self.gradientLayer.colors = @[(__bridge NSString *)[UIColor hwColor:@"#485C78" alpha:1.0].CGColor, (__bridge NSString *)[UIColor hwColor:@"#40597F" alpha:1.0].CGColor];
+        
+    }
+    
+    self.curButton.userInteractionEnabled = enabled;
+    
+}
+
+- (void)setOnTintColor:(UIColor *)onTintColor {
+//    _onTintColor = onTintColor;
+//    if (self.isOn) {
+//        self.backgroundView.backgroundColor = onTintColor;
+//    }
+}
+
+- (void)setOffTintColor:(UIColor *)offTintColor {
+//    _offTintColor = offTintColor;
+//    if (!self.isOn) {
+//        self.backgroundView.backgroundColor = offTintColor;
+//    }
+}
+
+- (void)setThumbGradientColors:(NSArray<UIColor *> *)thumbGradientColors {
+//    _thumbGradientColors = thumbGradientColors;
+//    
+//    if (thumbGradientColors && thumbGradientColors.count > 0) {
+//        NSMutableArray *cgColors = [NSMutableArray array];
+//        for (UIColor *color in thumbGradientColors) {
+//            [cgColors addObject:(id)color.CGColor];
+//        }
+//        self.gradientLayer.colors = cgColors;
+//    }
+}
+
+- (void)setTextColor:(UIColor *)textColor {
+    _textColor = textColor;
+    self.onLabel.textColor = textColor;
+    self.offLabel.textColor = textColor;
+}
+
+- (void)setTextFont:(UIFont *)textFont {
+    _textFont = textFont;
+    self.onLabel.font = textFont;
+    self.offLabel.font = textFont;
+    self.thumbLabel.font = textFont;
+}
+
+@end

+ 346 - 289
创维盒子/code/CloudPlayer/View/playerSetView.m

@@ -7,27 +7,38 @@
 
 #import "playerSetView.h"
 #import "SYJUISwitch.h"
+#import "customSwitchButton.h"
 
 @interface playerSetView ()
 @property(nonatomic, strong)UIView* blackBgView;
 
-@property(nonatomic, strong)UIView *bg0View;//1.4.4 新加分辨率
-@property(nonatomic, strong) UIButton *resolution720Button;
-@property(nonatomic, strong) UIButton *resolution1080Button;
-@property(nonatomic,strong) CAGradientLayer *glayer;
+@property(nonatomic, strong) UILabel *delayedLabel;//延时
+@property(nonatomic, strong) UILabel *PacketLossLabel;//丢包
+@property(nonatomic, strong) UILabel *speedLabel;//速度(带宽)
+@property(nonatomic, strong) UILabel *fpsLabel;
+
+//@property(nonatomic, strong)UIView *bg0View;//1.4.4 新加分辨率
+//@property(nonatomic, strong) UIButton *resolution720Button;
+//@property(nonatomic, strong) UIButton *resolution1080Button;
+//@property(nonatomic,strong) CAGradientLayer *glayer;
+
+//1.4.6 UI
+@property(nonatomic, strong)UIView *bg1ViewL;//第一行 左边
+@property(nonatomic, strong) customSwitchButton * resolutionSwitch;//分辨率切换开关
+
+@property(nonatomic, strong)UIView *bg1ViewR;//第一行 右边
+@property(nonatomic, strong) customSwitchButton * bottomNavSwitch;//底部导航栏开关
+
+@property(nonatomic, strong)UIView *bg2ViewL;//第二行 左边
+@property(nonatomic, strong) customSwitchButton * fullScreenSwitch;//全面屏开关
 
 @property(nonatomic, strong) UIView *bg1View;
-@property(nonatomic, strong) SYJUISwitch * bottomNavSwitch;//底部导航栏开关
-@property(nonatomic, strong) SYJUISwitch * fullScreenSwitch;//全面屏开关
+//@property(nonatomic, strong) customSwitchButton * bottomNavSwitch;//底部导航栏开关
+//@property(nonatomic, strong) SYJUISwitch * fullScreenSwitch;//全面屏开关
 @property(nonatomic, strong) UIButton *TVButton;
 @property(nonatomic, strong) UILabel *TVShowLabel;
 @property(nonatomic, strong) UIButton *exitPhoneButton;
 
-@property(nonatomic, strong) UILabel *delayedLabel;//延时
-@property(nonatomic, strong) UILabel *PacketLossLabel;//丢包
-@property(nonatomic, strong) UILabel *speedLabel;//速度(带宽)
-@property(nonatomic, strong) UILabel *fpsLabel;
-
 @end
 
 @implementation playerSetView
@@ -65,7 +76,7 @@
     [self addSubview:_blackBgView];
     
     [_blackBgView mas_makeConstraints:^(MASConstraintMaker *make) {
-        make.height.mas_equalTo(260 + 50);//(256);
+        make.height.mas_equalTo(340);//(256);
         make.width.mas_equalTo(320);//(245);
         make.centerX.mas_equalTo(0.f);
         make.centerY.mas_equalTo(0.f);
@@ -78,21 +89,6 @@
     CGFloat laberW = 30.0;
     CGFloat laberH = 16.0;
     
-    //延迟
-//    UILabel * delayedTipLabel =  [[UILabel alloc] init];
-//    delayedTipLabel.font = [UIFont systemFontOfSize:12.0];
-//    delayedTipLabel.textColor = [UIColor whiteColor];
-//    delayedTipLabel.text = NSLocalizedString(@"webrtc_msg_delayed",nil);
-//    [_blackBgView addSubview:delayedTipLabel];
-//    //delayedTipLabel.backgroundColor = [UIColor redColor];
-//    
-//    [delayedTipLabel mas_makeConstraints:^(MASConstraintMaker *make) {
-//        make.left.mas_equalTo(15);
-//        make.width.mas_equalTo(laberW);
-//        make.height.mas_equalTo(laberH);
-//        make.top.mas_equalTo(laberTop);
-//    }];
-    
     CGFloat fontSize = 12.0;
     
     ///获取设备当前地区的代码和APP语言环境
@@ -125,21 +121,7 @@
         make.top.mas_equalTo(laberTop);
     }];
     
-    //丢包
-//    UILabel * PacketLossTipLabel =  [[UILabel alloc] init];
-//    PacketLossTipLabel.font = [UIFont systemFontOfSize:12.0];
-//    PacketLossTipLabel.textColor = [UIColor whiteColor];
-//    PacketLossTipLabel.text = NSLocalizedString(@"webrtc_msg_PacketLoss",nil);
-//    [blackBgView addSubview:PacketLossTipLabel];
-//    //delayedTipLabel.backgroundColor = [UIColor redColor];
-//    
-//    [PacketLossTipLabel mas_makeConstraints:^(MASConstraintMaker *make) {
-//        make.centerX.mas_equalTo(- 1.5*laberW -10);
-//        make.width.mas_equalTo(laberW);
-//        make.height.mas_equalTo(laberH);
-//        make.top.mas_equalTo(laberTop);
-//    }];
-//    
+    
     _PacketLossLabel =  [[UILabel alloc] init];
     _PacketLossLabel.font = [UIFont systemFontOfSize:fontSize];
     _PacketLossLabel.textAlignment = NSTextAlignmentCenter;
@@ -156,20 +138,6 @@
         make.top.mas_equalTo(laberTop);
     }];
 
-    //带宽
-//    UILabel * speedLossTipLabel =  [[UILabel alloc] init];
-//    speedLossTipLabel.font = [UIFont systemFontOfSize:12.0];
-//    speedLossTipLabel.textColor = [UIColor whiteColor];
-//    speedLossTipLabel.text = NSLocalizedString(@"webrtc_msg_speed",nil);
-//    [blackBgView addSubview:speedLossTipLabel];
-//    //speedLossTipLabel.backgroundColor = [UIColor redColor];
-//
-//    [speedLossTipLabel mas_makeConstraints:^(MASConstraintMaker *make) {
-//        make.centerX.mas_equalTo(1.5*laberW -10);
-//        make.width.mas_equalTo(laberW +10 );
-//        make.height.mas_equalTo(laberH);
-//        make.top.mas_equalTo(laberTop);
-//    }];
     
     _speedLabel =  [[UILabel alloc] init];
     _speedLabel.font = [UIFont systemFontOfSize:fontSize];
@@ -188,176 +156,203 @@
         make.top.mas_equalTo(laberTop);
     }];
     
-    //fps
-//    UILabel * fpsTipLabel =  [[UILabel alloc] init];
-//    fpsTipLabel.font = [UIFont systemFontOfSize:12.0];
-//    fpsTipLabel.textColor = [UIColor whiteColor];
-//    fpsTipLabel.text = @"FPS:";
-//    [blackBgView addSubview:fpsTipLabel];
-//    //speedLossTipLabel.backgroundColor = [UIColor redColor];
-//
-//    [fpsTipLabel mas_makeConstraints:^(MASConstraintMaker *make) {
-//        make.right.mas_equalTo(- 15 - 0.5*laberW);
-//        make.width.mas_equalTo(laberW);
-//        make.height.mas_equalTo(laberH);
-//        make.top.mas_equalTo(laberTop);
-//    }];
-    
-    //_fpsLabel =  [[UILabel alloc] init];
-//    _fpsLabel.textAlignment = NSTextAlignmentRight;
-//    _fpsLabel.font = [UIFont systemFontOfSize:12.0];
-//    _fpsLabel.textColor = [UIColor whiteColor];
-//    //_fpsLabel.text = NSLocalizedString(@"webrtc_msg_delayed",nil);
-//    [_blackBgView addSubview:_fpsLabel];
-//    //_fpsLabel.backgroundColor = [UIColor redColor];
-//    
-//    [_fpsLabel mas_makeConstraints:^(MASConstraintMaker *make) {
-//        make.right.mas_equalTo(-15);
-//        make.width.mas_equalTo(laberW*2);
-//        make.height.mas_equalTo(laberH);
-//        make.top.mas_equalTo(laberTop);
-//    }];
+
     
     [self setWebRctMsgBydelayed:0 withPacketLoss:0.0 withSpeed:@"-" withFPS:@"-"];
     
     /***************************分辨率*******************************************************/
     
-    _bg0View = [UIView new];
-    _bg0View.layer.cornerRadius = 8;
-    _bg0View.backgroundColor = [UIColor hwColor:@"#29313D"];
-    [_blackBgView addSubview:_bg0View];
+//    _bg0View = [UIView new];
+//    _bg0View.layer.cornerRadius = 8;
+//    _bg0View.backgroundColor = [UIColor hwColor:@"#29313D"];
+//    [_blackBgView addSubview:_bg0View];
+//    
+//    [_bg0View mas_makeConstraints:^(MASConstraintMaker *make) {
+//        make.height.mas_equalTo(36);
+//        make.left.mas_equalTo(12);
+//        make.right.mas_equalTo(-12);
+//        //make.top.mas_equalTo(16.f);
+//        make.top.mas_equalTo(62.f);
+//    }];
+//    
+//    //分辨率
+//    UILabel *resolutionTipLabel = [[UILabel alloc] init];
+//    resolutionTipLabel.text = NSLocalizedString(@"cloudPhone_player_set_resolution",nil);
+//    resolutionTipLabel.textColor = [UIColor whiteColor];
+//    resolutionTipLabel.font = [UIFont systemFontOfSize:12.0];
+//    [_bg0View addSubview:resolutionTipLabel];
+//    
+//    [resolutionTipLabel mas_makeConstraints:^(MASConstraintMaker *make) {
+//        make.left.mas_equalTo(15);
+//        make.top.equalTo(_bg0View.mas_top).offset(0);
+//        make.bottom.equalTo(_bg0View.mas_bottom).offset(0);
+//    }];
+//    
+//    _resolution720Button = [[UIButton alloc] init];
+//    _resolution720Button.layer.cornerRadius = 5;
+//    _resolution720Button.backgroundColor = [UIColor hwColor:@"#D8D8D8" alpha:0.09];
+//    [_resolution720Button setTitle:@"720*1280" forState:UIControlStateNormal];
+//    [_resolution720Button setTitleColor:[UIColor hwColor:@"#FFFFFF"] forState:UIControlStateNormal];
+//    _resolution720Button.titleLabel.font = [UIFont systemFontOfSize:12.0];
+//    _resolution720Button.layer.masksToBounds = YES;
+//    [_resolution720Button addTarget:self action:@selector(didClickResolution720ButFun) forControlEvents:UIControlEventTouchUpInside];
+//    [_bg0View addSubview:_resolution720Button];
+//    
+//    [_resolution720Button mas_makeConstraints:^(MASConstraintMaker *make) {
+//        make.left.mas_equalTo(80);
+//        make.width.mas_equalTo(93);
+//        make.height.mas_equalTo(26);
+//        make.centerY.mas_equalTo(0);
+//    }];
+//    
+//    _resolution1080Button = [[UIButton alloc] init];
+//    _resolution1080Button.layer.cornerRadius = 5;
+//    _resolution1080Button.backgroundColor = [UIColor hwColor:@"#D8D8D8" alpha:0.09];
+//    [_resolution1080Button setTitle:@"1080*1920" forState:UIControlStateNormal];
+//    [_resolution1080Button setTitleColor:[UIColor hwColor:@"#FFFFFF"] forState:UIControlStateNormal];
+//    _resolution1080Button.titleLabel.font = [UIFont systemFontOfSize:12.0];
+//    _resolution1080Button.layer.masksToBounds = YES;
+//    [_resolution1080Button addTarget:self action:@selector(didClickResolution1080ButFun) forControlEvents:UIControlEventTouchUpInside];
+//    [_bg0View addSubview:_resolution1080Button];
+//    
+//    [_resolution1080Button mas_makeConstraints:^(MASConstraintMaker *make) {
+//        make.right.mas_equalTo(-12);
+//        make.width.mas_equalTo(93);
+//        make.height.mas_equalTo(26);
+//        make.centerY.mas_equalTo(0);
+//    }];
+//    
+//    // gradient
+//    _glayer = [CAGradientLayer layer];
+//    _glayer.frame = CGRectMake(0, 0, 93, 26);
+//    _glayer.startPoint = CGPointMake(0, 0.5);
+//    _glayer.endPoint = CGPointMake(0.97, 0.5);
+//    _glayer.colors = @[(__bridge id)[UIColor hwColor:@"#0CDEFD" alpha:1.0].CGColor, (__bridge id)[UIColor hwColor:@"#058DFB" alpha:1.0].CGColor];
+//    _glayer.locations = @[@(0), @(1.0f)];
+//    
+//    [self firstSetResolutionFun];
+//
     
-    [_bg0View mas_makeConstraints:^(MASConstraintMaker *make) {
-        make.height.mas_equalTo(36);
-        make.left.mas_equalTo(12);
-        make.right.mas_equalTo(-12);
-        //make.top.mas_equalTo(16.f);
-        make.top.mas_equalTo(62.f);
-    }];
+    /***************************1.4.6新UI*******************************************************/
     
-    //分辨率
-    UILabel *resolutionTipLabel = [[UILabel alloc] init];
-    resolutionTipLabel.text = NSLocalizedString(@"cloudPhone_player_set_resolution",nil);
-    resolutionTipLabel.textColor = [UIColor whiteColor];
-    resolutionTipLabel.font = [UIFont systemFontOfSize:12.0];
-    [_bg0View addSubview:resolutionTipLabel];
+   
     
-    [resolutionTipLabel mas_makeConstraints:^(MASConstraintMaker *make) {
-        make.left.mas_equalTo(15);
-        make.top.equalTo(_bg0View.mas_top).offset(0);
-        make.bottom.equalTo(_bg0View.mas_bottom).offset(0);
-    }];
+    /***************************分辨率*******************************************************/
     
-    _resolution720Button = [[UIButton alloc] init];
-    _resolution720Button.layer.cornerRadius = 5;
-    _resolution720Button.backgroundColor = [UIColor hwColor:@"#D8D8D8" alpha:0.09];
-    [_resolution720Button setTitle:@"720*1280" forState:UIControlStateNormal];
-    [_resolution720Button setTitleColor:[UIColor hwColor:@"#FFFFFF"] forState:UIControlStateNormal];
-    _resolution720Button.titleLabel.font = [UIFont systemFontOfSize:12.0];
-    _resolution720Button.layer.masksToBounds = YES;
-    [_resolution720Button addTarget:self action:@selector(didClickResolution720ButFun) forControlEvents:UIControlEventTouchUpInside];
-    [_bg0View addSubview:_resolution720Button];
-    
-    [_resolution720Button mas_makeConstraints:^(MASConstraintMaker *make) {
-        make.left.mas_equalTo(80);
-        make.width.mas_equalTo(93);
-        make.height.mas_equalTo(26);
-        make.centerY.mas_equalTo(0);
-    }];
+    _bg1ViewL = [UIView new];
+    _bg1ViewL.layer.cornerRadius = 8;
+    _bg1ViewL.backgroundColor = [UIColor hwColor:@"#29313D"];
+    [_blackBgView addSubview:_bg1ViewL];
     
-    _resolution1080Button = [[UIButton alloc] init];
-    _resolution1080Button.layer.cornerRadius = 5;
-    _resolution1080Button.backgroundColor = [UIColor hwColor:@"#D8D8D8" alpha:0.09];
-    [_resolution1080Button setTitle:@"1080*1920" forState:UIControlStateNormal];
-    [_resolution1080Button setTitleColor:[UIColor hwColor:@"#FFFFFF"] forState:UIControlStateNormal];
-    _resolution1080Button.titleLabel.font = [UIFont systemFontOfSize:12.0];
-    _resolution1080Button.layer.masksToBounds = YES;
-    [_resolution1080Button addTarget:self action:@selector(didClickResolution1080ButFun) forControlEvents:UIControlEventTouchUpInside];
-    [_bg0View addSubview:_resolution1080Button];
-    
-    [_resolution1080Button mas_makeConstraints:^(MASConstraintMaker *make) {
-        make.right.mas_equalTo(-12);
-        make.width.mas_equalTo(93);
-        make.height.mas_equalTo(26);
-        make.centerY.mas_equalTo(0);
+    [_bg1ViewL mas_makeConstraints:^(MASConstraintMaker *make) {
+        make.height.mas_equalTo(42);
+        make.left.mas_equalTo(15);
+        make.right.equalTo(self.mas_centerX).offset(-6);
+        make.top.mas_equalTo(56.f);
     }];
     
-    // gradient
-    _glayer = [CAGradientLayer layer];
-    _glayer.frame = CGRectMake(0, 0, 93, 26);
-    _glayer.startPoint = CGPointMake(0, 0.5);
-    _glayer.endPoint = CGPointMake(0.97, 0.5);
-    _glayer.colors = @[(__bridge id)[UIColor hwColor:@"#0CDEFD" alpha:1.0].CGColor, (__bridge id)[UIColor hwColor:@"#058DFB" alpha:1.0].CGColor];
-    _glayer.locations = @[@(0), @(1.0f)];
     
-    [self firstSetResolutionFun];
+    UILabel *bg1ViewLeftTipLab = [[UILabel alloc] init];
+    bg1ViewLeftTipLab.text = NSLocalizedString(@"cloudPhone_player_set_resolution",nil);
+    //bg1ViewLeftTipLab.textAlignment = NSTextAlignmentCenter;
+    bg1ViewLeftTipLab.textColor = [UIColor whiteColor];
+    bg1ViewLeftTipLab.font = [UIFont systemFontOfSize:12.0];
+    [_bg1ViewL addSubview:bg1ViewLeftTipLab];
+
+    [bg1ViewLeftTipLab mas_makeConstraints:^(MASConstraintMaker *make) {
+        make.left.mas_equalTo(8);
+        make.top.mas_equalTo(0);
+        make.bottom.mas_equalTo(0);;
+    }];
     
-    /***************************全面屏相关*******************************************************/
-    _bg1View = [UIView new];
-//    bg1View.layer.cornerRadius = 12;
-//    bg1View.backgroundColor = [UIColor hwColor:@"#29313D"];
-    [_blackBgView addSubview:_bg1View];
+    //开启和关闭多国语言
+    NSString *onStr =  NSLocalizedString(@"UISwitch_open_title",nil);
+    NSString *offStr = NSLocalizedString(@"UISwitch_close_title",nil);
     
-    [_bg1View mas_makeConstraints:^(MASConstraintMaker *make) {
+    _resolutionSwitch = [[customSwitchButton alloc] initWithFrame:CGRectMake(0, 0,80, 26)
+                                                             onText:@"720"
+                                                            offText:@"1080"];
+
+
+
+    [_bg1ViewL addSubview:_resolutionSwitch];
+
+    [_resolutionSwitch mas_makeConstraints:^(MASConstraintMaker *make) {
+            make.right.mas_equalTo(-8.f);
+            make.centerY.mas_equalTo(0.f);
+            make.width.mas_equalTo(80.f);
+            make.height.mas_equalTo(26.f);
+    }];
+
+    KWeakSelf
+    _resolutionSwitch.didClickSwitchButtonFun = ^(BOOL isOn) {
+        [weakSelf maskSwitchPressed:weakSelf.resolutionSwitch];
+    };
+                             
+    /***************************导航栏*******************************************************/
+    _bg1ViewR = [UIView new];
+    _bg1ViewR.layer.cornerRadius = 8;
+    _bg1ViewR.backgroundColor = [UIColor hwColor:@"#29313D"];
+    [_blackBgView addSubview:_bg1ViewR];
+    [_bg1ViewR mas_makeConstraints:^(MASConstraintMaker *make) {
         make.height.mas_equalTo(42);
-        make.left.mas_equalTo(12);
-        make.right.mas_equalTo(-12);
-        make.top.mas_equalTo(112.f);
-        //make.top.mas_equalTo(54.f);
+        make.right.mas_equalTo(-15);
+        make.left.equalTo(self.mas_centerX).offset(6);
+        make.top.mas_equalTo(56.f);
     }];
     
-    UIView *bgBottomNavView = [UIView new];
-    bgBottomNavView.layer.cornerRadius = 8;
-    bgBottomNavView.backgroundColor = [UIColor hwColor:@"#29313D"];
-    [_blackBgView addSubview:bgBottomNavView];
     
-    [bgBottomNavView mas_makeConstraints:^(MASConstraintMaker *make) {
-        make.bottom.mas_equalTo(_bg1View.mas_bottom);
-        make.left.mas_equalTo(12);
-        make.right.equalTo(self.mas_centerX).offset(-6);
-        //make.top.mas_equalTo(16.f);
-        make.top.mas_equalTo(_bg1View.mas_top);
+    UILabel *bg1ViewRightTipLab = [[UILabel alloc] init];
+    bg1ViewRightTipLab.text = NSLocalizedString(@"cloudPhone_nav_show_tip",nil);
+    //bg1ViewRightTipLab.textAlignment = NSTextAlignmentCenter;
+    bg1ViewRightTipLab.textColor = [UIColor whiteColor];
+    bg1ViewRightTipLab.font = [UIFont systemFontOfSize:12.0];
+    [_bg1ViewR addSubview:bg1ViewRightTipLab];
+
+    [bg1ViewRightTipLab mas_makeConstraints:^(MASConstraintMaker *make) {
+        make.left.mas_equalTo(8);
+        make.top.mas_equalTo(0);
+        make.bottom.mas_equalTo(0);;
     }];
     
-    UILabel *navSwitchTipLabel = [[UILabel alloc] init];
-    navSwitchTipLabel.text = NSLocalizedString(@"cloudPhone_nav_show_tip",nil);
-    //navSwitchTipLabel.textAlignment = NSTextAlignmentCenter;
-    navSwitchTipLabel.textColor = [UIColor whiteColor];
-    navSwitchTipLabel.font = [UIFont systemFontOfSize:12.0];
-    [bgBottomNavView addSubview:navSwitchTipLabel];
-    
-    [navSwitchTipLabel mas_makeConstraints:^(MASConstraintMaker *make) {
-        make.left.mas_equalTo(15);
-        make.top.equalTo(bgBottomNavView.mas_top).offset(0);
-        make.bottom.equalTo(bgBottomNavView.mas_bottom).offset(0);
-    }];
+    //开启和关闭多国语言
+    //NSString *onStr =  NSLocalizedString(@"UISwitch_open_title",nil);
+    //NSString *offStr =  NSLocalizedString(@"UISwitch_close_title",nil);
     
-    //底部导航栏开关
-    _bottomNavSwitch = [[SYJUISwitch alloc] initWithFrame:CGRectMake(0, 0, 44, 22)];
-    _bottomNavSwitch.onTintColor = HW13B2EBColor;
-    _bottomNavSwitch.offTintColor = [UIColor hwColor:@"#E3E8F1"];
-    [_bottomNavSwitch addTarget:self action:@selector(maskSwitchPressed:) forControlEvents:UIControlEventValueChanged];
-    [bgBottomNavView addSubview:_bottomNavSwitch];
+    _bottomNavSwitch = [[customSwitchButton alloc] initWithFrame:CGRectMake(0, 0,80, 26)
+                                                             onText:onStr
+                                                            offText:offStr];
+
+
+
+    [_bg1ViewR addSubview:_bottomNavSwitch];
+
     [_bottomNavSwitch mas_makeConstraints:^(MASConstraintMaker *make) {
-        make.right.mas_equalTo(-15.f);
-        make.centerY.mas_equalTo(0.f);
-        make.width.mas_equalTo(44.f);
-        make.height.mas_equalTo(22.f);
+            make.right.mas_equalTo(-8.f);
+            make.centerY.mas_equalTo(0.f);
+            make.width.mas_equalTo(80.f);
+            make.height.mas_equalTo(26.f);
     }];
+
+    _bottomNavSwitch.didClickSwitchButtonFun = ^(BOOL isOn) {
+        [weakSelf maskSwitchPressed:weakSelf.bottomNavSwitch];
+    };
     
     
+    /***************************全面屏相关*******************************************************/
+
+   
     //全面屏开关
-    UIView *bgFullScreenView = [UIView new];
-    bgFullScreenView.layer.cornerRadius = 8;
-    bgFullScreenView.backgroundColor = [UIColor hwColor:@"#29313D"];
-    [_blackBgView addSubview:bgFullScreenView];
+    _bg2ViewL = [UIView new];
+    _bg2ViewL.layer.cornerRadius = 8;
+    _bg2ViewL.backgroundColor = [UIColor hwColor:@"#29313D"];
+    [_blackBgView addSubview:_bg2ViewL];
     
-    [bgFullScreenView mas_makeConstraints:^(MASConstraintMaker *make) {
-        make.bottom.mas_equalTo(_bg1View.mas_bottom);
-        make.right.mas_equalTo(-12);
-        make.left.equalTo(self.mas_centerX).offset(6);
-        //make.top.mas_equalTo(16.f);
-        make.top.mas_equalTo(_bg1View.mas_top);
+    [_bg2ViewL mas_makeConstraints:^(MASConstraintMaker *make) {
+        make.height.mas_equalTo(42);
+        make.left.mas_equalTo(15);
+        make.right.equalTo(self.mas_centerX).offset(-6);
+        make.top.equalTo(_bg1ViewL.mas_bottom).offset(14);
     }];
     
     UILabel *fullScreenTipLabel = [[UILabel alloc] init];
@@ -365,85 +360,111 @@
     //fullScreenTipLabel.textAlignment = NSTextAlignmentCenter;
     fullScreenTipLabel.textColor = [UIColor whiteColor];
     fullScreenTipLabel.font = [UIFont systemFontOfSize:12.0];
-    [bgFullScreenView addSubview:fullScreenTipLabel];
+    [_bg2ViewL addSubview:fullScreenTipLabel];
     
     [fullScreenTipLabel mas_makeConstraints:^(MASConstraintMaker *make) {
-        make.left.mas_equalTo(15);
-        make.top.equalTo(bgFullScreenView.mas_top).offset(0);
-        make.bottom.equalTo(bgFullScreenView.mas_bottom).offset(0);
+        make.left.mas_equalTo(8);
+        make.top.mas_equalTo(0);
+        make.bottom.mas_equalTo(0);;
     }];
     
-    _fullScreenSwitch = [[SYJUISwitch alloc] initWithFrame:CGRectMake(0, 0, 44, 22)];
-    _fullScreenSwitch.onTintColor = HW13B2EBColor;
-    _fullScreenSwitch.offTintColor = [UIColor hwColor:@"#E3E8F1"];
-    [_fullScreenSwitch addTarget:self action:@selector(maskSwitchPressed:) forControlEvents:UIControlEventValueChanged];
-    [bgFullScreenView addSubview:_fullScreenSwitch];
+    //开启和关闭多国语言
+    //NSString *onStr =  NSLocalizedString(@"UISwitch_open_title",nil);
+    //NSString *offStr =  NSLocalizedString(@"UISwitch_close_title",nil);
+    
+    _fullScreenSwitch = [[customSwitchButton alloc] initWithFrame:CGRectMake(0, 0,80, 26)
+                                                             onText:onStr
+                                                            offText:offStr];
+
+
+
+    [_bg2ViewL addSubview:_fullScreenSwitch];
+
     [_fullScreenSwitch mas_makeConstraints:^(MASConstraintMaker *make) {
-        make.right.mas_equalTo(-15.f);
-        make.centerY.mas_equalTo(0.f);
-        make.width.mas_equalTo(44.f);
-        make.height.mas_equalTo(22.f);
+            make.right.mas_equalTo(-8.f);
+            make.centerY.mas_equalTo(0.f);
+            make.width.mas_equalTo(80.f);
+            make.height.mas_equalTo(26.f);
     }];
+
+    _fullScreenSwitch.didClickSwitchButtonFun = ^(BOOL isOn) {
+        [weakSelf maskSwitchPressed:weakSelf.fullScreenSwitch];
+    };
     
     
-    
-    KWeakSelf
+    //KWeakSelf
     dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(0.05 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
         [weakSelf setAllSwitchFun];
     });
     
     
     /**********************************************************************************/
-    UIView *bg2View = [UIView new];
-    bg2View.layer.cornerRadius = 12;
-    bg2View.backgroundColor = [UIColor hwColor:@"#29313D"];
-    [_blackBgView addSubview:bg2View];
-    
-    [bg2View mas_makeConstraints:^(MASConstraintMaker *make) {
-        make.height.mas_equalTo(72);
-        make.left.mas_equalTo(15);
-        make.right.mas_equalTo(-15);
-        make.top.equalTo(_bg1View.mas_bottom).offset(12);
-        //make.top.mas_equalTo(52);
-    }];
+//    UIView *bg2View = [UIView new];
+//    bg2View.layer.cornerRadius = 12;
+//    bg2View.backgroundColor = [UIColor hwColor:@"#29313D"];
+//    [_blackBgView addSubview:bg2View];
+//    
+//    [bg2View mas_makeConstraints:^(MASConstraintMaker *make) {
+//        make.height.mas_equalTo(72);
+//        make.left.mas_equalTo(15);
+//        make.right.mas_equalTo(-15);
+//        make.top.equalTo(_bg1View.mas_bottom).offset(12);
+//        //make.top.mas_equalTo(52);
+//    }];
     
     
-    NSArray *titleArr = @[NSLocalizedString(@"cloudPhone_set_screenshot_tip",nil),
+    NSArray *titleArr = @[NSLocalizedString(@"cloudPhone_set_app_upload_tip",nil),
                           NSLocalizedString(@"my_set_no_TV_p2p",nil),
-                          //NSLocalizedString(@"my_set_no_close_TV_p2p",nil),
+                          NSLocalizedString(@"cloudPhone_set_copy_tip",nil),
+                          NSLocalizedString(@"cloudPhone_set_screenshot_tip",nil),
                           NSLocalizedString(@"my_set_no_restart_phone",nil),
-                          //NSLocalizedString(@"cloudPhone_set_exit_tip",nil),
     ];
     
-    NSArray *imageArr = @[@"cloudPhone_set_screenshot",
+    NSArray *imageArr = @[@"cloudPhone_set_app_upload",
                           @"cloudPhone_set_TV",
+                          @"cloudPhone_set_copy",
+                          @"cloudPhone_set_screenshot",
                           @"cloudPhone_set_restart",
-                          //@"cloudPhone_set_exit",
     ];
     
     
-    CGFloat butTopY = 15.0;
+    //CGFloat butTopY = 15.0;
     CGFloat imageWH = 24.0;
     
-    CGFloat butHeight = imageWH +20 +5;
-    CGFloat butWidth = (320 -15*2)/3.0;  //70.0;
-    //CGFloat butWidth = (245 -12*2)/2.0;  //70.0;
-    CGFloat butSpace = 0.0; //(245  - butWidth*3)/3.0;
+//    CGFloat butHeight = imageWH +20 +5;
+//    CGFloat butWidth = (320 -15*2)/3.0;  //70.0;
+//    //CGFloat butWidth = (245 -12*2)/2.0;  //70.0;
+//    CGFloat butSpace = 0.0; //(245  - butWidth*3)/3.0;
     
     for (int i=0; i<titleArr.count; i++) {
         
         UIButton *but = [[UIButton alloc] init];
         //but.tag = 10+i;
         but.tag = 200+i;
+        but.layer.cornerRadius = 8;
+        but.backgroundColor = [UIColor hwColor:@"#29313D"];
         [but addTarget:self action:@selector(didClickButtonFun:) forControlEvents:UIControlEventTouchUpInside];
-        [bg2View addSubview:but];
+        [_blackBgView addSubview:but];
         //but.backgroundColor = [UIColor greenColor];
         
         [but mas_makeConstraints:^(MASConstraintMaker *make) {
-            make.left.mas_equalTo(butSpace + (butWidth+butSpace)*(i%4));
-            make.width.mas_equalTo(butWidth);
-            make.height.mas_equalTo(butHeight);
-            make.top.mas_equalTo(butTopY + (i/4)* (butHeight + 25) );
+//            make.left.mas_equalTo(butSpace + (butWidth+butSpace)*(i%4));
+//            make.width.mas_equalTo(butWidth);
+//            make.height.mas_equalTo(butHeight);
+//            make.top.mas_equalTo(butTopY + (i/4)* (butHeight + 25) );
+            
+            make.height.mas_equalTo(42);
+            if(i%2 == 0){
+                make.right.mas_equalTo(-15);
+                make.left.equalTo(self.mas_centerX).offset(6);
+            }
+            else{
+                make.left.mas_equalTo(15);
+                make.right.equalTo(self.mas_centerX).offset(-6);
+            }
+            
+            make.top.equalTo(_bg2ViewL.mas_top).offset((ceil(i/2.0)) *(42 + 14));
+            
         }];
         
         UIImageView *imageV = [[UIImageView alloc] init];
@@ -451,10 +472,15 @@
         [but addSubview:imageV];
         
         [imageV mas_makeConstraints:^(MASConstraintMaker *make) {
-            make.centerX.mas_equalTo(0);
+//            make.centerX.mas_equalTo(0);
+//            make.width.mas_equalTo(imageWH);
+//            make.height.mas_equalTo(imageWH);
+//            make.top.mas_equalTo(0);
+            
+            make.centerY.mas_equalTo(0);
             make.width.mas_equalTo(imageWH);
             make.height.mas_equalTo(imageWH);
-            make.top.mas_equalTo(0);
+            make.left.mas_equalTo(16);
         }];
         
         NSString *curText = titleArr[i];
@@ -471,13 +497,23 @@
         //textLabel.backgroundColor = [UIColor redColor];
         
         [textLabel mas_makeConstraints:^(MASConstraintMaker *make) {
-            make.centerX.mas_equalTo(0);
-            make.width.mas_equalTo(butWidth);
+//            make.centerX.mas_equalTo(0);
+//            make.width.mas_equalTo(butWidth);
+//            make.height.mas_equalTo(20);
+//            make.top.equalTo(imageV.mas_bottom).offset(0);
+            
+            make.centerY.mas_equalTo(0);
+            //make.width.mas_equalTo(butWidth);
             make.height.mas_equalTo(20);
-            make.top.equalTo(imageV.mas_bottom).offset(0);
+            make.left.equalTo(imageV.mas_right).offset(8);
         }];
         
-        if(i==1){
+        if(i==0){
+            but.alpha = 0.5;
+            but.enabled = NO;
+            but.userInteractionEnabled = NO;
+        }
+        else if(i==1){
             _TVButton = but;
             _TVShowLabel = textLabel;
             
@@ -498,7 +534,6 @@
     [_exitPhoneButton.titleLabel setFont:[UIFont systemFontOfSize:12.f]];
     _exitPhoneButton.backgroundColor = [UIColor hwColor:@"#29313D"];
     [_blackBgView addSubview:_exitPhoneButton];
-   
 //    if(ksharedAppDelegate.TvStatusMod.isTVShowType){
 //        _TVButton.selected = YES;
 //    }
@@ -507,7 +542,8 @@
         make.height.mas_equalTo(42);
         make.left.mas_equalTo(12);
         make.right.mas_equalTo(-12);
-        make.top.equalTo(bg2View.mas_bottom).offset(12);
+        //make.top.equalTo(bg2View.mas_bottom).offset(12);
+        make.bottom.mas_equalTo(-18);
     }];
     
     [self handleResolutionUIFun];
@@ -520,9 +556,17 @@
     
     BOOL fullscreenType = [HWDataManager getBoolWithKey:Consn_player_full_screen_show];
     [_fullScreenSwitch setOn:fullscreenType];
+    
+    NSInteger curResolution = [HWDataManager getIntegerWithKey:Const_cloudPhone_cur_resolution];
+    if(curResolution == 0 || curResolution == 1){
+        _resolutionSwitch.on = YES;
+    }
+    else{
+        _resolutionSwitch.on = NO;
+    }
 }
 
-- (void)maskSwitchPressed:(SYJUISwitch *)maskSwitch{
+- (void)maskSwitchPressed:(customSwitchButton *)maskSwitch{
     if(_bottomNavSwitch == maskSwitch){
         if (maskSwitch.on) {
             [HWDataManager setBoolWithKey:Consn_player_Nav_hide value:NO];
@@ -556,7 +600,16 @@
         [self handleResolutionUIFun];
         [[NSNotificationCenter defaultCenter] postNotificationName:setPlayerFullScreenNotification object:nil];
     }
-    
+    else if (_resolutionSwitch == maskSwitch){
+        
+        if (maskSwitch.on) {
+            [self didClickResolution720ButFun];
+        }
+        else{
+            [self didClickResolution1080ButFun];
+        }
+
+    }
     //[self removeFun];
 }
 
@@ -660,14 +713,14 @@
 - (void)firstSetResolutionFun
 {
     NSInteger curResolution = [HWDataManager getIntegerWithKey:Const_cloudPhone_cur_resolution];
-    if(curResolution == 0 || curResolution == 1){
-        _resolution720Button.selected = YES;
-        [_resolution720Button.layer insertSublayer:_glayer atIndex:0];
-    }
-    else{
-        _resolution1080Button.selected = YES;
-        [_resolution1080Button.layer insertSublayer:_glayer atIndex:0];
-    }
+//    if(curResolution == 0 || curResolution == 1){
+//        _resolution720Button.selected = YES;
+//        [_resolution720Button.layer insertSublayer:_glayer atIndex:0];
+//    }
+//    else{
+//        _resolution1080Button.selected = YES;
+//        [_resolution1080Button.layer insertSublayer:_glayer atIndex:0];
+//    }
 }
 
 #pragma mark 是否要显示设置分辨率(全面屏要隐藏)
@@ -675,41 +728,45 @@
 {
     BOOL isHide  = [HWDataManager getBoolWithKey:Consn_player_full_screen_show];
     if (isHide) {
-        [_blackBgView mas_updateConstraints:^(MASConstraintMaker *make) {
-            make.height.mas_equalTo(260);//(256);
-        }];
+//        [_blackBgView mas_updateConstraints:^(MASConstraintMaker *make) {
+//            make.height.mas_equalTo(260);//(256);
+//        }];
+//        
+//        _bg0View.hidden = YES;
+//         
+//        [_bg1View mas_updateConstraints:^(MASConstraintMaker *make) {
+//            make.top.mas_equalTo(62);
+//        }];
         
-        _bg0View.hidden = YES;
-         
-        [_bg1View mas_updateConstraints:^(MASConstraintMaker *make) {
-            make.top.mas_equalTo(62);
-        }];
-
+        _bg1ViewL.alpha = 0.5;
+        _resolutionSwitch.enabled = NO;
     }
     else{
+        _bg1ViewL.alpha = 1.0;
+        _resolutionSwitch.enabled = YES;
         
-        [_blackBgView mas_updateConstraints:^(MASConstraintMaker *make) {
-            make.height.mas_equalTo(260 + 50);//(256);
-        }];
-        
-        _bg0View.hidden = NO;
-        
-        [_bg1View mas_updateConstraints:^(MASConstraintMaker *make) {
-            make.top.mas_equalTo(112);
-        }];
+//        [_blackBgView mas_updateConstraints:^(MASConstraintMaker *make) {
+//            make.height.mas_equalTo(260 + 50);//(256);
+//        }];
+//        
+//        _bg0View.hidden = NO;
+//        
+//        [_bg1View mas_updateConstraints:^(MASConstraintMaker *make) {
+//            make.top.mas_equalTo(112);
+//        }];
     }
 }
 
 #pragma mark 点击了分辨率720
 - (void)didClickResolution720ButFun
 {
-    if(_resolution720Button.selected){
-        return;
-    }
-    
-    _resolution1080Button.selected = NO;
-    _resolution720Button.selected = YES;
-    [_resolution720Button.layer insertSublayer:_glayer atIndex:0];
+//    if(_resolution720Button.selected){
+//        return;
+//    }
+//    
+//    _resolution1080Button.selected = NO;
+//    _resolution720Button.selected = YES;
+//    [_resolution720Button.layer insertSublayer:_glayer atIndex:0];
     
     if(_didClickButtonFun){
         _didClickButtonFun(1);
@@ -721,12 +778,12 @@
 #pragma mark 点击了分辨率1080
 - (void)didClickResolution1080ButFun
 {
-    if(_resolution1080Button.selected){
-        return;
-    }
-    _resolution720Button.selected = NO;
-    _resolution1080Button.selected = YES;
-    [_resolution1080Button.layer insertSublayer:_glayer atIndex:0];
+//    if(_resolution1080Button.selected){
+//        return;
+//    }
+//    _resolution720Button.selected = NO;
+//    _resolution1080Button.selected = YES;
+//    [_resolution1080Button.layer insertSublayer:_glayer atIndex:0];
     
     if(_didClickButtonFun){
         _didClickButtonFun(2);

+ 5 - 0
创维盒子/code/en.lproj/Localizable.strings

@@ -691,3 +691,8 @@
 "audio_not_Cache_Tip"      = "This audio is not cached and cannot be listened to offline. Please connect to the network and try again.";
 "Heartbeat_box_restart_Suc_Box" = "Device restarted successfully";
 
+//1.4.6
+"UISwitch_open_title"      = "ON";
+"UISwitch_close_title"      = "OFF";
+"cloudPhone_set_app_upload_tip"      = "APP Upload";
+"cloudPhone_set_copy_tip"      = "clipboard";

+ 7 - 2
创维盒子/code/webRtc/webRtcPlayerViewController.m

@@ -507,13 +507,18 @@
                    [weakSelf didClickSetResolution1080Fun];
                 }
                 break;
-            case 200:
+            case 202:
+                {//剪切板
+                   //[weakSelf didClickshortCatFun];
+                }
+                break;
+            case 203:
                 {//截图
                    [weakSelf didClickshortCatFun];
                 }
                 break;
 #pragma mark 重启盒子
-            case 202:
+            case 204:
                 {
                     [weakSelf didClickRestartFun];
                 }

+ 6 - 0
创维盒子/code/zh-Hans.lproj/Localizable.strings

@@ -686,3 +686,9 @@
 //"alert_install_TV_msg_3"      = "秒。";
 "audio_not_Cache_Tip"      = "这首音频未缓存不能离线听,\n请连接网络后重试。";
 "Heartbeat_box_restart_Suc_Box" = "设备重启成功";
+
+//1.4.6
+"UISwitch_open_title"      = "开启";
+"UISwitch_close_title"      = "关闭";
+"cloudPhone_set_app_upload_tip"      = "应用传输";
+"cloudPhone_set_copy_tip"      = "剪切板";

+ 6 - 0
创维盒子/code/zh-Hant.lproj/Localizable.strings

@@ -690,3 +690,9 @@
 //"alert_install_TV_msg_3"      = "秒。";
 "audio_not_Cache_Tip"      = "這首音訊未緩存不能離線聽,\n請連接網絡後重。";
 "Heartbeat_box_restart_Suc_Box" = "設備重啓成功";
+
+//1.4.6
+"UISwitch_open_title"      = "开启";
+"UISwitch_close_title"      = "關閉";
+"cloudPhone_set_app_upload_tip"      = "應用傳輸";
+"cloudPhone_set_copy_tip"      = "剪切板";

+ 12 - 0
创维盒子/双子星云手机.xcodeproj/project.pbxproj

@@ -264,6 +264,10 @@
 		6B2A946E2F0B5E8C00BFC469 /* KeychainHelper.m in Sources */ = {isa = PBXBuildFile; fileRef = 6B2A946C2F0B5E8C00BFC469 /* KeychainHelper.m */; };
 		6B2A946F2F0B5E8C00BFC469 /* KeychainHelper.m in Sources */ = {isa = PBXBuildFile; fileRef = 6B2A946C2F0B5E8C00BFC469 /* KeychainHelper.m */; };
 		6B2A94702F0B5E8C00BFC469 /* KeychainHelper.h in Headers */ = {isa = PBXBuildFile; fileRef = 6B2A946B2F0B5E8C00BFC469 /* KeychainHelper.h */; };
+		6B2A94792F0B9E7C00BFC469 /* customSwitchButton.m in Sources */ = {isa = PBXBuildFile; fileRef = 6B2A94782F0B9E7C00BFC469 /* customSwitchButton.m */; };
+		6B2A947A2F0B9E7C00BFC469 /* customSwitchButton.h in Headers */ = {isa = PBXBuildFile; fileRef = 6B2A94772F0B9E7C00BFC469 /* customSwitchButton.h */; };
+		6B2A947B2F0B9E7C00BFC469 /* customSwitchButton.h in Headers */ = {isa = PBXBuildFile; fileRef = 6B2A94772F0B9E7C00BFC469 /* customSwitchButton.h */; };
+		6B2A947C2F0B9E7C00BFC469 /* customSwitchButton.m in Sources */ = {isa = PBXBuildFile; fileRef = 6B2A94782F0B9E7C00BFC469 /* customSwitchButton.m */; };
 		6B2C1E1C2C070ADE00FDCF82 /* ZFAVPlayerManager.h in Headers */ = {isa = PBXBuildFile; fileRef = 6B2C1DCC2C070ADE00FDCF82 /* ZFAVPlayerManager.h */; };
 		6B2C1E1D2C070ADE00FDCF82 /* ZFAVPlayerManager.h in Headers */ = {isa = PBXBuildFile; fileRef = 6B2C1DCC2C070ADE00FDCF82 /* ZFAVPlayerManager.h */; };
 		6B2C1E1E2C070ADE00FDCF82 /* ZFAVPlayerManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 6B2C1DCD2C070ADE00FDCF82 /* ZFAVPlayerManager.m */; };
@@ -1806,6 +1810,8 @@
 		6B2A63602D7994660044057A /* customRestartingBoxView.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = customRestartingBoxView.m; sourceTree = "<group>"; };
 		6B2A946B2F0B5E8C00BFC469 /* KeychainHelper.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = KeychainHelper.h; sourceTree = "<group>"; };
 		6B2A946C2F0B5E8C00BFC469 /* KeychainHelper.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = KeychainHelper.m; sourceTree = "<group>"; };
+		6B2A94772F0B9E7C00BFC469 /* customSwitchButton.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = customSwitchButton.h; sourceTree = "<group>"; };
+		6B2A94782F0B9E7C00BFC469 /* customSwitchButton.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = customSwitchButton.m; sourceTree = "<group>"; };
 		6B2C1DCC2C070ADE00FDCF82 /* ZFAVPlayerManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ZFAVPlayerManager.h; sourceTree = "<group>"; };
 		6B2C1DCD2C070ADE00FDCF82 /* ZFAVPlayerManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ZFAVPlayerManager.m; sourceTree = "<group>"; };
 		6B2C1DCF2C070ADE00FDCF82 /* UIImageView+ZFCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIImageView+ZFCache.h"; sourceTree = "<group>"; };
@@ -2757,6 +2763,8 @@
 				6B1CC2C92B67A5FC00AD4217 /* USBInsertPopView.m */,
 				6B6D42EF2C295BCD006CAE3A /* playerSetView.h */,
 				6B6D42F02C295BCD006CAE3A /* playerSetView.m */,
+				6B2A94772F0B9E7C00BFC469 /* customSwitchButton.h */,
+				6B2A94782F0B9E7C00BFC469 /* customSwitchButton.m */,
 			);
 			path = View;
 			sourceTree = "<group>";
@@ -4436,6 +4444,7 @@
 				6BA00E2E2C9AA826003AE520 /* webRtcPlayerViewController+AppDelegate.h in Headers */,
 				6B2C1E902C070ADE00FDCF82 /* ZFPlayerLogManager.h in Headers */,
 				6B1CC2CE2B6B6D6B00AD4217 /* commandSendCheckModel.h in Headers */,
+				6B2A947B2F0B9E7C00BFC469 /* customSwitchButton.h in Headers */,
 				6B0581602AFCD0DF00D37290 /* uploadImageOrVideoViewController.h in Headers */,
 				18F9CB092ABD7835003FF71A /* TipsQRCodeForChangeDeviceViewController.h in Headers */,
 				6B07AC2B2BF8D38F005C2B0E /* NASFileAudioModel.h in Headers */,
@@ -4749,6 +4758,7 @@
 				6BA00E302C9AA826003AE520 /* webRtcPlayerViewController+AppDelegate.h in Headers */,
 				6B2C1E912C070ADE00FDCF82 /* ZFPlayerLogManager.h in Headers */,
 				6BD506F52B9576A4006E7CB0 /* commandSendCheckModel.h in Headers */,
+				6B2A947A2F0B9E7C00BFC469 /* customSwitchButton.h in Headers */,
 				6BD506F62B9576A4006E7CB0 /* uploadImageOrVideoViewController.h in Headers */,
 				6BD506F72B9576A4006E7CB0 /* TipsQRCodeForChangeDeviceViewController.h in Headers */,
 				6B07AC2E2BF8D38F005C2B0E /* NASFileAudioModel.h in Headers */,
@@ -5140,6 +5150,7 @@
 				6BD5072E2B9576A4006E7CB0 /* HWToolListCell.m in Sources */,
 				6BD5072F2B9576A4006E7CB0 /* cloudPhoneExtraFileListModel.m in Sources */,
 				6BCCF1AE2D1E487B00BAF144 /* UpgradeInfoModel.m in Sources */,
+				6B2A94792F0B9E7C00BFC469 /* customSwitchButton.m in Sources */,
 				6BB5731E2C7D6E1D00713351 /* scanToPCLoginViewController.m in Sources */,
 				6B2C1E7F2C070ADE00FDCF82 /* ZFOrientationObserver.m in Sources */,
 				6B42A2202C41040B000555BB /* UIInterface+HXRotation.m in Sources */,
@@ -5535,6 +5546,7 @@
 				A084D68E27E859D300054880 /* HWToolListCell.m in Sources */,
 				6B45C4FE2B57BC87007E6911 /* cloudPhoneExtraFileListModel.m in Sources */,
 				6BCCF1AD2D1E487B00BAF144 /* UpgradeInfoModel.m in Sources */,
+				6B2A947C2F0B9E7C00BFC469 /* customSwitchButton.m in Sources */,
 				6BB5731C2C7D6E1D00713351 /* scanToPCLoginViewController.m in Sources */,
 				6B2C1E7E2C070ADE00FDCF82 /* ZFOrientationObserver.m in Sources */,
 				6B42A21F2C41040B000555BB /* UIInterface+HXRotation.m in Sources */,