Commit 12f615a10ed3bde1eef92faa45d41226948d3f8e

Authored by 王军波
1 parent 0b9e891a

添加UGC直播播放

LiveVideoCloud/LiveVideoCloud.xcodeproj/project.pbxproj
... ... @@ -147,6 +147,7 @@
147 147 D25BF87A1E7B8A82007FB138 /* FilterFunctionView.m in Sources */ = {isa = PBXBuildFile; fileRef = D25BF8771E7B8A82007FB138 /* FilterFunctionView.m */; };
148 148 D25BF87B1E7B8A82007FB138 /* SliderView.m in Sources */ = {isa = PBXBuildFile; fileRef = D25BF8791E7B8A82007FB138 /* SliderView.m */; };
149 149 D25BF87D1E7B8C78007FB138 /* KSYGPUResource.bundle in Resources */ = {isa = PBXBuildFile; fileRef = D25BF87C1E7B8C78007FB138 /* KSYGPUResource.bundle */; };
  150 + D25BF8801E7BD266007FB138 /* LVCUGCLivePlayerController.m in Sources */ = {isa = PBXBuildFile; fileRef = D25BF87F1E7BD266007FB138 /* LVCUGCLivePlayerController.m */; };
150 151 D2888D941E6EB8B4003A77C8 /* LVCTabBar.m in Sources */ = {isa = PBXBuildFile; fileRef = D2888D931E6EB8B4003A77C8 /* LVCTabBar.m */; };
151 152 D2888D9E1E6EBF1B003A77C8 /* LVCLiveViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = D2888D9B1E6EBF1B003A77C8 /* LVCLiveViewController.m */; };
152 153 D2888DB11E6EC05F003A77C8 /* TempViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = D2888DB01E6EC05F003A77C8 /* TempViewController.m */; };
... ... @@ -222,7 +223,6 @@
222 223 8112D4301E7927A5002E00F6 /* LVCPlayerLoadingView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = LVCPlayerLoadingView.m; sourceTree = "<group>"; };
223 224 812E504F1E7699DC004F5FCD /* CNLiveMsgTools.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = CNLiveMsgTools.framework; sourceTree = "<group>"; };
224 225 812E50501E7699DC004F5FCD /* CNLivePlayerSDK.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = CNLivePlayerSDK.framework; sourceTree = "<group>"; };
225   - 812E50511E7699DC004F5FCD /* KSYGPUResource.bundle */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.plug-in"; path = KSYGPUResource.bundle; sourceTree = "<group>"; };
226 226 81FB5B3A1E7A6FFC00F98E1D /* SevenSwitch.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SevenSwitch.h; sourceTree = "<group>"; };
227 227 81FB5B3B1E7A6FFC00F98E1D /* SevenSwitch.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SevenSwitch.m; sourceTree = "<group>"; };
228 228 D2029B811E6EAAA50027CD92 /* LiveVideoCloud.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = LiveVideoCloud.app; sourceTree = BUILT_PRODUCTS_DIR; };
... ... @@ -480,6 +480,8 @@
480 480 D25BF8781E7B8A82007FB138 /* SliderView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SliderView.h; sourceTree = "<group>"; };
481 481 D25BF8791E7B8A82007FB138 /* SliderView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SliderView.m; sourceTree = "<group>"; };
482 482 D25BF87C1E7B8C78007FB138 /* KSYGPUResource.bundle */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.plug-in"; path = KSYGPUResource.bundle; sourceTree = "<group>"; };
  483 + D25BF87E1E7BD266007FB138 /* LVCUGCLivePlayerController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LVCUGCLivePlayerController.h; sourceTree = "<group>"; };
  484 + D25BF87F1E7BD266007FB138 /* LVCUGCLivePlayerController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = LVCUGCLivePlayerController.m; sourceTree = "<group>"; };
483 485 D2888D921E6EB8B4003A77C8 /* LVCTabBar.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LVCTabBar.h; sourceTree = "<group>"; };
484 486 D2888D931E6EB8B4003A77C8 /* LVCTabBar.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = LVCTabBar.m; sourceTree = "<group>"; };
485 487 D2888D9A1E6EBF1B003A77C8 /* LVCLiveViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LVCLiveViewController.h; sourceTree = "<group>"; };
... ... @@ -1376,6 +1378,8 @@
1376 1378 810B64E21E779AFE00133E15 /* LVCLivePlayerController.m */,
1377 1379 810B65081E77B39D00133E15 /* LVCFullScreenPlayerController.h */,
1378 1380 810B65091E77B39D00133E15 /* LVCFullScreenPlayerController.m */,
  1381 + D25BF87E1E7BD266007FB138 /* LVCUGCLivePlayerController.h */,
  1382 + D25BF87F1E7BD266007FB138 /* LVCUGCLivePlayerController.m */,
1379 1383 );
1380 1384 path = Controller;
1381 1385 sourceTree = "<group>";
... ... @@ -1550,8 +1554,6 @@
1550 1554 D2029CB01E6EADE10027CD92 /* MJRefresh.bundle in Resources */,
1551 1555 D2575C7C1E76A4F300E3A8FC /* NHFighterView.nib in Resources */,
1552 1556 D25BF87D1E7B8C78007FB138 /* KSYGPUResource.bundle in Resources */,
1553   - D2029B8F1E6EAAA50027CD92 /* Main.storyboard in Resources */,
1554   - 812E50541E7699DC004F5FCD /* KSYGPUResource.bundle in Resources */,
1555 1557 );
1556 1558 runOnlyForDeploymentPostprocessing = 0;
1557 1559 };
... ... @@ -1670,6 +1672,7 @@
1670 1672 D2029BCA1E6EADD70027CD92 /* BaseModel.m in Sources */,
1671 1673 D25BF87B1E7B8A82007FB138 /* SliderView.m in Sources */,
1672 1674 810B65041E779B1F00133E15 /* NSArray+MASAdditions.m in Sources */,
  1675 + D25BF8801E7BD266007FB138 /* LVCUGCLivePlayerController.m in Sources */,
1673 1676 D2029D031E6EAE2E0027CD92 /* UIImage+ZXExtension.m in Sources */,
1674 1677 D2029D0A1E6EAE2E0027CD92 /* ZXServerUrl.m in Sources */,
1675 1678 D2029CCA1E6EADE10027CD92 /* SVProgressHUD.m in Sources */,
... ...
LiveVideoCloud/LiveVideoCloud/Classes/Sections/homeSections/Controller/HomeViewController.m
... ... @@ -10,6 +10,7 @@
10 10 #import "LVCLivePlayerController.h"
11 11 #import "LVCInteractionController.h"
12 12 #import "LVCLivePlayerController.h"
  13 +#import "LVCUGCLivePlayerController.h"
13 14  
14 15 @interface HomeViewController ()
15 16  
... ... @@ -43,6 +44,12 @@
43 44 [liveBtn addTarget:self action:@selector(liveAction) forControlEvents:UIControlEventTouchUpInside];
44 45 [self.view addSubview:liveBtn];
45 46  
  47 + UIButton *UGCLiveBtn = [UIButton buttonWithType:UIButtonTypeCustom];
  48 + UGCLiveBtn.frame = CGRectMake(0, 200, self.view.width, 40);
  49 + [UGCLiveBtn setTitle:@"UGC直播" forState:UIControlStateNormal];
  50 + [UGCLiveBtn addTarget:self action:@selector(UGCLiveAction) forControlEvents:UIControlEventTouchUpInside];
  51 + [self.view addSubview:UGCLiveBtn];
  52 +
46 53 [[UIApplication sharedApplication].keyWindow addSubview:self.interactionBtn];
47 54 }
48 55  
... ... @@ -53,6 +60,12 @@
53 60 [self.navigationController pushViewController:liveVC animated:YES];
54 61 }
55 62  
  63 +- (void)UGCLiveAction
  64 +{
  65 + LVCUGCLivePlayerController *UGCLiveVC = [[LVCUGCLivePlayerController alloc] init];
  66 + [self.navigationController pushViewController:UGCLiveVC animated:YES];
  67 +}
  68 +
56 69 - (void)interactionAction
57 70 {
58 71 LVCInteractionController *intVC = [[LVCInteractionController alloc] init];
... ...
LiveVideoCloud/LiveVideoCloud/Classes/Sections/homeSections/Controller/LVCUGCLivePlayerController.h 0 → 100644
  1 +//
  2 +// LVCUGCLivePlayerController.h
  3 +// LiveVideoCloud
  4 +//
  5 +// Created by cnliveJunBo on 17/3/17.
  6 +// Copyright © 2017年 cnlive. All rights reserved.
  7 +//
  8 +
  9 +#import <UIKit/UIKit.h>
  10 +
  11 +@interface LVCUGCLivePlayerController : UIViewController
  12 +
  13 +@end
... ...
LiveVideoCloud/LiveVideoCloud/Classes/Sections/homeSections/Controller/LVCUGCLivePlayerController.m 0 → 100644
  1 +//
  2 +// LVCUGCLivePlayerController.m
  3 +// LiveVideoCloud
  4 +//
  5 +// Created by cnliveJunBo on 17/3/17.
  6 +// Copyright © 2017年 cnlive. All rights reserved.
  7 +//
  8 +
  9 +#import "LVCUGCLivePlayerController.h"
  10 +
  11 +@interface LVCUGCLivePlayerController ()
  12 +
  13 +@end
  14 +
  15 +@implementation LVCUGCLivePlayerController
  16 +
  17 +- (void)viewWillAppear:(BOOL)animated {
  18 +
  19 + [super viewWillAppear:animated];
  20 +
  21 + self.navigationController.navigationBar.hidden = YES;
  22 +}
  23 +
  24 +- (void)viewWillDisappear:(BOOL)animated {
  25 +
  26 + [super viewWillDisappear:animated];
  27 +
  28 + self.navigationController.navigationBar.hidden = NO;
  29 +}
  30 +
  31 +- (void)viewDidLoad {
  32 + [super viewDidLoad];
  33 +
  34 + self.view.backgroundColor = [UIColor whiteColor];
  35 +}
  36 +
  37 +- (void)didReceiveMemoryWarning {
  38 + [super didReceiveMemoryWarning];
  39 + // Dispose of any resources that can be recreated.
  40 +}
  41 +
  42 +@end
... ...