Commit aa9a756be838e6000939576d19f8622b0ee8b59f
1 parent
ce89cccb
登录时闪退,跳转逻辑修改
Showing
5 changed files
with
12 additions
and
5 deletions
CNLiveVideoClassifyKit.podspec
CNLiveVideoClassifyKit/Classes/Controller/CNCategoryBaseViewController.h
| ... | ... | @@ -15,10 +15,11 @@ NS_ASSUME_NONNULL_BEGIN |
| 15 | 15 | @property (nonatomic, strong) JXCategoryListContainerView *listContainerView; |
| 16 | 16 | @property (nonatomic, strong) NSMutableArray *titles;//标题 |
| 17 | 17 | @property (nonatomic, assign) NSInteger ld_currentIndex; //当前选中 |
| 18 | +@property (nonatomic, assign)BOOL isHiddenFirst;//是否隐藏一级分类 | |
| 18 | 19 | |
| 19 | 20 | -(JXCategoryBaseView *)preferredCategoryView; |
| 20 | 21 | -(CGFloat)preferredCategoryViewHeight; |
| 21 | -- (void)categoryView:(JXCategoryBaseView *)categoryView didSelectedItemAtIndex:(NSInteger)index; | |
| 22 | +- (void)categoryViewSelectedItemAtIndex:(NSInteger)index; | |
| 22 | 23 | @end |
| 23 | 24 | |
| 24 | 25 | NS_ASSUME_NONNULL_END | ... | ... |
CNLiveVideoClassifyKit/Classes/Controller/CNCategoryBaseViewController.m
| ... | ... | @@ -7,6 +7,7 @@ |
| 7 | 7 | |
| 8 | 8 | #import "CNCategoryBaseViewController.h" |
| 9 | 9 | #import "CNLiveListController.h" |
| 10 | +#import "CNLiveListManager.h" | |
| 10 | 11 | |
| 11 | 12 | @interface CNCategoryBaseViewController () |
| 12 | 13 | @end |
| ... | ... | @@ -38,6 +39,12 @@ |
| 38 | 39 | } |
| 39 | 40 | |
| 40 | 41 | #pragma mark - Public |
| 42 | +- (void)categoryViewSelectedItemAtIndex:(NSInteger)index | |
| 43 | +{ | |
| 44 | + self.ld_currentIndex = index; | |
| 45 | + [[CNLiveListManager shareListManager] setIsHiddenFirst:NO]; | |
| 46 | + self.isHiddenFirst = NO; | |
| 47 | +} | |
| 41 | 48 | |
| 42 | 49 | -(JXCategoryBaseView *)preferredCategoryView{ |
| 43 | 50 | return [[JXCategoryBaseView alloc] init]; | ... | ... |
CNLiveVideoClassifyKit/Classes/Controller/CNLiveClassifySegmentController.m
| ... | ... | @@ -52,7 +52,6 @@ static const CGFloat animationHeight = 15; |
| 52 | 52 | @property (nonatomic, assign) BOOL isLoading; |
| 53 | 53 | @property (nonatomic, assign) BOOL isDSShopChanged; |
| 54 | 54 | @property (nonatomic, assign) BOOL contentLogin;//从内容跳过来的 |
| 55 | -@property (nonatomic, assign)BOOL isHiddenFirst;//是否隐藏一级分类 | |
| 56 | 55 | |
| 57 | 56 | @end |
| 58 | 57 | ... | ... |
CNLiveVideoClassifyKit/Classes/Controller/CNLiveSubSegmentController.m
| ... | ... | @@ -22,7 +22,7 @@ |
| 22 | 22 | @property (nonatomic, strong) UIButton *historyBtn;//历史记录 |
| 23 | 23 | @property (nonatomic, strong) UIButton *downloadingBtn;//听见中国下载按钮 |
| 24 | 24 | |
| 25 | -@property (nonatomic, assign)BOOL isHiddenFirst;//是否隐藏一级分类 | |
| 25 | + | |
| 26 | 26 | |
| 27 | 27 | |
| 28 | 28 | @property (nonatomic, strong)NSArray<CNCategoryGetChannelModel*> *pageListArr; |
| ... | ... | @@ -83,7 +83,7 @@ |
| 83 | 83 | } |
| 84 | 84 | if (self.selectChannelId != -1) { |
| 85 | 85 | NSString *classifyId = [BHConfig get:ChannelsSelectSecond]; |
| 86 | - [BHConfig set:ChannelsSelectSecond value:nil]; | |
| 86 | + [BHConfig set:ChannelsSelectSecond value:@""]; | |
| 87 | 87 | if (!CNLiveStringIsEmpty(classifyId)) { |
| 88 | 88 | NSInteger selectChannelId = [self containsWithChannelIndex:self.selectChannelId classifyId:classifyId]; |
| 89 | 89 | if(selectChannelId == -1){ | ... | ... |