修改游戏模式下公屏放大缩小
This commit is contained in:
@@ -32,7 +32,7 @@
|
||||
|
||||
NSString * const kRoomShowTopicKey = @"kRoomShowTopicKey";
|
||||
|
||||
@interface XPRoomMessageContainerView ()<UITableViewDelegate, UITableViewDataSource>
|
||||
@interface XPRoomMessageContainerView ()<UITableViewDelegate, UITableViewDataSource, XPRoomMessageTableViewCellDelegate>
|
||||
///房间的代理
|
||||
@property (nonatomic,weak) id<RoomHostDelegate> hostDelegate;
|
||||
|
||||
@@ -60,6 +60,8 @@ NSString * const kRoomShowTopicKey = @"kRoomShowTopicKey";
|
||||
@property (nonatomic, strong) NSMutableArray *trumpetQueue;
|
||||
///小喇叭动画定时器
|
||||
@property (nonatomic, strong) dispatch_source_t trumpetTimer;
|
||||
///是否是大的 只有在小游戏的时候有用
|
||||
@property (nonatomic,assign) BOOL isLarge;
|
||||
@end
|
||||
|
||||
|
||||
@@ -517,6 +519,7 @@ NSString * const kRoomShowTopicKey = @"kRoomShowTopicKey";
|
||||
if (cell == nil) {
|
||||
cell = [[XPRoomMessageTableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:NSStringFromClass([XPRoomMessageTableViewCell class])];
|
||||
}
|
||||
cell.delegate = self;
|
||||
NSAttributedString* attr = [self.datasource objectAtIndex:indexPath.row];
|
||||
NSString *bubbleStr = [self.messageBubbles objectAtIndex:indexPath.row];
|
||||
cell.bubbleImageUrl = bubbleStr;
|
||||
@@ -524,6 +527,7 @@ NSString * const kRoomShowTopicKey = @"kRoomShowTopicKey";
|
||||
return cell;
|
||||
}
|
||||
|
||||
|
||||
- (void)createTrumpetAnimation:(NSDictionary *)attatchment {
|
||||
self.trumpetView.data = attatchment;
|
||||
self.trumpetView.hidden = NO;
|
||||
@@ -577,6 +581,16 @@ NSString * const kRoomShowTopicKey = @"kRoomShowTopicKey";
|
||||
[self.trumpetView.mainView.layer pop_addAnimation:animation2 forKey:@"animation2"];
|
||||
[self.trumpetView.mainView.layer pop_addAnimation:animation3 forKey:@"animation3"];
|
||||
}
|
||||
#pragma mark - XPRoomMessageTableViewCellDelegate
|
||||
- (void)xPRoomMessageTableViewCellDidTapEmpty:(XPRoomMessageTableViewCell *)view {
|
||||
if (self.hostDelegate.getRoomInfo.type == RoomType_MiniGame) {
|
||||
self.isLarge = !self.isLarge;
|
||||
CGFloat height = self.isLarge ? 200 : 80;
|
||||
[self mas_updateConstraints:^(MASConstraintMaker *make) {
|
||||
make.height.mas_equalTo(height);
|
||||
}];
|
||||
}
|
||||
}
|
||||
|
||||
#pragma mark - Getters And Setters
|
||||
- (UITableView *)messageTableView {
|
||||
|
Reference in New Issue
Block a user