Ver código fonte

1.创维盒子第二个测试版本完整代码上传

huangxiaodong 1 ano atrás
pai
commit
c8daa7c0d2

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

@@ -156,6 +156,8 @@
 		6BF52CA22AD7C2F600A617DB /* inputPWDViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 6BF52CA02AD7C2F600A617DB /* inputPWDViewController.m */; };
 		6BF52CA62AD7D3BE00A617DB /* customLaunchView.h in Headers */ = {isa = PBXBuildFile; fileRef = 6BF52CA42AD7D3BE00A617DB /* customLaunchView.h */; };
 		6BF52CA72AD7D3BE00A617DB /* customLaunchView.m in Sources */ = {isa = PBXBuildFile; fileRef = 6BF52CA52AD7D3BE00A617DB /* customLaunchView.m */; };
+		6BF52CAD2AD82EA500A617DB /* PlayerControlButTipView.h in Headers */ = {isa = PBXBuildFile; fileRef = 6BF52CAB2AD82EA500A617DB /* PlayerControlButTipView.h */; };
+		6BF52CAE2AD82EA500A617DB /* PlayerControlButTipView.m in Sources */ = {isa = PBXBuildFile; fileRef = 6BF52CAC2AD82EA500A617DB /* PlayerControlButTipView.m */; };
 		6C21BF39CEECF8E81BD97788 /* libPods-双子星云手机Tests.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 16C83602E592F43A82A92B3E /* libPods-双子星云手机Tests.a */; };
 		82762E13327622CA8A8512E6 /* libPods-隐私保护-双子星云手机UITests.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 5A7C795CAC690A410AE1E306 /* libPods-隐私保护-双子星云手机UITests.a */; };
 		A00221DB27EAFF4A00E45F78 /* HWAddBookmarkViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = A00221D927EAFF4A00E45F78 /* HWAddBookmarkViewController.m */; };
@@ -459,6 +461,8 @@
 		6BF52CA02AD7C2F600A617DB /* inputPWDViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = inputPWDViewController.m; sourceTree = "<group>"; };
 		6BF52CA42AD7D3BE00A617DB /* customLaunchView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = customLaunchView.h; sourceTree = "<group>"; };
 		6BF52CA52AD7D3BE00A617DB /* customLaunchView.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = customLaunchView.m; sourceTree = "<group>"; };
+		6BF52CAB2AD82EA500A617DB /* PlayerControlButTipView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = PlayerControlButTipView.h; sourceTree = "<group>"; };
+		6BF52CAC2AD82EA500A617DB /* PlayerControlButTipView.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = PlayerControlButTipView.m; sourceTree = "<group>"; };
 		71D630B0FBD97501D316E4AB /* Pods-隐私保护.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-隐私保护.release.xcconfig"; path = "Target Support Files/Pods-隐私保护/Pods-隐私保护.release.xcconfig"; sourceTree = "<group>"; };
 		86FBD9FD629A5194B7C58D9F /* Pods-双子星云手机-双子星云手机UITests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-双子星云手机-双子星云手机UITests.debug.xcconfig"; path = "Target Support Files/Pods-双子星云手机-双子星云手机UITests/Pods-双子星云手机-双子星云手机UITests.debug.xcconfig"; sourceTree = "<group>"; };
 		A00221D827EAFF4A00E45F78 /* HWAddBookmarkViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = HWAddBookmarkViewController.h; sourceTree = "<group>"; };
@@ -872,6 +876,8 @@
 				183AE6B52A8CA0C000B11CB0 /* ShowImageView.m */,
 				187076752A9F400300F15F7F /* PlayerLoadingView.h */,
 				187076762A9F400300F15F7F /* PlayerLoadingView.m */,
+				6BF52CAB2AD82EA500A617DB /* PlayerControlButTipView.h */,
+				6BF52CAC2AD82EA500A617DB /* PlayerControlButTipView.m */,
 			);
 			path = View;
 			sourceTree = "<group>";
@@ -1407,6 +1413,7 @@
 				18C4754F2A8E0DB5006129C0 /* MySetViewController.h in Headers */,
 				18FCE53F2AD136670020F623 /* PlayerViewController+TouchPointXD.h in Headers */,
 				18FCE53E2AD136670020F623 /* PlayerViewController+AdjustBtnFrame.h in Headers */,
+				6BF52CAD2AD82EA500A617DB /* PlayerControlButTipView.h in Headers */,
 				6BF52C972AD5546500A617DB /* SimplePing.h in Headers */,
 				6B3F96342AD2A15A008E349E /* netWorkManager.h in Headers */,
 				184C8ADD2A949DBD00F26650 /* HWVersionModel.h in Headers */,
@@ -1810,6 +1817,7 @@
 				18F9CB002ABD3643003FF71A /* ModifyPWDSecondViewController.m in Sources */,
 				1868201E2AB97BE1005702A6 /* TipsQRCodeViewController.m in Sources */,
 				183AE6092A89CE3C00B11CB0 /* JSONAPI.m in Sources */,
+				6BF52CAE2AD82EA500A617DB /* PlayerControlButTipView.m in Sources */,
 				1810F9002AA1839C00322116 /* PhoneTimeInfoModel.m in Sources */,
 				1823A8262A8601A500CE2913 /* GuideViewController.m in Sources */,
 				18A909992ABC4A3300E6D2BE /* ComontAlretViewController.m in Sources */,

+ 22 - 0
创维盒子/双子星云手机/Assets.xcassets/Player/ControlButTipLine.imageset/Contents.json

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

BIN
创维盒子/双子星云手机/Assets.xcassets/Player/ControlButTipLine.imageset/ControlButTipLine@2x.png


BIN
创维盒子/双子星云手机/Assets.xcassets/Player/ControlButTipLine.imageset/ControlButTipLine@3x.png


+ 1 - 1
创维盒子/双子星云手机/CloudPlayer/PlayerViewController+AdjustBtnFrame.m

@@ -42,7 +42,7 @@
 // 控制按钮3s后 自动靠边算法
 - (void)adjustPlayerViewControlBtnFrame1 {
     
-    CGFloat margin = 70;
+    CGFloat margin = 60/2.0;
     CGFloat W_H = 60;
     mPlayerView.controlBtn.alpha = 0.5;
     

+ 17 - 6
创维盒子/双子星云手机/CloudPlayer/PlayerViewController.mm

@@ -40,6 +40,7 @@
 #import "PhoneTimeInfoModel.h"
 #import "connectDeviceManager.h"
 
+
 typedef enum : NSUInteger {
     BITRATE_EXTREME_SPEED = 2,//极速
     //    BITRATE_HIGH_SPEED = 843000,//高速
@@ -221,8 +222,8 @@ UITextFieldDelegate>
     [self connectVideoServer];
     [self opencommandChannelManagerrc_openURL];
     
-    _timer = [NSTimer scheduledTimerWithTimeInterval:1.0 target:self selector:@selector(timerChange) userInfo:nil repeats:YES];
-    [[NSRunLoop currentRunLoop] addTimer:_timer forMode:NSRunLoopCommonModes];
+//    _timer = [NSTimer scheduledTimerWithTimeInterval:1.0 target:self selector:@selector(timerChange) userInfo:nil repeats:YES];
+//    [[NSRunLoop currentRunLoop] addTimer:_timer forMode:NSRunLoopCommonModes];
 }
 
 - (void)initData
@@ -416,6 +417,12 @@ UITextFieldDelegate>
             
             NSError *error = nil;
             NSDictionary *dataDict = [NSJSONSerialization JSONObjectWithData:message options:NSJSONReadingMutableContainers error:&error];
+            
+            if([dataDict isKindOfClass:[NSDictionary class]]){
+                //[__NSCFString allKeys] unrecognized selector sent to ins
+                return;
+            }
+            
             NSString *messageType = dataDict[@"type"];
             
             if ([messageType isEqualToString:@"cutting"]) {
@@ -903,7 +910,11 @@ UITextFieldDelegate>
         if (mPlayerView.width > mPlayerView.height){
             [mPlayerView.controlBtn setFrame:CGRectMake((mPlayerView.width - h_w_controlBtn)/2.f, mPlayerView.height - h_w_controlBtn - 20.f, h_w_controlBtn, h_w_controlBtn)];
         }else{
-            [mPlayerView.controlBtn setFrame:CGRectMake(mPlayerView.width - h_w_controlBtn - 20.f, (SCREEN_H - h_w_controlBtn)/2.f, h_w_controlBtn, h_w_controlBtn)];
+            //默认居右
+            //[mPlayerView.controlBtn setFrame:CGRectMake(mPlayerView.width - h_w_controlBtn - 20.f, (SCREEN_H - h_w_controlBtn)/2.f, h_w_controlBtn, h_w_controlBtn)];
+            
+            //默认居左
+            [mPlayerView.controlBtn setFrame:CGRectMake( h_w_controlBtn + 10.f, (SCREEN_H - h_w_controlBtn)/2.f, h_w_controlBtn, h_w_controlBtn)];
         }
         
         [mPlayerView.controlBtn setHidden:NO];
@@ -1196,7 +1207,7 @@ UITextFieldDelegate>
 }
 
 - (void)liveStreamManager:(RCLiveSteamManager *)manager didReceiveJitterDelay:(int)jitterDelayMs{
-    
+    HLog(@"延时毫秒:%d",jitterDelayMs)
 }
 
 
@@ -2204,8 +2215,8 @@ static int  couneeee = 0;
     self.concentTime = [iTools getNowTimeStamp];
     self.currentTime = 0;
     
-//    _timer = [NSTimer scheduledTimerWithTimeInterval:1.0 target:self selector:@selector(timerChange) userInfo:nil repeats:YES];
-//    [[NSRunLoop currentRunLoop] addTimer:_timer forMode:NSRunLoopCommonModes];
+    _timer = [NSTimer scheduledTimerWithTimeInterval:1.0 target:self selector:@selector(timerChange) userInfo:nil repeats:YES];
+    [[NSRunLoop currentRunLoop] addTimer:_timer forMode:NSRunLoopCommonModes];
 }
 
 - (void)cancelTimer {

BIN
创维盒子/双子星云手机/CloudPlayer/RCCloudPhoneSDK.framework/RCCloudPhoneSDK


+ 16 - 0
创维盒子/双子星云手机/CloudPlayer/View/PlayerControlButTipView.h

@@ -0,0 +1,16 @@
+//
+//  PlayerControlButTipView.h
+//  隐私保护
+//
+//  Created by xd h on 2023/10/12.
+//
+
+#import <UIKit/UIKit.h>
+
+NS_ASSUME_NONNULL_BEGIN
+
+@interface PlayerControlButTipView : UIView
+
+@end
+
+NS_ASSUME_NONNULL_END

+ 38 - 0
创维盒子/双子星云手机/CloudPlayer/View/PlayerControlButTipView.m

@@ -0,0 +1,38 @@
+//
+//  PlayerControlButTipView.m
+//  隐私保护
+//
+//  Created by xd h on 2023/10/12.
+//
+
+#import "PlayerControlButTipView.h"
+@interface PlayerControlButTipView()
+
+@property(nonatomic,strong)UIImageView *ControlButTipLineImageView;
+
+@end
+@implementation PlayerControlButTipView
+
+- (id)initWithFrame:(CGRect)frame{
+    self = [super initWithFrame:frame];
+    
+    [self drawAnyView];
+    
+    return self;
+}
+
+- (void)drawAnyView{
+    
+    _ControlButTipLineImageView = [[UIImageView alloc] init];
+    _ControlButTipLineImageView.image = [UIImage imageNamed:@"ControlButTipLine"];
+    [self addSubview:_ControlButTipLineImageView];
+    
+    CGFloat curCenterY = SCREEN_H/2.0 + 30;
+    [_ControlButTipLineImageView mas_makeConstraints:^(MASConstraintMaker *make) {
+        make.left.mas_equalTo(10.f);
+        make.height.mas_equalTo(56);
+        make.width.mas_equalTo(16.f);
+        make.bottom.mas_equalTo(-curCenterY);
+    }];
+}
+@end

+ 14 - 1
创维盒子/双子星云手机/CloudPlayer/View/PlayerView.m

@@ -8,6 +8,7 @@
 
 #import "PlayerView.h"
 #import "UIView+View.h"
+#import "PlayerControlButTipView.h"
 
 @interface PlayerView ()
 <UIGestureRecognizerDelegate,
@@ -66,7 +67,7 @@ ShowImageViewDelegate>{
                   inRect:CGRectMake(0, 0, glkshowImageView.drawableWidth, glkshowImageView.drawableHeight)
                 fromRect:[ciImage extent]];
     
-    //[self->glkshowImageView display];
+    [self->glkshowImageView display];
 }
 
 - (void)showIMage
@@ -152,6 +153,18 @@ ShowImageViewDelegate>{
     [self initAddSubViewForBottomContrView];
     
     [self setPoMas_makeWithImageRate:frame.size.width/frame.size.height isOpenVirtual:NO isUsageMode:NO];
+    
+//    PlayerControlButTipView *PlayerControlButTipV = [[PlayerControlButTipView alloc] init];
+//    PlayerControlButTipV.backgroundColor = [UIColor hwColor:@"000000" alpha:0.6];
+//    [self addSubview:PlayerControlButTipV];
+//
+//
+//    [PlayerControlButTipV mas_makeConstraints:^(MASConstraintMaker *make) {
+//        make.right.mas_equalTo(0);
+//        make.top.mas_equalTo(0.f);
+//        make.left.mas_equalTo(0.f);
+//        make.bottom.mas_equalTo(0.f);
+//    }];
 }
 
 - (void)initAddSubViewForBottomContrView{