temp save: 更好的效果
This commit is contained in:
@@ -38,17 +38,18 @@
|
|||||||
self.textLayout = [YYTextLayout layoutWithContainer:container text:content];
|
self.textLayout = [YYTextLayout layoutWithContainer:container text:content];
|
||||||
|
|
||||||
CGSize textSize = self.textLayout.textBoundingRect.size;
|
CGSize textSize = self.textLayout.textBoundingRect.size;
|
||||||
// CGFloat anotherHeight = [self heightForAttributedStringUsingTextKit:content maxWidth:kRoomMessageMaxWidth];
|
// CGFloat anotherHeight = [self heightForAttributedStringUsingTextKit:content maxWidth:kRoomMessageMaxWidth].height;
|
||||||
self.rowHeight = ceil(textSize.height) + self.contentTopMargin + self.contentBottomMargin + self.cellBottomMargin + 20;
|
|
||||||
if (![NSString isEmpty:self.bubbleImageUrl]) {
|
|
||||||
self.rowHeight += 30;
|
|
||||||
} else {
|
|
||||||
self.rowHeight += 10;
|
|
||||||
}
|
|
||||||
|
|
||||||
if ([self.cellKey isEqualToString:@"ChatMessage"]) {
|
if ([NSString isEmpty:self.bubbleImageUrl]) {
|
||||||
NSLog(@" ----- 11 ----- %@ : %@", [NSValue valueWithCGSize:textSize], [NSValue valueWithCGSize:[self heightForAttributedStringUsingTextKit:content maxWidth:kRoomMessageMaxWidth]]);
|
self.rowHeight = ceil(textSize.height) + self.cellBottomMargin + self.contentTopMargin + 20;
|
||||||
|
} else {
|
||||||
|
self.rowHeight = ceil(textSize.height) + self.contentTopMargin + self.contentBottomMargin + self.cellBottomMargin + 20;
|
||||||
}
|
}
|
||||||
|
self.rowHeight += 10;
|
||||||
|
|
||||||
|
// if ([self.cellKey isEqualToString:@"ChatMessage"]) {
|
||||||
|
// NSLog(@" ----- 11 ----- %@ : %@", [NSValue valueWithCGSize:textSize], [NSValue valueWithCGSize:[self heightForAttributedStringUsingTextKit:content maxWidth:kRoomMessageMaxWidth]]);
|
||||||
|
// }
|
||||||
|
|
||||||
// self.rowHeight = [self heightForAttributedText:content
|
// self.rowHeight = [self heightForAttributedText:content
|
||||||
// maxWidth:kRoomMessageMaxWidth];
|
// maxWidth:kRoomMessageMaxWidth];
|
||||||
|
@@ -14,9 +14,9 @@
|
|||||||
|
|
||||||
- (void)setAttributedText:(NSAttributedString *)attributedText {
|
- (void)setAttributedText:(NSAttributedString *)attributedText {
|
||||||
NSMutableAttributedString* attributedTextCopy = [attributedText mutableCopy];
|
NSMutableAttributedString* attributedTextCopy = [attributedText mutableCopy];
|
||||||
CGSize maxSize = CGSizeMake(kRoomMessageMaxWidth - 24, MAXFLOAT);
|
|
||||||
|
CGSize maxSize = CGSizeMake(kRoomMessageMaxWidth, MAXFLOAT);
|
||||||
self.maxWidth = maxSize.width - 8;
|
self.maxWidth = maxSize.width;
|
||||||
|
|
||||||
CGSize size = [attributedText boundingRectWithSize:maxSize
|
CGSize size = [attributedText boundingRectWithSize:maxSize
|
||||||
options:NSStringDrawingUsesFontLeading | NSStringDrawingUsesLineFragmentOrigin
|
options:NSStringDrawingUsesFontLeading | NSStringDrawingUsesLineFragmentOrigin
|
||||||
@@ -50,7 +50,7 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
self.textWidth = layout.textBoundingRect.size.width;
|
self.textWidth = layout.textBoundingRect.size.width + 12;
|
||||||
|
|
||||||
[super setAttributedText:attributedTextCopy];
|
[super setAttributedText:attributedTextCopy];
|
||||||
}
|
}
|
||||||
@@ -65,8 +65,8 @@
|
|||||||
size = CGSizeMake(imageView.bounds.size.height * scale, imageView.bounds.size.height);
|
size = CGSizeMake(imageView.bounds.size.height * scale, imageView.bounds.size.height);
|
||||||
imageView.bounds = CGRectMake(0, 0, size.width, size.height);
|
imageView.bounds = CGRectMake(0, 0, size.width, size.height);
|
||||||
}else{
|
}else{
|
||||||
size = CGSizeMake(16, 16);
|
size = CGSizeMake(18, 18);
|
||||||
imageView.bounds = CGRectMake(0, 0, 16, 16);
|
imageView.bounds = CGRectMake(0, 0, 18, 18);
|
||||||
}
|
}
|
||||||
NSMutableAttributedString * replaceAttr = [NSMutableAttributedString yy_attachmentStringWithContent:imageView
|
NSMutableAttributedString * replaceAttr = [NSMutableAttributedString yy_attachmentStringWithContent:imageView
|
||||||
contentMode:UIViewContentModeScaleAspectFit
|
contentMode:UIViewContentModeScaleAspectFit
|
||||||
|
@@ -27,6 +27,8 @@
|
|||||||
@property (nonatomic,strong) XPNetImageYYLabel *contentLabel;
|
@property (nonatomic,strong) XPNetImageYYLabel *contentLabel;
|
||||||
///点击空白区域的手势
|
///点击空白区域的手势
|
||||||
@property (nonatomic,strong) UITapGestureRecognizer *tapEmptyRecognizer;
|
@property (nonatomic,strong) UITapGestureRecognizer *tapEmptyRecognizer;
|
||||||
|
|
||||||
|
@property(nonatomic, strong) UIVisualEffectView *blurEffectView;
|
||||||
@end
|
@end
|
||||||
|
|
||||||
@implementation XPRoomMessageTableViewCell
|
@implementation XPRoomMessageTableViewCell
|
||||||
@@ -45,8 +47,9 @@
|
|||||||
self.contentView.clipsToBounds = NO;
|
self.contentView.clipsToBounds = NO;
|
||||||
|
|
||||||
self.selectionStyle = UITableViewCellSelectionStyleNone;
|
self.selectionStyle = UITableViewCellSelectionStyleNone;
|
||||||
self.backgroundColor = [UIColor colorWithRed:arc4random()%255/255.0 green:arc4random()%255/255.0 blue:arc4random()%255/255.0 alpha:0.4];//[UIColor clearColor];
|
self.backgroundColor = [UIColor clearColor];
|
||||||
[self.contentView addSubview:self.bubbleImageView];
|
[self.contentView addSubview:self.bubbleImageView];
|
||||||
|
[self.contentView addSubview:self.blurEffectView];
|
||||||
[self.contentView addSubview:self.contentLabel];
|
[self.contentView addSubview:self.contentLabel];
|
||||||
UITapGestureRecognizer * tap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(didTap)];
|
UITapGestureRecognizer * tap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(didTap)];
|
||||||
tap.delegate = self;
|
tap.delegate = self;
|
||||||
@@ -59,9 +62,9 @@
|
|||||||
- (void)initSubViewConstraints {
|
- (void)initSubViewConstraints {
|
||||||
|
|
||||||
[self.bubbleImageView mas_makeConstraints:^(MASConstraintMaker *make) {
|
[self.bubbleImageView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.leading.mas_equalTo(self.contentLabel).offset(-20);
|
make.leading.mas_equalTo(self.contentLabel).offset(-16);
|
||||||
make.top.mas_equalTo(self.contentLabel).offset(-10);
|
make.top.mas_equalTo(self.contentLabel).offset(0);
|
||||||
make.bottom.mas_equalTo(self.contentLabel);//.offset(10);
|
make.bottom.mas_equalTo(self.contentLabel).offset(10);
|
||||||
make.trailing.mas_equalTo(self.contentLabel).offset(20);
|
make.trailing.mas_equalTo(self.contentLabel).offset(20);
|
||||||
}];
|
}];
|
||||||
|
|
||||||
@@ -70,6 +73,10 @@
|
|||||||
make.bottom.mas_equalTo(-20);
|
make.bottom.mas_equalTo(-20);
|
||||||
make.top.mas_equalTo(10);
|
make.top.mas_equalTo(10);
|
||||||
}];
|
}];
|
||||||
|
|
||||||
|
[self.blurEffectView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.edges.mas_equalTo(self.bubbleImageView);
|
||||||
|
}];
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)setIsLeftBigImage:(BOOL)isLeftBigImage {
|
- (void)setIsLeftBigImage:(BOOL)isLeftBigImage {
|
||||||
@@ -144,34 +151,59 @@
|
|||||||
self.contentLabel.attributedText = messageInfo.content;
|
self.contentLabel.attributedText = messageInfo.content;
|
||||||
// self.contentLabel.textLayout = messageInfo.textLayout;
|
// self.contentLabel.textLayout = messageInfo.textLayout;
|
||||||
|
|
||||||
if (messageInfo.bubbleImageUrl.length) {
|
if (![NSString isEmpty:messageInfo.bubbleImageUrl]) {
|
||||||
|
self.blurEffectView.hidden = YES;
|
||||||
@kWeakify(self);
|
@kWeakify(self);
|
||||||
[self.bubbleImageView loadImageWithUrl:messageInfo.bubbleImageUrl completion:^(UIImage * _Nonnull image, NSURL * _Nonnull url) {
|
[self.bubbleImageView loadImageWithUrl:messageInfo.bubbleImageUrl completion:^(UIImage * _Nonnull image, NSURL * _Nonnull url) {
|
||||||
@kStrongify(self);
|
@kStrongify(self);
|
||||||
UIImage *image1 = [UIImage imageWithCGImage:image.CGImage scale:2.0 orientation:UIImageOrientationUp];
|
UIImage *image1 = [UIImage imageWithCGImage:image.CGImage scale:2.0 orientation:UIImageOrientationUp];
|
||||||
UIImage *cutImage = [image1 cropRightAndBottomPixels:2];
|
UIImage *cutImage = [image1 cropRightAndBottomPixels:2];
|
||||||
self.bubbleImageView.image = [self resizableImage:cutImage];
|
self.bubbleImageView.image = [self resizableImage:cutImage];
|
||||||
|
|
||||||
|
[self.contentLabel mas_remakeConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.leading.mas_equalTo(messageInfo.contentLeftMargin);
|
||||||
|
make.top.mas_equalTo(messageInfo.contentTopMargin);
|
||||||
|
make.bottom.mas_equalTo(- messageInfo.contentBottomMargin - messageInfo.cellBottomMargin);
|
||||||
|
|
||||||
|
// make.centerY.mas_equalTo(self.contentView);
|
||||||
|
|
||||||
|
// if (isMSRTL()) {
|
||||||
|
make.width.mas_greaterThanOrEqualTo([self RTLLabelWidth] - messageInfo.contentLeftMargin);
|
||||||
|
// make.height.mas_greaterThanOrEqualTo([self RTLLabelHeight]);
|
||||||
|
// }
|
||||||
|
}];
|
||||||
|
|
||||||
|
[self.bubbleImageView mas_updateConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.top.mas_equalTo(0);
|
||||||
|
make.leading.trailing.mas_equalTo(self.contentView).offset(0);
|
||||||
|
// make.trailing.mas_equalTo(self.contentLabel).offset(-messageInfo.contentRightMargin - 10);
|
||||||
|
}];
|
||||||
}];
|
}];
|
||||||
[self.contentLabel mas_remakeConstraints:^(MASConstraintMaker *make) {
|
|
||||||
make.leading.mas_equalTo(self.bubbleImageView).offset(self.messageInfo.contentLeftMargin + 12);
|
|
||||||
// make.top.mas_equalTo(self.bubbleImageView).offset(self.messageInfo.contentTopMargin+20);
|
|
||||||
// make.bottom.mas_equalTo(self.bubbleImageView).offset(-self.messageInfo.contentBottomMargin-10);
|
|
||||||
make.top.mas_equalTo(-10);
|
|
||||||
make.bottom.mas_equalTo(0);
|
|
||||||
if (isMSRTL()) { // MARK: 可能会有性能问题,但源代码已经使用了更新 layout 的方案,推测是头像框和气泡会导致卡顿
|
|
||||||
make.width.mas_greaterThanOrEqualTo([self RTLLabelWidth]);
|
|
||||||
}
|
|
||||||
}];
|
|
||||||
} else {
|
} else {
|
||||||
|
self.blurEffectView.hidden = NO;
|
||||||
self.bubbleImageView.image = [UIImage imageWithColor:[DJDKMIMOMColor messageBubbleColor]];
|
self.bubbleImageView.image = [UIImage imageWithColor:[DJDKMIMOMColor messageBubbleColor]];
|
||||||
[self.contentLabel mas_remakeConstraints:^(MASConstraintMaker *make) {
|
[self.contentLabel mas_remakeConstraints:^(MASConstraintMaker *make) {
|
||||||
make.edges.mas_equalTo(self.contentView).inset(10);
|
make.leading.mas_equalTo(messageInfo.contentLeftMargin);
|
||||||
// make.leading.mas_equalTo(self.bubbleImageView).offset(self.messageInfo.contentLeftMargin + 12);
|
make.bottom.mas_equalTo(-messageInfo.cellBottomMargin);
|
||||||
// make.top.mas_equalTo(self.bubbleImageView).offset(self.messageInfo.contentTopMargin+10);
|
make.top.mas_equalTo(messageInfo.contentTopMargin);
|
||||||
// make.bottom.mas_equalTo(self.bubbleImageView).offset(-self.messageInfo.contentBottomMargin-20);
|
make.width.mas_equalTo([self RTLLabelWidth] - messageInfo.contentLeftMargin);
|
||||||
// if (isMSRTL()) { // MARK: 可能会有性能问题,但源代码已经使用了更新 layout 的方案,推测是头像框和气泡会导致卡顿
|
}];
|
||||||
// make.width.mas_greaterThanOrEqualTo([self RTLLabelWidth]);
|
// [self.contentLabel mas_remakeConstraints:^(MASConstraintMaker *make) {
|
||||||
// }
|
//// make.top.equalTo(self.contentView).offset(10); // 距离顶部 10 点
|
||||||
|
//// make.bottom.equalTo(self.contentView).offset(-10); // 距离底部 10 点
|
||||||
|
//// make.trailing.equalTo(self.contentView).offset(-10); // 距离右侧 10 点
|
||||||
|
//// make.centerY.mas_equalTo(self.contentView);
|
||||||
|
//// if (isMSRTL()) {
|
||||||
|
//// make.width.mas_greaterThanOrEqualTo([self RTLLabelWidth]);
|
||||||
|
// make.height.mas_greaterThanOrEqualTo([self RTLLabelHeight]);
|
||||||
|
//// }
|
||||||
|
// make.leading.equalTo(self.contentView).offset(10); // 左侧有足够空间,避免过宽
|
||||||
|
// }];
|
||||||
|
[self.bubbleImageView mas_updateConstraints:^(MASConstraintMaker *make) {
|
||||||
|
make.leading.mas_equalTo(self.contentLabel).offset(-8);
|
||||||
|
make.trailing.mas_equalTo(self.contentLabel).offset(8);
|
||||||
|
make.bottom.mas_equalTo(self.contentLabel).offset(0);
|
||||||
}];
|
}];
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -200,8 +232,16 @@
|
|||||||
CGSize size = [self.contentLabel.attributedText boundingRectWithSize:CGSizeMake(kRoomMessageMaxWidth, 0)
|
CGSize size = [self.contentLabel.attributedText boundingRectWithSize:CGSizeMake(kRoomMessageMaxWidth, 0)
|
||||||
options:NSStringDrawingUsesFontLeading | NSStringDrawingUsesLineFragmentOrigin
|
options:NSStringDrawingUsesFontLeading | NSStringDrawingUsesLineFragmentOrigin
|
||||||
context:nil].size;
|
context:nil].size;
|
||||||
NSLog(@" ----- 11 ----- %@", [NSValue valueWithCGSize:size]);
|
// NSLog(@" ----- 11 ----- %@", [NSValue valueWithCGSize:size]);
|
||||||
return MIN(ceil(size.width) + self.messageInfo.contentLeftMargin + self.messageInfo.contentRightMargin + 8, self.contentLabel.maxWidth);
|
// return MIN(ceil(size.width) + self.messageInfo.contentLeftMargin + self.messageInfo.contentRightMargin + 8, self.contentLabel.maxWidth);
|
||||||
|
return ceil(size.width);// + self.messageInfo.contentLeftMargin + self.messageInfo.contentRightMargin + 8;
|
||||||
|
}
|
||||||
|
|
||||||
|
- (CGFloat)RTLLabelHeight {
|
||||||
|
CGSize size = [self.contentLabel.attributedText boundingRectWithSize:CGSizeMake(kRoomMessageMaxWidth, 0)
|
||||||
|
options:NSStringDrawingUsesFontLeading | NSStringDrawingUsesLineFragmentOrigin
|
||||||
|
context:nil].size;
|
||||||
|
return ceil(size.height);
|
||||||
}
|
}
|
||||||
|
|
||||||
- (UIImage *)scaleToSize:(UIImage *)img {
|
- (UIImage *)scaleToSize:(UIImage *)img {
|
||||||
@@ -232,14 +272,19 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
- (NetImageView *)bubbleImageView {
|
- (NetImageView *)bubbleImageView {
|
||||||
if (!_bubbleImageView) {
|
if (!_bubbleImageView) {
|
||||||
_bubbleImageView = [[NetImageView alloc] init];
|
_bubbleImageView = [[NetImageView alloc] init];
|
||||||
_bubbleImageView.clipsToBounds = NO;
|
_bubbleImageView.clipsToBounds = NO;
|
||||||
_bubbleImageView.userInteractionEnabled = YES;
|
_bubbleImageView.userInteractionEnabled = YES;
|
||||||
_bubbleImageView.layer.masksToBounds = YES;
|
[_bubbleImageView setCornerRadius:8];
|
||||||
_bubbleImageView.layer.cornerRadius = 7;
|
// _bubbleImageView.layer.masksToBounds = YES;
|
||||||
|
// _bubbleImageView.layer.cornerRadius = 8;
|
||||||
|
|
||||||
|
// [_contentLabel setCornerRadius:8
|
||||||
|
// corners:kCALayerMinXMinYCorner | kCALayerMaxXMinYCorner | kCALayerMaxXMaxYCorner | kCALayerMinXMaxYCorner
|
||||||
|
// borderWidth:1
|
||||||
|
// borderColor:[UIColor greenColor]];
|
||||||
}
|
}
|
||||||
return _bubbleImageView;
|
return _bubbleImageView;
|
||||||
}
|
}
|
||||||
@@ -256,9 +301,15 @@
|
|||||||
- (XPNetImageYYLabel *)contentLabel {
|
- (XPNetImageYYLabel *)contentLabel {
|
||||||
if (!_contentLabel) {
|
if (!_contentLabel) {
|
||||||
_contentLabel = [[XPNetImageYYLabel alloc] init];
|
_contentLabel = [[XPNetImageYYLabel alloc] init];
|
||||||
_contentLabel.preferredMaxLayoutWidth = kRoomMessageMaxWidth - 24;
|
_contentLabel.preferredMaxLayoutWidth = kRoomMessageMaxWidth ;
|
||||||
_contentLabel.numberOfLines = 0;
|
_contentLabel.numberOfLines = 0;
|
||||||
_contentLabel.userInteractionEnabled = YES;
|
_contentLabel.userInteractionEnabled = YES;
|
||||||
|
|
||||||
|
// [_contentLabel setCornerRadius:8
|
||||||
|
// corners:kCALayerMinXMinYCorner | kCALayerMaxXMinYCorner | kCALayerMaxXMaxYCorner | kCALayerMinXMaxYCorner
|
||||||
|
// borderWidth:1
|
||||||
|
// borderColor:[UIColor redColor]];
|
||||||
|
|
||||||
}
|
}
|
||||||
return _contentLabel;
|
return _contentLabel;
|
||||||
}
|
}
|
||||||
@@ -270,4 +321,22 @@
|
|||||||
}
|
}
|
||||||
return _clickBtn;
|
return _clickBtn;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
- (UIVisualEffectView *)blurEffectView {
|
||||||
|
if (!_blurEffectView) {
|
||||||
|
// 创建模糊效果
|
||||||
|
UIBlurEffect *blurEffect = [UIBlurEffect effectWithStyle:UIBlurEffectStyleDark]; // 选择模糊样式(例如:Light, Dark, ExtraLight 等)
|
||||||
|
|
||||||
|
// 创建包含模糊效果的视图
|
||||||
|
_blurEffectView = [[UIVisualEffectView alloc] initWithEffect:blurEffect];
|
||||||
|
|
||||||
|
// 设置模糊视图的大小与目标视图一致
|
||||||
|
_blurEffectView.frame = CGRectMake(0, 0, KScreenWidth, 200);
|
||||||
|
_blurEffectView.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight; // 使模糊视图适应目标视图的尺寸变化
|
||||||
|
_blurEffectView.hidden = YES;
|
||||||
|
|
||||||
|
[_blurEffectView setCornerRadius:8];
|
||||||
|
}
|
||||||
|
return _blurEffectView;
|
||||||
|
}
|
||||||
@end
|
@end
|
||||||
|
@@ -1118,35 +1118,35 @@ NSString * const kRoomShowTopicKey = @"kRoomShowTopicKey";
|
|||||||
|
|
||||||
|
|
||||||
#pragma mark - UITableViewDelegate And UITableViewDataSource
|
#pragma mark - UITableViewDelegate And UITableViewDataSource
|
||||||
//- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath {
|
- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath {
|
||||||
// NSArray *source = @[];
|
NSArray *source = @[];
|
||||||
// switch (self.displayType) {
|
switch (self.displayType) {
|
||||||
// case 1:
|
case 1:
|
||||||
// source = self.datasource;
|
source = self.datasource;
|
||||||
// break;
|
break;
|
||||||
// case 2:
|
case 2:
|
||||||
// source = self.datasource_chat;
|
source = self.datasource_chat;
|
||||||
// break;
|
break;
|
||||||
// case 3:
|
case 3:
|
||||||
// source = self.datasource_gift;
|
source = self.datasource_gift;
|
||||||
// break;
|
break;
|
||||||
//
|
|
||||||
// default:
|
default:
|
||||||
// source = self.datasource;
|
source = self.datasource;
|
||||||
// break;
|
break;
|
||||||
// }
|
}
|
||||||
//
|
|
||||||
// XPMessageInfoModel *model = [source xpSafeObjectAtIndex:indexPath.row];
|
XPMessageInfoModel *model = [source xpSafeObjectAtIndex:indexPath.row];
|
||||||
//
|
|
||||||
// // 如果 model 中有高度数据,使用 model 的高度
|
// 如果 model 中有高度数据,使用 model 的高度
|
||||||
// if (model.rowHeight > 0) {
|
if (model.rowHeight > 0) {
|
||||||
// return model.rowHeight;
|
return model.rowHeight;
|
||||||
// }
|
}
|
||||||
//
|
|
||||||
// // 否则,使用自适应高度
|
// 否则,使用自适应高度
|
||||||
// return 100;
|
// return 100;
|
||||||
//// return UITableViewAutomaticDimension;
|
return UITableViewAutomaticDimension;
|
||||||
//}
|
}
|
||||||
|
|
||||||
- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
|
- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
|
||||||
switch (self.displayType) {
|
switch (self.displayType) {
|
||||||
@@ -1336,7 +1336,7 @@ NSString * const kRoomShowTopicKey = @"kRoomShowTopicKey";
|
|||||||
_messageTableView = [[UITableView alloc] initWithFrame:CGRectZero style:UITableViewStylePlain];
|
_messageTableView = [[UITableView alloc] initWithFrame:CGRectZero style:UITableViewStylePlain];
|
||||||
_messageTableView.delegate = self;
|
_messageTableView.delegate = self;
|
||||||
_messageTableView.dataSource = self;
|
_messageTableView.dataSource = self;
|
||||||
// _messageTableView.rowHeight = UITableViewAutomaticDimension;
|
_messageTableView.rowHeight = UITableViewAutomaticDimension;
|
||||||
// _messageTableView.estimatedRowHeight = 44; // 预估高度
|
// _messageTableView.estimatedRowHeight = 44; // 预估高度
|
||||||
_messageTableView.tableFooterView = [UIView new];
|
_messageTableView.tableFooterView = [UIView new];
|
||||||
_messageTableView.separatorStyle = UITableViewCellSeparatorStyleNone;
|
_messageTableView.separatorStyle = UITableViewCellSeparatorStyleNone;
|
||||||
|
Reference in New Issue
Block a user