Commit 4bbb404c8a28c17dc2ac88c49cb407bf0e3572bc
1 parent
5541797d
0.4.7
Showing
4 changed files
with
14 additions
and
5 deletions
CNLiveVideoClassifyKit.podspec
| @@ -8,7 +8,7 @@ | @@ -8,7 +8,7 @@ | ||
| 8 | 8 | ||
| 9 | Pod::Spec.new do |s| | 9 | Pod::Spec.new do |s| |
| 10 | s.name = 'CNLiveVideoClassifyKit' | 10 | s.name = 'CNLiveVideoClassifyKit' |
| 11 | - s.version = '0.4.6' | 11 | + s.version = '0.4.7' |
| 12 | s.summary = '视讯头部一二级菜单组件' | 12 | s.summary = '视讯头部一二级菜单组件' |
| 13 | 13 | ||
| 14 | # This description is used to generate tags and improve search results. | 14 | # This description is used to generate tags and improve search results. |
CNLiveVideoClassifyKit/Classes/SearchView/ViewController/CNWitnessSearchDetailController.m
| @@ -80,7 +80,7 @@ static NSString *const CNWitnessSearchPersonCellID = @"CNWitnessSearchPersonCell | @@ -80,7 +80,7 @@ static NSString *const CNWitnessSearchPersonCellID = @"CNWitnessSearchPersonCell | ||
| 80 | }else{ | 80 | }else{ |
| 81 | [[CNLiveListManager shareListManager] removeObserver:self forKeyPath:@"personMessage"]; | 81 | [[CNLiveListManager shareListManager] removeObserver:self forKeyPath:@"personMessage"]; |
| 82 | } | 82 | } |
| 83 | - | 83 | + NSLog(@"CNWitnessSearchDetailController++++++销毁了"); |
| 84 | } | 84 | } |
| 85 | - (instancetype)initWithPageType:(CNWitnessSearchDetailType)type | 85 | - (instancetype)initWithPageType:(CNWitnessSearchDetailType)type |
| 86 | { | 86 | { |
CNLiveVideoClassifyKit/Classes/SearchView/ViewController/CNWitnessSearchListController.m
| @@ -18,6 +18,9 @@ | @@ -18,6 +18,9 @@ | ||
| 18 | @end | 18 | @end |
| 19 | 19 | ||
| 20 | @implementation CNWitnessSearchListController | 20 | @implementation CNWitnessSearchListController |
| 21 | +-(void)dealloc{ | ||
| 22 | + NSLog(@"CNWitnessSearchListController++++++销毁了"); | ||
| 23 | +} | ||
| 21 | 24 | ||
| 22 | - (void)viewDidLoad { | 25 | - (void)viewDidLoad { |
| 23 | [super viewDidLoad]; | 26 | [super viewDidLoad]; |
CNLiveVideoClassifyKit/Classes/SearchView/ViewController/CNWitnessSearchViewController.m
| @@ -45,6 +45,9 @@ static NSString *const CNWitnessSearchHeaderViewID = @"CNWitnessSearchHeaderView | @@ -45,6 +45,9 @@ static NSString *const CNWitnessSearchHeaderViewID = @"CNWitnessSearchHeaderView | ||
| 45 | self.dataSource = [CNWitnessSearchPresent dealHots:self.hots isShowAll:self.isShowAll allHistories:self.histories.copy]; | 45 | self.dataSource = [CNWitnessSearchPresent dealHots:self.hots isShowAll:self.isShowAll allHistories:self.histories.copy]; |
| 46 | [self.collectionView reloadData]; | 46 | [self.collectionView reloadData]; |
| 47 | } | 47 | } |
| 48 | +-(void)dealloc{ | ||
| 49 | + NSLog(@"CNWitnessSearchViewController++++++销毁了"); | ||
| 50 | +} | ||
| 48 | - (void)viewDidLoad { | 51 | - (void)viewDidLoad { |
| 49 | [super viewDidLoad]; | 52 | [super viewDidLoad]; |
| 50 | self.navigationController.interactivePopGestureRecognizer.delegate = self; | 53 | self.navigationController.interactivePopGestureRecognizer.delegate = self; |
| @@ -73,8 +76,11 @@ static NSString *const CNWitnessSearchHeaderViewID = @"CNWitnessSearchHeaderView | @@ -73,8 +76,11 @@ static NSString *const CNWitnessSearchHeaderViewID = @"CNWitnessSearchHeaderView | ||
| 73 | make.top.equalTo(self.collectionView); | 76 | make.top.equalTo(self.collectionView); |
| 74 | make.width.mas_equalTo(kScreenWidth); | 77 | make.width.mas_equalTo(kScreenWidth); |
| 75 | }]; | 78 | }]; |
| 76 | - UIPanGestureRecognizer *pan = [[UIPanGestureRecognizer alloc] initWithTarget:self action:@selector(panGestureEvent:)]; | ||
| 77 | - [self.listVC.view addGestureRecognizer:pan]; | 79 | +} |
| 80 | +- (void)viewDidDisappear:(BOOL)animated{ | ||
| 81 | + [super viewDidDisappear:animated]; | ||
| 82 | + [self removeChild:self.listVC]; | ||
| 83 | + self.listVC = nil; | ||
| 78 | } | 84 | } |
| 79 | - (BOOL)preferredNavigationBarHidden{ | 85 | - (BOOL)preferredNavigationBarHidden{ |
| 80 | return YES; | 86 | return YES; |
| @@ -93,7 +99,7 @@ static NSString *const CNWitnessSearchHeaderViewID = @"CNWitnessSearchHeaderView | @@ -93,7 +99,7 @@ static NSString *const CNWitnessSearchHeaderViewID = @"CNWitnessSearchHeaderView | ||
| 93 | make.left.equalTo(self.view).offset(translation.x); | 99 | make.left.equalTo(self.view).offset(translation.x); |
| 94 | }]; | 100 | }]; |
| 95 | } else if (gesture.state == UIGestureRecognizerStateEnded) { | 101 | } else if (gesture.state == UIGestureRecognizerStateEnded) { |
| 96 | - if (translation.x >= sensitivePosition) { | 102 | + if (translation.x >= sensitivePosition || gesture.numberOfTouches < 0.5) { |
| 97 | [self listViewShow:NO]; | 103 | [self listViewShow:NO]; |
| 98 | }else{ | 104 | }else{ |
| 99 | [self listViewShow:YES]; | 105 | [self listViewShow:YES]; |