修复了消息中心没有关注人的时候中间空白的问题
This commit is contained in:
@@ -26,8 +26,6 @@ NSString * const kMengXinShowReadDotKey = @"kMengXinShowReadDotKey";
|
|||||||
@property (nonatomic, strong) UIStackView *mainStackView;
|
@property (nonatomic, strong) UIStackView *mainStackView;
|
||||||
///工具条
|
///工具条
|
||||||
@property (nonatomic, strong) UIStackView *toolStackView;
|
@property (nonatomic, strong) UIStackView *toolStackView;
|
||||||
///好友容器
|
|
||||||
@property (nonatomic, strong) UIView *friendContentView;
|
|
||||||
///好友列表
|
///好友列表
|
||||||
@property (nonatomic, strong) UICollectionView *collectionView;
|
@property (nonatomic, strong) UICollectionView *collectionView;
|
||||||
|
|
||||||
@@ -198,9 +196,11 @@ NSString * const kMengXinShowReadDotKey = @"kMengXinShowReadDotKey";
|
|||||||
|
|
||||||
- (void)setFriendsArray:(NSArray *)friendsArray {
|
- (void)setFriendsArray:(NSArray *)friendsArray {
|
||||||
_friendsArray = friendsArray;
|
_friendsArray = friendsArray;
|
||||||
if (friendsArray.count) {
|
|
||||||
self.friendContentView.hidden = NO;
|
|
||||||
[self.collectionView reloadData];
|
[self.collectionView reloadData];
|
||||||
|
if (_friendsArray.count > 0) {
|
||||||
|
self.collectionView.hidden = NO;
|
||||||
|
} else {
|
||||||
|
self.collectionView.hidden = YES;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
- (UIStackView *)mainStackView {
|
- (UIStackView *)mainStackView {
|
||||||
@@ -231,13 +231,6 @@ NSString * const kMengXinShowReadDotKey = @"kMengXinShowReadDotKey";
|
|||||||
}
|
}
|
||||||
return _funtionArray;
|
return _funtionArray;
|
||||||
}
|
}
|
||||||
- (UIView *)friendContentView {
|
|
||||||
if (!_friendContentView) {
|
|
||||||
_friendContentView = [[UIView alloc] init];
|
|
||||||
_friendContentView.hidden = YES;
|
|
||||||
}
|
|
||||||
return _friendContentView;
|
|
||||||
}
|
|
||||||
|
|
||||||
- (UICollectionView *)collectionView {
|
- (UICollectionView *)collectionView {
|
||||||
if (!_collectionView) {
|
if (!_collectionView) {
|
||||||
@@ -254,6 +247,7 @@ NSString * const kMengXinShowReadDotKey = @"kMengXinShowReadDotKey";
|
|||||||
_collectionView.backgroundColor = [UIColor clearColor];
|
_collectionView.backgroundColor = [UIColor clearColor];
|
||||||
_collectionView.layer.cornerRadius = 8;
|
_collectionView.layer.cornerRadius = 8;
|
||||||
_collectionView.layer.masksToBounds = YES;
|
_collectionView.layer.masksToBounds = YES;
|
||||||
|
_collectionView.hidden = YES;
|
||||||
_collectionView.showsHorizontalScrollIndicator = NO;
|
_collectionView.showsHorizontalScrollIndicator = NO;
|
||||||
}
|
}
|
||||||
return _collectionView;
|
return _collectionView;
|
||||||
|
Reference in New Issue
Block a user