Commit 14dfadea2290f16a470b2f81ba56b8078a79cacf

Authored by 张旭
1 parent f9e0f6b5

横屏转竖屏 ---隐藏横屏显示视图

横屏选集-选集 隐藏看点的透明图
metaCode/Classes/Main/HuBiLieHomePage/Controller/CNLiveTVPlayerViewController.swift
... ... @@ -588,7 +588,16 @@ class CNLiveTVPlayerViewController:UIViewController, UITableViewDataSource, UITa
588 588 self.player.orientationDidChanged = {[weak self] player,isFullScreen in
589 589 guard let self = self else { return }
590 590 self.handleScreenCaptureChange()
591   -// self.playHandleScreenCaptureChange(isFullScreen: isFullScreen)
  591 +
  592 +
  593 + if self.player.isFullScreen{
  594 +
  595 + }else{
  596 + //横屏转竖屏时 ,隐藏横屏弹出的视图
  597 + self.controlView.beiSuBgView.isHidden = true
  598 + self.controlView.gaoqingBgView.isHidden = true
  599 + self.controlView.xuanjiBgView.isHidden = true
  600 + }
592 601 }
593 602 var endAssetURL:URL?
594 603 /// 播放完成
... ... @@ -622,7 +631,7 @@ class CNLiveTVPlayerViewController:UIViewController, UITableViewDataSource, UITa
622 631  
623 632  
624 633 }
625   - //横屏看点-选
  634 + // MARK: - 横屏-选集-看点 点击某
626 635 self.controlView.xuanjiBgView.vodPlayerLandscapeXuanjiKanDianSelectBlock = { [weak self] seleIndex,vodPlayBlockListListModel in
627 636 guard let self = self else { return }
628 637 //切换横屏看点视频
... ... @@ -902,7 +911,7 @@ class CNLiveTVPlayerViewController:UIViewController, UITableViewDataSource, UITa
902 911  
903 912  
904 913 }
905   -
  914 + // MARK: - 横屏-选集-专辑 点击某集
906 915 self.controlView.controlXuanjiUpdateBlock = { [weak self] index,albumModel in
907 916 guard let self = self else { return }
908 917 let vodModel = albumModel
... ...
metaCode/Classes/Main/HuBiLieHomePage/View/VodDetail/CNLiveZFPlayerControlView.swift
... ... @@ -144,6 +144,7 @@ class CNLiveZFPlayerControlView:ZFPlayerControlView{
144 144 make.left.right.top.bottom.equalToSuperview()
145 145 }
146 146 self.xuanjiBgView.isHidden = true
  147 + //横屏-选集-专辑 的某集
147 148 self.xuanjiBgView.xuanjiUpdateBlock = {[weak self] index,albumModel in
148 149 guard let self = self else { return }
149 150 //jishuIndex:Int,_ albumModel:CNLiveVodAlbumListModel
... ...
metaCode/Classes/Main/HuBiLieHomePage/View/VodDetail/HengPing/CNLiveVodLandscapeXuanjiView.swift
... ... @@ -95,6 +95,7 @@ class CNLiveVodLandscapeXuanjiView:UIView, UITableViewDataSource, UITableViewDel
95 95 lazy var bgScrollView :UIScrollView = {
96 96 let bgScrollView = UIScrollView()
97 97 bgScrollView.showsVerticalScrollIndicator = false
  98 + bgScrollView.isScrollEnabled = true
98 99 return bgScrollView
99 100 }()
100 101  
... ... @@ -162,6 +163,8 @@ class CNLiveVodLandscapeXuanjiView:UIView, UITableViewDataSource, UITableViewDel
162 163 func setupNewUI(kanDianListArr:NSMutableArray){
163 164 // CNLiveVodPlayblockListListModel
164 165 self.bgScrollView.isHidden = true
  166 +
  167 + self.tableViewBgView.isHidden = false
165 168 self.kandianTableView.isHidden = false
166 169 self.kandianTableView.reloadData()
167 170 }
... ... @@ -186,7 +189,7 @@ class CNLiveVodLandscapeXuanjiView:UIView, UITableViewDataSource, UITableViewDel
186 189 cell.isSelect = false
187 190 }
188 191 cell.vodPlayBlockListListModel = listModel
189   -
  192 + //横屏看点-点击某集
190 193 cell.vodXuanjiKandianCellClickBlock = {[weak self] vodPlayBlockListListModel in
191 194 guard let self = self else { return }
192 195 self.vodPlayerLandscapeXuanjiKanDianSelectBlock?(indexPath.row,vodPlayBlockListListModel ?? CNLiveVodPlayBlockListListModel())
... ... @@ -215,8 +218,10 @@ class CNLiveVodLandscapeXuanjiView:UIView, UITableViewDataSource, UITableViewDel
215 218 // self.realHotCollectionView.reloadData()
216 219  
217 220 self.bgScrollView.isHidden = false
  221 +
  222 + self.tableViewBgView.isHidden = true
218 223 self.kandianTableView.isHidden = true
219   -
  224 +
220 225 let WH:CGFloat = 50.0
221 226 let padding:CGFloat = 13.5
222 227 let maxH = max(KSreenHeight, KSreenWidth)
... ... @@ -231,9 +236,10 @@ class CNLiveVodLandscapeXuanjiView:UIView, UITableViewDataSource, UITableViewDel
231 236 //hangIndex 当前是第几行,1...n
232 237 var hangIndex = 1
233 238  
  239 +
234 240 var maxContentHeight:CGFloat = self.bgScrollView.height
235   - for i in 0..<(model?.list.count ?? 0){
236   - let listMdl = model?.list[i]
  241 + for i in 0..<(model?.list.count ?? 0){//60{//
  242 + let listMdl = model?.list[i]//model?.list[0]//
237 243 let rowH = WH+padding
238 244 let imgX = CGFloat(lieIndex)*(WH+padding)
239 245 let imgY = rowH*CGFloat(hangIndex-1)
... ...