提交
This commit is contained in:
@@ -14,22 +14,27 @@
|
||||
#import "QXRoomSeatPKView.h"
|
||||
#import "QXRoomSeatTypeFrientView.h"
|
||||
#import "QXRoomUserCharmView.h"
|
||||
#import "QXRoomSeatTypeSingerView.h"
|
||||
|
||||
@interface QXRoomSeatView()<QXRoomSeatDelegate>
|
||||
/// 二卡八
|
||||
@property (nonatomic,strong)QXRoomSeatTypeNormalView *normalSeatView;
|
||||
|
||||
/// K歌房
|
||||
@property (nonatomic,strong)QXRoomSeatTypeSongView *songView;
|
||||
|
||||
/// 拍卖房
|
||||
@property (nonatomic,strong)QXRoomSeatTypeAuctionView *auctionView;
|
||||
|
||||
/// 在线列表
|
||||
@property (nonatomic,strong) QXRoomOnlineUserListView *onlineListView;
|
||||
|
||||
/// 私密小屋
|
||||
@property (nonatomic,strong)QXRoomSeatTypeCabinView *cabinView;
|
||||
|
||||
/// PK
|
||||
@property (nonatomic,strong)QXRoomSeatPKView *roomPkView;
|
||||
|
||||
/// 交友房
|
||||
@property (nonatomic,strong)QXRoomSeatTypeFrientView *roomFriendView;
|
||||
|
||||
/// 点唱房
|
||||
@property (nonatomic,strong)QXRoomSeatTypeSingerView *singerView;
|
||||
|
||||
@property (nonatomic,strong)QXRoomUserCharmView *charmListView;
|
||||
@end
|
||||
|
||||
@@ -48,14 +53,25 @@
|
||||
|
||||
//初始化普通视图
|
||||
-(void)initNomarlView{
|
||||
// if (_songView) {
|
||||
// [_songView removeFromSuperview];
|
||||
// _songView = nil;
|
||||
// }
|
||||
//
|
||||
if (_singerView) {
|
||||
_singerView.transform = CGAffineTransformIdentity;
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self->_singerView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
} completion:^(BOOL finished) {
|
||||
[self->_singerView destroyViews];
|
||||
[self->_singerView removeFromSuperview];
|
||||
self->_singerView = nil;
|
||||
[self showNormalView];
|
||||
}];
|
||||
return;
|
||||
}
|
||||
if (_songView) {
|
||||
// [_normalSeatView removeFromSuperview];
|
||||
// _normalSeatView = nil;
|
||||
[[QXAgoraEngine sharedEngine] ktv_EndSing];
|
||||
_songView.transform = CGAffineTransformIdentity;
|
||||
// 弹性动画
|
||||
@@ -70,22 +86,7 @@
|
||||
[self->_songView destroyViews];
|
||||
[self->_songView removeFromSuperview];
|
||||
self->_songView = nil;
|
||||
[self addSubview:self.normalSeatView];
|
||||
[self.normalSeatView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
self.normalSeatView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self.normalSeatView.transform = CGAffineTransformIdentity;
|
||||
} completion:^(BOOL finished) {
|
||||
|
||||
}];
|
||||
[self showNormalView];
|
||||
}];
|
||||
return;
|
||||
}
|
||||
@@ -109,22 +110,7 @@
|
||||
[self->_auctionView destroyViews];
|
||||
[self->_auctionView removeFromSuperview];
|
||||
self->_auctionView = nil;
|
||||
[self addSubview:self.normalSeatView];
|
||||
[self.normalSeatView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
self.normalSeatView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self.normalSeatView.transform = CGAffineTransformIdentity;
|
||||
} completion:^(BOOL finished) {
|
||||
|
||||
}];
|
||||
[self showNormalView];
|
||||
}];
|
||||
return;
|
||||
}
|
||||
@@ -142,22 +128,7 @@
|
||||
[self->_roomPkView destroyViews];
|
||||
[self->_roomPkView removeFromSuperview];
|
||||
self->_roomPkView = nil;
|
||||
[self addSubview:self.normalSeatView];
|
||||
[self.normalSeatView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
self.normalSeatView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self.normalSeatView.transform = CGAffineTransformIdentity;
|
||||
} completion:^(BOOL finished) {
|
||||
|
||||
}];
|
||||
[self showNormalView];
|
||||
}];
|
||||
return;
|
||||
}
|
||||
@@ -175,22 +146,7 @@
|
||||
[self->_roomFriendView destroyViews];
|
||||
[self->_roomFriendView removeFromSuperview];
|
||||
self->_roomFriendView = nil;
|
||||
[self addSubview:self.normalSeatView];
|
||||
[self.normalSeatView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
self.normalSeatView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self.normalSeatView.transform = CGAffineTransformIdentity;
|
||||
} completion:^(BOOL finished) {
|
||||
|
||||
}];
|
||||
[self showNormalView];
|
||||
}];
|
||||
return;
|
||||
}
|
||||
@@ -199,9 +155,44 @@
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
}
|
||||
|
||||
-(void)showNormalView{
|
||||
[self addSubview:self.normalSeatView];
|
||||
[self.normalSeatView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
self.normalSeatView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self.normalSeatView.transform = CGAffineTransformIdentity;
|
||||
} completion:^(BOOL finished) {
|
||||
|
||||
}];
|
||||
}
|
||||
//初始化拍卖视图
|
||||
-(void)initAuctionView{
|
||||
if (_singerView) {
|
||||
_singerView.transform = CGAffineTransformIdentity;
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self->_singerView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
} completion:^(BOOL finished) {
|
||||
[self->_singerView destroyViews];
|
||||
[self->_singerView removeFromSuperview];
|
||||
self->_singerView = nil;
|
||||
[self showAuctionView];
|
||||
}];
|
||||
return;
|
||||
}
|
||||
if (_normalSeatView) {
|
||||
// [_normalSeatView removeFromSuperview];
|
||||
// _normalSeatView = nil;
|
||||
@@ -218,22 +209,7 @@
|
||||
[self->_normalSeatView destroyViews];
|
||||
[self->_normalSeatView removeFromSuperview];
|
||||
self->_normalSeatView = nil;
|
||||
[self addSubview:self.auctionView];
|
||||
[self.auctionView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
self.auctionView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self.auctionView.transform = CGAffineTransformIdentity;
|
||||
} completion:^(BOOL finished) {
|
||||
|
||||
}];
|
||||
[self showAuctionView];
|
||||
}];
|
||||
return;
|
||||
}
|
||||
@@ -254,22 +230,7 @@
|
||||
[self->_songView destroyViews];
|
||||
[self->_songView removeFromSuperview];
|
||||
self->_songView = nil;
|
||||
[self addSubview:self.auctionView];
|
||||
[self.auctionView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
self.auctionView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self.auctionView.transform = CGAffineTransformIdentity;
|
||||
} completion:^(BOOL finished) {
|
||||
|
||||
}];
|
||||
[self showAuctionView];
|
||||
}];
|
||||
return;
|
||||
}
|
||||
@@ -287,22 +248,7 @@
|
||||
[self->_roomPkView destroyViews];
|
||||
[self->_roomPkView removeFromSuperview];
|
||||
self->_roomPkView = nil;
|
||||
[self addSubview:self.auctionView];
|
||||
[self.auctionView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
self.auctionView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self.auctionView.transform = CGAffineTransformIdentity;
|
||||
} completion:^(BOOL finished) {
|
||||
|
||||
}];
|
||||
[self showAuctionView];
|
||||
}];
|
||||
return;
|
||||
}
|
||||
@@ -321,21 +267,7 @@
|
||||
[self->_roomFriendView removeFromSuperview];
|
||||
self->_roomFriendView = nil;
|
||||
[self addSubview:self.auctionView];
|
||||
[self.auctionView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
self.auctionView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self.auctionView.transform = CGAffineTransformIdentity;
|
||||
} completion:^(BOOL finished) {
|
||||
|
||||
}];
|
||||
[self showAuctionView];
|
||||
}];
|
||||
return;
|
||||
}
|
||||
@@ -344,9 +276,45 @@
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
}
|
||||
-(void)showAuctionView{
|
||||
[self addSubview:self.auctionView];
|
||||
[self.auctionView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
self.auctionView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self.auctionView.transform = CGAffineTransformIdentity;
|
||||
} completion:^(BOOL finished) {
|
||||
|
||||
}];
|
||||
}
|
||||
|
||||
//初始化点唱
|
||||
//初始化ktv
|
||||
-(void)initSingView{
|
||||
if (_singerView) {
|
||||
_singerView.transform = CGAffineTransformIdentity;
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self->_singerView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
} completion:^(BOOL finished) {
|
||||
[self->_singerView destroyViews];
|
||||
[self->_singerView removeFromSuperview];
|
||||
self->_singerView = nil;
|
||||
[self showSongView];
|
||||
}];
|
||||
return;
|
||||
}
|
||||
if (_normalSeatView) {
|
||||
// [_normalSeatView removeFromSuperview];
|
||||
// _normalSeatView = nil;
|
||||
@@ -363,22 +331,7 @@
|
||||
[self->_normalSeatView destroyViews];
|
||||
[self->_normalSeatView removeFromSuperview];
|
||||
self->_normalSeatView = nil;
|
||||
[self addSubview:self.songView];
|
||||
[self.songView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
self.songView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self.songView.transform = CGAffineTransformIdentity;
|
||||
} completion:^(BOOL finished) {
|
||||
|
||||
}];
|
||||
[self showSongView];
|
||||
}];
|
||||
return;
|
||||
}
|
||||
@@ -399,55 +352,7 @@
|
||||
[self->_auctionView destroyViews];
|
||||
[self->_auctionView removeFromSuperview];
|
||||
self->_auctionView = nil;
|
||||
[self addSubview:self.songView];
|
||||
[self.songView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
self.songView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self.songView.transform = CGAffineTransformIdentity;
|
||||
} completion:^(BOOL finished) {
|
||||
|
||||
}];
|
||||
}];
|
||||
return;
|
||||
}
|
||||
if (_roomPkView) {
|
||||
_roomPkView.transform = CGAffineTransformIdentity;
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self->_roomPkView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
} completion:^(BOOL finished) {
|
||||
[self->_roomPkView destroyViews];
|
||||
[self->_roomPkView removeFromSuperview];
|
||||
self->_roomPkView = nil;
|
||||
[self addSubview:self.songView];
|
||||
[self.songView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
self.songView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self.songView.transform = CGAffineTransformIdentity;
|
||||
} completion:^(BOOL finished) {
|
||||
|
||||
}];
|
||||
[self showSongView];
|
||||
}];
|
||||
return;
|
||||
}
|
||||
@@ -465,22 +370,7 @@
|
||||
[self->_roomFriendView destroyViews];
|
||||
[self->_roomFriendView removeFromSuperview];
|
||||
self->_roomFriendView = nil;
|
||||
[self addSubview:self.songView];
|
||||
[self.songView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
self.songView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self.songView.transform = CGAffineTransformIdentity;
|
||||
} completion:^(BOOL finished) {
|
||||
|
||||
}];
|
||||
[self showSongView];
|
||||
}];
|
||||
return;
|
||||
}
|
||||
@@ -489,6 +379,24 @@
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
}
|
||||
-(void)showSongView{
|
||||
[self addSubview:self.songView];
|
||||
[self.songView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
self.songView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self.songView.transform = CGAffineTransformIdentity;
|
||||
} completion:^(BOOL finished) {
|
||||
|
||||
}];
|
||||
}
|
||||
|
||||
- (void)initRoomPKView{
|
||||
if (_normalSeatView) {
|
||||
@@ -526,11 +434,14 @@
|
||||
}];
|
||||
return;
|
||||
}
|
||||
if (_songView) {
|
||||
// [_normalSeatView removeFromSuperview];
|
||||
// _normalSeatView = nil;
|
||||
[[QXAgoraEngine sharedEngine] ktv_EndSing];
|
||||
_songView.transform = CGAffineTransformIdentity;
|
||||
[self addSubview:self.roomPkView];
|
||||
[self.roomPkView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
}
|
||||
-(void)initRoomFriendView{
|
||||
if (_singerView) {
|
||||
_singerView.transform = CGAffineTransformIdentity;
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
@@ -538,39 +449,17 @@
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self->_songView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
self->_singerView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
} completion:^(BOOL finished) {
|
||||
[self->_songView destroyViews];
|
||||
[self->_songView removeFromSuperview];
|
||||
self->_songView = nil;
|
||||
[self addSubview:self.roomPkView];
|
||||
[self.roomPkView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
self.roomPkView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self.roomPkView.transform = CGAffineTransformIdentity;
|
||||
} completion:^(BOOL finished) {
|
||||
|
||||
}];
|
||||
[self->_singerView destroyViews];
|
||||
[self->_singerView removeFromSuperview];
|
||||
self->_singerView = nil;
|
||||
[self showRoomFriendView];
|
||||
}];
|
||||
return;
|
||||
}
|
||||
[self addSubview:self.roomPkView];
|
||||
[self.roomPkView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
}
|
||||
-(void)initRoomFriendView{
|
||||
if (_normalSeatView) {
|
||||
// [_normalSeatView removeFromSuperview];
|
||||
// _normalSeatView = nil;
|
||||
|
||||
_normalSeatView.transform = CGAffineTransformIdentity;
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
@@ -584,22 +473,7 @@
|
||||
[self->_normalSeatView destroyViews];
|
||||
[self->_normalSeatView removeFromSuperview];
|
||||
self->_normalSeatView = nil;
|
||||
[self addSubview:self.roomFriendView];
|
||||
[self.roomFriendView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
self.roomFriendView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self.roomFriendView.transform = CGAffineTransformIdentity;
|
||||
} completion:^(BOOL finished) {
|
||||
|
||||
}];
|
||||
[self showRoomFriendView];
|
||||
}];
|
||||
return;
|
||||
}
|
||||
@@ -620,22 +494,7 @@
|
||||
[self->_auctionView destroyViews];
|
||||
[self->_auctionView removeFromSuperview];
|
||||
self->_auctionView = nil;
|
||||
[self addSubview:self.roomFriendView];
|
||||
[self.roomFriendView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
self.roomFriendView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self.roomFriendView.transform = CGAffineTransformIdentity;
|
||||
} completion:^(BOOL finished) {
|
||||
|
||||
}];
|
||||
[self showRoomFriendView];
|
||||
}];
|
||||
return;
|
||||
}
|
||||
@@ -654,22 +513,7 @@
|
||||
[self->_songView destroyViews];
|
||||
[self->_songView removeFromSuperview];
|
||||
self->_songView = nil;
|
||||
[self addSubview:self.roomFriendView];
|
||||
[self.roomFriendView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
self.roomFriendView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self.roomFriendView.transform = CGAffineTransformIdentity;
|
||||
} completion:^(BOOL finished) {
|
||||
|
||||
}];
|
||||
[self showRoomFriendView];
|
||||
}];
|
||||
return;
|
||||
}
|
||||
@@ -678,6 +522,127 @@
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
}
|
||||
-(void)showRoomFriendView{
|
||||
[self addSubview:self.roomFriendView];
|
||||
[self.roomFriendView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
self.roomFriendView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self.roomFriendView.transform = CGAffineTransformIdentity;
|
||||
} completion:^(BOOL finished) {
|
||||
|
||||
}];
|
||||
}
|
||||
|
||||
-(void)initSignerView{
|
||||
if (_roomFriendView) {
|
||||
_roomFriendView.transform = CGAffineTransformIdentity;
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self->_roomFriendView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
} completion:^(BOOL finished) {
|
||||
[self->_roomFriendView destroyViews];
|
||||
[self->_roomFriendView removeFromSuperview];
|
||||
self->_roomFriendView = nil;
|
||||
[self showSinggerView];
|
||||
}];
|
||||
return;
|
||||
}
|
||||
if (_normalSeatView) {
|
||||
// [_normalSeatView removeFromSuperview];
|
||||
// _normalSeatView = nil;
|
||||
_normalSeatView.transform = CGAffineTransformIdentity;
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self->_normalSeatView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
} completion:^(BOOL finished) {
|
||||
[self->_normalSeatView destroyViews];
|
||||
[self->_normalSeatView removeFromSuperview];
|
||||
self->_normalSeatView = nil;
|
||||
[self showSinggerView];
|
||||
}];
|
||||
return;
|
||||
}
|
||||
if (_auctionView) {
|
||||
_auctionView.transform = CGAffineTransformIdentity;
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self->_auctionView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
} completion:^(BOOL finished) {
|
||||
if (self->_auctionView.auctionInfoView != nil) {
|
||||
[self->_auctionView.auctionInfoView hide];
|
||||
}
|
||||
[self->_auctionView destroyViews];
|
||||
[self->_auctionView removeFromSuperview];
|
||||
self->_auctionView = nil;
|
||||
[self showSinggerView];
|
||||
}];
|
||||
return;
|
||||
}
|
||||
if (_songView) {
|
||||
[[QXAgoraEngine sharedEngine] ktv_EndSing];
|
||||
_songView.transform = CGAffineTransformIdentity;
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self->_songView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
} completion:^(BOOL finished) {
|
||||
[self->_songView destroyViews];
|
||||
[self->_songView removeFromSuperview];
|
||||
self->_songView = nil;
|
||||
[self showSinggerView];
|
||||
}];
|
||||
return;
|
||||
}
|
||||
[self addSubview:self.singerView];
|
||||
[self.singerView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
}
|
||||
-(void)showSinggerView{
|
||||
[self addSubview:self.singerView];
|
||||
[self.singerView mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.left.right.top.bottom.equalTo(self);
|
||||
}];
|
||||
self.singerView.transform = CGAffineTransformMakeScale(0.01, 0.01);
|
||||
// 弹性动画
|
||||
[UIView animateWithDuration:0.5
|
||||
delay:0
|
||||
usingSpringWithDamping:0.9
|
||||
initialSpringVelocity:0.1
|
||||
options:UIViewAnimationOptionCurveEaseOut
|
||||
animations:^{
|
||||
self.singerView.transform = CGAffineTransformIdentity;
|
||||
} completion:^(BOOL finished) {
|
||||
|
||||
}];
|
||||
}
|
||||
|
||||
- (void)initCabinView{
|
||||
self.cabinView = [[QXRoomSeatTypeCabinView alloc] init];
|
||||
@@ -708,6 +673,9 @@
|
||||
case QXRoomSeatViewTypeFriend:
|
||||
self.roomFriendView.myPitNumber = myPitNumber;
|
||||
break;
|
||||
case QXRoomSeatViewTypeSinger:
|
||||
self.singerView.myPitNumber = myPitNumber;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
@@ -747,6 +715,10 @@
|
||||
[self initRoomFriendView];
|
||||
}
|
||||
break;
|
||||
case QXRoomSeatViewTypeSinger:{
|
||||
[self initSignerView];
|
||||
}
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
@@ -807,6 +779,9 @@
|
||||
case QXRoomSeatViewTypeFriend:
|
||||
self.roomFriendView.roomModel = roomModel;
|
||||
break;
|
||||
case QXRoomSeatViewTypeSinger:
|
||||
self.singerView.roomModel = roomModel;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
@@ -886,6 +861,9 @@
|
||||
case QXRoomSeatViewTypeFriend:
|
||||
[self.roomFriendView clearCharm];
|
||||
break;
|
||||
case QXRoomSeatViewTypeSinger:
|
||||
[self.singerView clearCharm];
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
@@ -913,6 +891,9 @@
|
||||
case QXRoomSeatViewTypeFriend:
|
||||
[self.roomFriendView roomClearUserCharmWithUserId:userId];
|
||||
break;
|
||||
case QXRoomSeatViewTypeSinger:
|
||||
[self.singerView roomClearUserCharmWithUserId:userId];
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
@@ -939,6 +920,9 @@
|
||||
case QXRoomSeatViewTypeFriend:
|
||||
[self.roomFriendView roomSeatExchangedWithFromPitNumber:fromPitNumber toPitNumber:toPitNumber userInfo:userInfo isPK:isPK];
|
||||
break;
|
||||
case QXRoomSeatViewTypeSinger:
|
||||
[self.singerView roomSeatExchangedWithFromPitNumber:fromPitNumber toPitNumber:toPitNumber userInfo:userInfo isPK:isPK];
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
@@ -966,6 +950,9 @@
|
||||
case QXRoomSeatViewTypeFriend:
|
||||
[self.roomFriendView setSeatCharmWithUser:model];
|
||||
break;
|
||||
case QXRoomSeatViewTypeSinger:
|
||||
[self.singerView setSeatCharmWithUser:model];
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
@@ -994,6 +981,9 @@
|
||||
case QXRoomSeatViewTypeFriend:
|
||||
[self.roomFriendView setSeatCharmWithUsers:users];
|
||||
break;
|
||||
case QXRoomSeatViewTypeSinger:
|
||||
[self.singerView setSeatCharmWithUsers:users];
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
@@ -1019,6 +1009,9 @@
|
||||
case QXRoomSeatViewTypePK:
|
||||
[self.roomPkView setSeatIsLock:isLock pitNumber:pitNumber];
|
||||
break;
|
||||
case QXRoomSeatViewTypeSinger:
|
||||
[self.singerView setSeatIsLock:isLock pitNumber:pitNumber];
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
@@ -1212,6 +1205,9 @@
|
||||
case QXRoomSeatViewTypeFriend:
|
||||
[self.roomFriendView didUpDownSeatWithUser:user isUpSeat:isUpSeat pit_number:pit_number isPK:isPK];
|
||||
break;
|
||||
case QXRoomSeatViewTypeSinger:
|
||||
[self.singerView didUpDownSeatWithUser:user isUpSeat:isUpSeat pit_number:pit_number isPK:isPK];
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
@@ -1260,24 +1256,26 @@
|
||||
self.onlineListView.roomId = self.roomModel.room_info.room_id;
|
||||
[self.onlineListView showInView:self.viewController.view];
|
||||
}
|
||||
/// 点唱房当前歌曲信息发生变化
|
||||
-(void)singerSongCurrentSongInfoDidChanged:(QXUserSongListModel*)model{
|
||||
if (_singerView) {
|
||||
[self.singerView singerSongCurrentSongInfoDidChanged:model];
|
||||
}
|
||||
}
|
||||
/// 点唱房下一首歌信息发生变化
|
||||
-(void)singerSongNextSongInfoDidChanged:(QXUserSongListModel*)model{
|
||||
if (_singerView) {
|
||||
[self.singerView singerSongNextSongInfoDidChanged:model];
|
||||
}
|
||||
}
|
||||
/// 已点歌曲数量发生变化
|
||||
-(void)singerSongCountDidChanged:(NSString*)count{
|
||||
if (_singerView) {
|
||||
[self.singerView singerSongCountDidChanged:count];
|
||||
}
|
||||
}
|
||||
|
||||
-(void)roomUserInfoDidChanged:(QXUserHomeModel *)user{
|
||||
// if (_normalSeatView) {
|
||||
// [self.normalSeatView roomUserInfoDidChanged:user];
|
||||
// return;
|
||||
// }
|
||||
// if (_songView) {
|
||||
// [self.songView roomUserInfoDidChanged:user];
|
||||
// return;
|
||||
// }
|
||||
// if (_auctionView) {
|
||||
// [self.auctionView roomUserInfoDidChanged:user];
|
||||
// return;
|
||||
// }
|
||||
// if (_roomPkView) {
|
||||
// [self.roomPkView roomUserInfoDidChanged:user];
|
||||
// return;
|
||||
// }
|
||||
switch (self.type) {
|
||||
case QXRoomSeatViewTypeNormal:
|
||||
[self.normalSeatView roomUserInfoDidChanged:user];
|
||||
@@ -1297,6 +1295,9 @@
|
||||
case QXRoomSeatViewTypeFriend:
|
||||
[self.roomFriendView roomUserInfoDidChanged:user];
|
||||
break;
|
||||
case QXRoomSeatViewTypeSinger:
|
||||
[self.singerView roomUserInfoDidChanged:user];
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
@@ -1321,6 +1322,9 @@
|
||||
case QXRoomSeatViewTypeFriend:
|
||||
[self.roomFriendView stopHWDMP4];
|
||||
break;
|
||||
case QXRoomSeatViewTypeSinger:
|
||||
[self.singerView stopHWDMP4];
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
@@ -1345,6 +1349,9 @@
|
||||
case QXRoomSeatViewTypeFriend:
|
||||
[self.roomFriendView playHWDMP4];
|
||||
break;
|
||||
case QXRoomSeatViewTypeSinger:
|
||||
[self.singerView playHWDMP4];
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
@@ -1373,6 +1380,10 @@
|
||||
[self.cabinView destroyViews];
|
||||
_cabinView = nil;
|
||||
}
|
||||
if (_singerView) {
|
||||
[self.singerView destroyViews];
|
||||
_singerView = nil;
|
||||
}
|
||||
}
|
||||
|
||||
-(QXRoomOnlineUserListView *)onlineListView{
|
||||
@@ -1382,7 +1393,13 @@
|
||||
}
|
||||
return _onlineListView;
|
||||
}
|
||||
|
||||
-(QXRoomSeatTypeSingerView *)singerView{
|
||||
if (!_singerView) {
|
||||
_singerView = [[QXRoomSeatTypeSingerView alloc] init];
|
||||
_singerView.delegate = self;
|
||||
}
|
||||
return _singerView;
|
||||
}
|
||||
-(QXRoomSeatTypeAuctionView *)auctionView{
|
||||
if (!_auctionView) {
|
||||
_auctionView = [[QXRoomSeatTypeAuctionView alloc] init];
|
||||
|
||||
Reference in New Issue
Block a user