把礼物动画从舞台的view中移出来 单一职责
This commit is contained in:
@@ -26,6 +26,7 @@
|
||||
#import "RoomHeaderView.h"
|
||||
#import "SocialStageView.h"
|
||||
#import "XPMiniRoomView.h"
|
||||
#import "XPRoomAnimationView.h"
|
||||
///P
|
||||
#import "XPRoomPresenter.h"
|
||||
#import "XPRoomProtocol.h"
|
||||
@@ -46,7 +47,8 @@
|
||||
@property (nonatomic,strong) XPRoomMenuContainerView *menuContainerView;
|
||||
///活动
|
||||
@property (nonatomic,strong) XPRoomActivityContainerView *activityContainerView;
|
||||
|
||||
///动画的view
|
||||
@property (nonatomic,strong) XPRoomAnimationView *animationView;
|
||||
///房间的Uid
|
||||
@property (nonatomic,copy) NSString * roomUid;
|
||||
///用户信息
|
||||
@@ -95,10 +97,6 @@
|
||||
[self.view endEditing:YES];
|
||||
}
|
||||
|
||||
- (void)viewDidLayoutSubviews {
|
||||
[super viewDidLayoutSubviews];
|
||||
[self.backContainerView superViewDidLayoutViews];
|
||||
}
|
||||
|
||||
#pragma mark - Private Method
|
||||
- (void)initSubViews {
|
||||
@@ -108,6 +106,7 @@
|
||||
[self.view addSubview:self.messageContainerView];
|
||||
[self.view addSubview:self.menuContainerView];
|
||||
[self.view addSubview:self.activityContainerView];
|
||||
[self.view addSubview:self.animationView];
|
||||
}
|
||||
|
||||
- (void)initSubViewConstraints {
|
||||
@@ -144,6 +143,10 @@
|
||||
make.bottom.mas_equalTo(self.menuContainerView.mas_top).offset(-5);
|
||||
make.width.mas_equalTo(80);
|
||||
}];
|
||||
|
||||
[self.animationView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.edges.mas_equalTo(self.view);
|
||||
}];
|
||||
}
|
||||
|
||||
- (void)exitOldRoom {
|
||||
@@ -213,6 +216,9 @@
|
||||
[self enterRoomFail];
|
||||
}
|
||||
|
||||
- (CGPoint)centerForUserAtUid:(NSString *)uid {
|
||||
return [self.stageView centerForUserAtUid:uid];
|
||||
}
|
||||
|
||||
#pragma mark - RoomDelegate
|
||||
- (RoomInfoModel *)getRoomInfo {
|
||||
@@ -289,4 +295,11 @@
|
||||
return _activityContainerView;
|
||||
}
|
||||
|
||||
- (XPRoomAnimationView *)animationView {
|
||||
if (!_animationView) {
|
||||
_animationView = [[XPRoomAnimationView alloc] initWithdelegate:self];
|
||||
}
|
||||
return _animationView;
|
||||
}
|
||||
|
||||
@end
|
||||
|
Reference in New Issue
Block a user