Commit 34dfc3eb35dace3ac2a6ff84068d6bc50f866e63

Authored by yanglingyu
1 parent be1a571a

0.8.0视讯优化

CNLiveVideoClassifyKit.podspec
... ... @@ -8,7 +8,7 @@
8 8  
9 9 Pod::Spec.new do |s|
10 10 s.name = 'CNLiveVideoClassifyKit'
11   - s.version = '0.7.9'
  11 + s.version = '0.8.0'
12 12 s.summary = '视讯头部一二级菜单组件'
13 13  
14 14 # This description is used to generate tags and improve search results.
... ...
CNLiveVideoClassifyKit/Classes/ClassifyCategory/Controller/CNLiveClassifySegmentController.m
... ... @@ -49,6 +49,8 @@ static const CGFloat animationHeight = 15;
49 49 @property (nonatomic, strong) NSMutableArray *textColors; //未选中字体颜色
50 50 @property (nonatomic, strong) NSMutableArray *textColorSeleteds; //选中字体颜色
51 51  
  52 +@property (nonatomic, strong) NSString *selectID;//选中频道ID
  53 +
52 54 @property (nonatomic, assign) BOOL hasChanged;
53 55 @property (nonatomic, assign) BOOL isEditing;
54 56 @property (nonatomic, assign) BOOL oldStatusBar;
... ... @@ -250,6 +252,14 @@ static const CGFloat animationHeight = 15;
250 252 }
251 253 - (void)uploadSubViews
252 254 {
  255 + if([self.selectID isNotBlank]){
  256 + NSInteger selectIndex = [self containsWithChannelId:self.selectID];
  257 + if (selectIndex != -1){
  258 + self.ld_currentIndex = selectIndex;
  259 + self.myCategoryView.defaultSelectedIndex = self.ld_currentIndex;
  260 + }
  261 + }
  262 +
253 263 if (self.ld_currentIndex>=self.titles.count) {
254 264 self.ld_currentIndex = 0;
255 265 }
... ... @@ -837,6 +847,7 @@ static const CGFloat animationHeight = 15;
837 847 #pragma mark - JXCategoryListContainerViewDelegate
838 848 - (id<JXCategoryListContentViewDelegate>)listContainerView:(JXCategoryListContainerView *)listContainerView initListForIndex:(NSInteger)index{
839 849 CNCategoryGetChannelModel *model = self.dataArray[index];
  850 + self.selectID = model.id;
840 851 BOOL isBlack = NO;
841 852 if (CNLiveStringIsEmpty(model.statusBarColor)) {
842 853 isBlack = YES;
... ... @@ -870,6 +881,7 @@ static const CGFloat animationHeight = 15;
870 881 [self updateSelectColors:index];
871 882 [self configCategoryViewWithType:JXCategoryTitleImageType_OnlyImage selectIndex:index unselectIndex:index];
872 883 CNCategoryGetChannelModel *model = (CNCategoryGetChannelModel *)[self.dataArray wjj_safetyObjectAtIndex:index];
  884 + self.selectID = model.id;
873 885 if (![CNUserShareManager isLogin]) {
874 886 [BHConfig set:ChannelsSelectFirst value:model.id];
875 887 }
... ...
Example/Podfile.lock
... ... @@ -195,7 +195,7 @@ PODS:
195 195 - CNLiveUserManagement (0.1.6):
196 196 - CNLiveEnvironment
197 197 - CNLiveNewTripartiteManagement/MJExtension
198   - - CNLiveVideoClassifyKit (0.7.8):
  198 + - CNLiveVideoClassifyKit (0.7.9):
199 199 - CNLiveBaseKit
200 200 - CNLiveBaseTools
201 201 - CNLiveBeeHive
... ... @@ -655,7 +655,7 @@ SPEC CHECKSUMS:
655 655 CNLiveShareToolKit: 224eeab02d85228b29271eb53ad62f92242fed46
656 656 CNLiveTencentopenapi: d7c4cea634f51cae6aa61286dc3847193246dc6d
657 657 CNLiveUserManagement: 68b965fff76513c371a321b3c34862578718dc26
658   - CNLiveVideoClassifyKit: 80aac88d05899726e976157df316b9c0b52513f7
  658 + CNLiveVideoClassifyKit: 839d07cbcb727fe2b4b08db2cd3c2cc0ed43accc
659 659 JXCategoryView: 7b1ee69ede4843c581688afe84d0f047723262f2
660 660 Masonry: 678fab65091a9290e40e2832a55e7ab731aad201
661 661 MJExtension: 635f2c663dcb1bf76fa4b715b2570a5710aec545
... ... @@ -683,4 +683,4 @@ SPEC CHECKSUMS:
683 683  
684 684 PODFILE CHECKSUM: 6491e4045e4ae937b78cb644deaa04fb626a1aef
685 685  
686   -COCOAPODS: 1.11.3
  686 +COCOAPODS: 1.11.2
... ...