Commit 90e14087073a8786462669814c1e3bf6973ebfe8

Authored by yanglingyu
1 parent bb7106cb

0.7.3

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.2'
  11 + s.version = '0.7.3'
12 12 s.summary = '视讯头部一二级菜单组件'
13 13  
14 14 # This description is used to generate tags and improve search results.
... ...
CNLiveVideoClassifyKit/Classes/ClassifyCategory/view/CNCustomChannelListView.m
... ... @@ -35,7 +35,9 @@ static NSString * const headerIdentifier = @"CustomChannelsHeader";
35 35 @end
36 36  
37 37 @implementation CNCustomChannelListView
38   -
  38 +- (void)dealloc{
  39 + [[NSNotificationCenter defaultCenter] removeObserver:self];
  40 +}
39 41 - (instancetype)initWithFrame:(CGRect)frame
40 42 {
41 43 self = [super initWithFrame:frame];
... ... @@ -59,10 +61,18 @@ static NSString * const headerIdentifier = @"CustomChannelsHeader";
59 61 [self addSubview:self.collectionView];
60 62 [self.collectionView registerClass:[CNCustomChannelListCell class] forCellWithReuseIdentifier:reuseIdentifier];
61 63 [self.collectionView registerClass:[CNCustomChannelListReusableView class] forSupplementaryViewOfKind:UICollectionElementKindSectionHeader withReuseIdentifier:headerIdentifier];
62   -
  64 + [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(reloadDataAndRefresh) name:UIApplicationWillEnterForegroundNotification object:nil];
63 65 [self getLocalDataAndRefresh];
64 66 }
65   -
  67 +- (void)reloadDataAndRefresh{
  68 + [self finishAction:self.finishBtn] ;
  69 + [self getLocalDataAndRefresh];
  70 + for (UIView *view in self.collectionView.subviews) {
  71 + if ([view isKindOfClass:[UIView class]]) {
  72 + [view removeFromSuperview];
  73 + }
  74 + }
  75 +}
66 76 - (void)layoutSubviews {
67 77 [super layoutSubviews];
68 78  
... ...