提交
This commit is contained in:
@@ -63,7 +63,7 @@
|
||||
|
||||
- (void)initSubViews{
|
||||
// UILabel *tLabel = [[UILabel alloc] init];
|
||||
// tLabel.text = QXText(@"秘地");
|
||||
// tLabel.text = QXText(@"MY语聊");
|
||||
// tLabel.font = [UIFont boldSystemFontOfSize:20];
|
||||
// [self.view addSubview:tLabel];
|
||||
// [tLabel mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
@@ -407,8 +407,8 @@
|
||||
_categoryView = [[JXCategoryTitleView alloc] init];
|
||||
_categoryView.frame = CGRectMake(15, 0, SCREEN_WIDTH-30, 44);
|
||||
_categoryView.delegate = self;
|
||||
_categoryView.titleSelectedColor = [UIColor colorWithHexString:@"#FFFFFF"];
|
||||
_categoryView.titleColor = RGB16A(0xF1ECFF, 0.45);
|
||||
_categoryView.titleSelectedColor = [UIColor colorWithHexString:@"#333333"];
|
||||
_categoryView.titleColor = RGB16A(0x666666, 0.45);
|
||||
_categoryView.cellWidth = JXCategoryViewAutomaticDimension;
|
||||
_categoryView.contentEdgeInsetLeft = 3;
|
||||
_categoryView.cellSpacing = 16;
|
||||
|
||||
@@ -30,7 +30,8 @@
|
||||
-(void)initSubViews{
|
||||
self.view.backgroundColor = [UIColor whiteColor];
|
||||
// self.titles = @[@"房间榜", @"财富榜", @"魅力榜",@"公会榜",@"真爱榜"];
|
||||
self.titles = @[@"房间榜", @"财富榜", @"魅力榜",@"真爱榜"];
|
||||
// self.titles = @[@"房间榜", @"财富榜", @"魅力榜",@"真爱榜"];
|
||||
self.titles = @[@"房间榜", @"财富榜", @"魅力榜"];
|
||||
self.listVCArray = [NSMutableArray array];
|
||||
self.categoryView = [[JXCategoryTitleView alloc] init];
|
||||
self.categoryView.frame = CGRectMake(0, 0, SCREEN_WIDTH-100, 44);
|
||||
|
||||
@@ -105,9 +105,17 @@
|
||||
[self.skyView updateProgress:model];
|
||||
[self.ageView updateProgress:model];
|
||||
[self.timeView updateProgress:model];
|
||||
if (model.status.intValue == 1) {
|
||||
self.acTagView.end_time = model.end_time;
|
||||
[self.view addSubview:self.acTagView];
|
||||
}else{
|
||||
[self.acTagView stopTimer];
|
||||
[self.acTagView removeFromSuperview];
|
||||
}
|
||||
}
|
||||
|
||||
-(void)meetActivityGiftInfoIsUpdate:(QXRoomChatListModel *)giftInfo{
|
||||
[self.meetView updateUserAndGiftInfoWithModel:giftInfo];
|
||||
self.acTagView.end_time = giftInfo.end_time.longLongValue;
|
||||
}
|
||||
@end
|
||||
|
||||
@@ -19,6 +19,7 @@
|
||||
#import "QXAgePraizeView.h"/// 岁月之城
|
||||
#import "QXTimePraizeView.h"/// 时空之巅
|
||||
#import "QXMeetActivityView.h"
|
||||
#import "QXActivityTagView.h"
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
@interface QXRoomViewController : QXBaseViewController<QXRoomMessageManagerDelegate,QXRoomSeatDelegate>
|
||||
@@ -40,6 +41,7 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
|
||||
|
||||
@property (nonatomic,strong)QXActivityTagView *acTagView;
|
||||
@property (nonatomic,strong)QXSkyPraizeView *skyView;
|
||||
@property (nonatomic,strong)QXAgePraizeView *ageView;
|
||||
@property (nonatomic,strong)QXTimePraizeView *timeView;
|
||||
|
||||
@@ -1867,6 +1867,12 @@ QXRoomUserInfoViewDelegate
|
||||
}
|
||||
return _timeView;
|
||||
}
|
||||
-(QXActivityTagView *)acTagView{
|
||||
if (!_acTagView) {
|
||||
_acTagView = [[QXActivityTagView alloc] init];
|
||||
}
|
||||
return _acTagView;
|
||||
}
|
||||
-(QXMeetActivityView *)meetView{
|
||||
if (!_meetView) {
|
||||
_meetView = [[QXMeetActivityView alloc] init];
|
||||
|
||||
17
QXLive/HomePage(声播)/View/房间/QXActivityTagView.h
Normal file
17
QXLive/HomePage(声播)/View/房间/QXActivityTagView.h
Normal file
@@ -0,0 +1,17 @@
|
||||
//
|
||||
// QXActivityTagView.h
|
||||
// QXLive
|
||||
//
|
||||
// Created by 启星 on 2025/9/24.
|
||||
//
|
||||
|
||||
#import <UIKit/UIKit.h>
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
@interface QXActivityTagView : UIView
|
||||
@property (nonatomic,assign)long end_time;
|
||||
-(void)stopTimer;
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
98
QXLive/HomePage(声播)/View/房间/QXActivityTagView.m
Normal file
98
QXLive/HomePage(声播)/View/房间/QXActivityTagView.m
Normal file
@@ -0,0 +1,98 @@
|
||||
//
|
||||
// QXActivityTagView.m
|
||||
// QXLive
|
||||
//
|
||||
// Created by 启星 on 2025/9/24.
|
||||
//
|
||||
|
||||
#import "QXActivityTagView.h"
|
||||
#import "QXTimer.h"
|
||||
@interface QXActivityTagView()
|
||||
@property (nonatomic,strong)UIImageView *imageView;
|
||||
@property (nonatomic,strong)UILabel *timeLabel;
|
||||
@property (nonatomic,strong)QXTimer *timer;
|
||||
@property (nonatomic,assign)NSInteger startTime;
|
||||
@end
|
||||
@implementation QXActivityTagView
|
||||
|
||||
- (instancetype)init
|
||||
{
|
||||
self = [super init];
|
||||
if (self) {
|
||||
self.frame = CGRectMake(SCREEN_WIDTH-80, SCREEN_HEIGHT-250, 80, 100);
|
||||
[self initSubviews];
|
||||
}
|
||||
return self;
|
||||
}
|
||||
|
||||
-(void)initSubviews{
|
||||
self.imageView = [[UIImageView alloc] initWithImage:[UIImage imageNamed:@"ac_tag_icon"]];
|
||||
self.imageView.frame = CGRectMake(0, 0, 80, 80);
|
||||
[self addSubview:self.imageView];
|
||||
|
||||
self.timeLabel = [[UILabel alloc] initWithFrame:CGRectMake(0, self.imageView.bottom, self.width, 20)];
|
||||
self.timeLabel.textAlignment = NSTextAlignmentCenter;
|
||||
self.timeLabel.font = [UIFont systemFontOfSize:12];
|
||||
self.timeLabel.textColor = RGB16(0xFFEBBD);
|
||||
[self addSubview:self.timeLabel];
|
||||
|
||||
UIPanGestureRecognizer *panRecognizer = [[UIPanGestureRecognizer alloc] initWithTarget:self action:@selector(handlePan:)];
|
||||
[self addGestureRecognizer:panRecognizer];
|
||||
}
|
||||
|
||||
|
||||
-(void)setEnd_time:(long)end_time{
|
||||
_end_time = end_time;
|
||||
if (end_time == 0) {
|
||||
return;
|
||||
}
|
||||
NSTimeInterval timeInterval = [[NSDate date] timeIntervalSince1970];
|
||||
// 将秒转换为毫秒
|
||||
long long milliseconds = (long long)(timeInterval);
|
||||
self.startTime = end_time - milliseconds;
|
||||
|
||||
if (self.startTime <= 0) {
|
||||
//时间错误不进行倒计时
|
||||
self.timeLabel.text = @"倒计时 00:00";
|
||||
[self removeFromSuperview];
|
||||
return;
|
||||
}
|
||||
MJWeakSelf
|
||||
[self stopTimer];
|
||||
_timer = [QXTimer scheduledTimerWithTimeInterval:1 repeats:YES queue:dispatch_get_main_queue() block:^{
|
||||
dispatch_async(dispatch_get_main_queue(), ^{
|
||||
weakSelf.startTime--;
|
||||
NSInteger min = (self.startTime % 3600) / 60;
|
||||
NSInteger second = self.startTime % 60;
|
||||
weakSelf.timeLabel.text = [NSString stringWithFormat:@"倒计时 %02ld:%02ld",min,second];
|
||||
if (weakSelf.startTime<=0) {
|
||||
[weakSelf stopTimer];
|
||||
weakSelf.timeLabel.text = @"倒计时 00:00";
|
||||
[weakSelf removeFromSuperview];
|
||||
}
|
||||
});
|
||||
}];
|
||||
}
|
||||
-(void)stopTimer{
|
||||
if (_timer) {
|
||||
[self->_timer invalidate];
|
||||
self->_timer= nil;
|
||||
}
|
||||
}
|
||||
-(void)handlePan:(UIPanGestureRecognizer*)recognizer{
|
||||
if (recognizer.state == UIGestureRecognizerStateEnded) {
|
||||
NSLog(@"拖动结束");
|
||||
}
|
||||
CGPoint translation = [recognizer translationInView:self.viewController.view];
|
||||
CGPoint panCenter = CGPointMake(recognizer.view.center.x + translation.x,
|
||||
recognizer.view.center.y + translation.y);
|
||||
if (panCenter.y < kSafeAreaTop || panCenter.y> SCREEN_HEIGHT-kSafeAreaBottom) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
recognizer.view.center = CGPointMake(SCREEN_WIDTH-ScaleWidth(80)/2,
|
||||
recognizer.view.center.y + translation.y);
|
||||
[recognizer setTranslation:CGPointZero inView:self.viewController.view];
|
||||
}
|
||||
@end
|
||||
@@ -168,7 +168,7 @@ NSInteger maxMessageCount = 20;
|
||||
-(void)insertNoitce{
|
||||
QXRoomChatListModel *model = [QXRoomChatListModel new];
|
||||
model.messageType = QXRoomChatMessageTypeSystem;
|
||||
model.text = @"秘地严禁未成年人进行直播或打赏,官方将24小时在线巡查。我们提倡绿色直播,直播间严禁出现涉政、涉恐、涉黄、涉赌等违法违规内容,严禁宣传封建迷信、宗教极端思想、出现低俗色情、吸烟酗酒等内容,严禁违反社会主义核心价值观、践踏社会道德底线、诱导打赏、低俗 PK 、买卖金币等行为,请大家共同遵守、监督并及时举报。请勿相信各类刷钻、购买礼包、游戏币及电商贩卖等非官方广告信息,谨防网络诈骗。";
|
||||
model.text = @"MY语聊严禁未成年人进行直播或打赏,官方将24小时在线巡查。我们提倡绿色直播,直播间严禁出现涉政、涉恐、涉黄、涉赌等违法违规内容,严禁宣传封建迷信、宗教极端思想、出现低俗色情、吸烟酗酒等内容,严禁违反社会主义核心价值观、践踏社会道德底线、诱导打赏、低俗 PK 、买卖金币等行为,请大家共同遵守、监督并及时举报。请勿相信各类刷钻、购买礼包、游戏币及电商贩卖等非官方广告信息,谨防网络诈骗。";
|
||||
[self.dataArray addObject:model];
|
||||
[self.tableView reloadData];
|
||||
[self scrollToBottom];
|
||||
|
||||
@@ -183,8 +183,8 @@
|
||||
-(void)initSubviews{
|
||||
self.selectedBgBtn = [[UIButton alloc] initWithFrame:CGRectMake(0, 0, self.width, self.height)];
|
||||
[self.selectedBgBtn setBackgroundImage:[UIImage imageNamed:@"room_sound_sel"] forState:(UIControlStateSelected)];
|
||||
[self.selectedBgBtn setBackgroundImage:[UIImage imageWithColor:RGB16A(0xE9E9E9, 0.2)] forState:(UIControlStateNormal)];
|
||||
[self.selectedBgBtn addRoundedCornersWithRadius:12];
|
||||
[self.selectedBgBtn setBackgroundImage:[UIImage imageWithColor:RGB16A(0xE9E9E9, 0.4)] forState:(UIControlStateNormal)];
|
||||
[self.selectedBgBtn addRoundedCornersWithRadius:5];
|
||||
self.selectedBgBtn.userInteractionEnabled = NO;
|
||||
[self.contentView addSubview:self.selectedBgBtn];
|
||||
|
||||
|
||||
@@ -96,7 +96,7 @@
|
||||
UITapGestureRecognizer *tap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(hide)];
|
||||
tap.delegate = self;
|
||||
[self addGestureRecognizer:tap];
|
||||
self.bgView = [[UIView alloc] initWithFrame:CGRectMake(0, SCREEN_HEIGHT, SCREEN_WIDTH, kSafeAreaBottom+ScaleWidth(429+33))];
|
||||
self.bgView = [[UIView alloc] initWithFrame:CGRectMake(0, SCREEN_HEIGHT, SCREEN_WIDTH, kSafeAreaBottom+ScaleWidth(429-141-50+33))];
|
||||
// self.bgView.backgroundColor = [UIColor whiteColor];
|
||||
[self addSubview:self.bgView];
|
||||
|
||||
@@ -385,7 +385,9 @@
|
||||
make.left.mas_equalTo(16);
|
||||
make.right.mas_equalTo(-16);
|
||||
// make.bottom.mas_equalTo(-(kSafeAreaBottom+10));
|
||||
make.top.equalTo(self.relationTableView.mas_bottom).offset(20);
|
||||
// make.top.equalTo(self.relationTableView.mas_bottom).offset(20);
|
||||
make.top.equalTo(self.giftTitleLabel.mas_bottom).offset(12);
|
||||
|
||||
make.height.mas_equalTo(35);
|
||||
}];
|
||||
|
||||
@@ -410,6 +412,11 @@
|
||||
}];
|
||||
}
|
||||
|
||||
|
||||
self.relationMoreBtn.hidden = YES;
|
||||
self.relationshipSeatBtn.hidden = YES;
|
||||
self.relationshipCardBtn.hidden = YES;
|
||||
self.relationTableView.hidden = YES;
|
||||
}
|
||||
-(BOOL)gestureRecognizer:(UIGestureRecognizer *)gestureRecognizer shouldReceiveTouch:(UITouch *)touch{
|
||||
return touch.view == self;
|
||||
@@ -878,7 +885,7 @@
|
||||
-(void)showInView:(UIView *)view{
|
||||
[view addSubview:self];
|
||||
[UIView animateWithDuration:0.3 animations:^{
|
||||
self.bgView.y = SCREEN_HEIGHT- ScaleWidth(429+33)-kSafeAreaBottom;
|
||||
self.bgView.y = SCREEN_HEIGHT- ScaleWidth(429-141-50+33)-kSafeAreaBottom;
|
||||
}];
|
||||
}
|
||||
-(void)hide{
|
||||
|
||||
@@ -172,13 +172,13 @@
|
||||
case QXRoomRoleTypeCompere:{
|
||||
if ((self.roomModel.room_info.type_id.intValue == 1 || self.roomModel.room_info.type_id.intValue == 3 || self.roomModel.room_info.type_id.intValue == 4 || self.roomModel.room_info.type_id.intValue == 8) && self.roomModel.room_info.label_id.intValue == 2) {
|
||||
toolsArr = @[self.roomSubsidy,self.roomMessage,self.roomOrderMic,self.roomBgImage];
|
||||
roomTypeArr = @[self.roomTypeSing,self.roomTypeAuction,self.roomTypeFunny,self.roomTypeFriend];
|
||||
roomTypeArr = @[self.roomTypeSing,self.roomTypeBoy,self.roomTypeGirl];
|
||||
moreArr = @[self.roomLeave,self.roomVoiceSet,self.roomSetting,self.roomEffects,self.drifPop,self.roomReport];
|
||||
// roomTypeArr = @[self.roomTypeSing,self.roomTypeAuction,self.roomTypeBoy,self.roomTypeGirl,self.roomTypeFriend];
|
||||
// moreArr = @[self.roomLeave,self.roomShare,self.roomVoiceSet,self.roomSetting,self.roomWelcome,self.roomEffects,self.roomReport];
|
||||
}else{
|
||||
toolsArr = @[self.roomSubsidy,self.roomMessage,self.roomOrderMic,self.roomBgMusic,self.roomBgImage];
|
||||
roomTypeArr = @[self.roomTypeSing,self.roomTypeAuction,self.roomTypeFunny,self.roomTypeFriend];
|
||||
roomTypeArr = @[self.roomTypeSing,self.roomTypeBoy,self.roomTypeGirl];
|
||||
moreArr = @[self.roomLeave,self.roomVoiceSet,self.roomSetting,self.roomEffects,self.drifPop,self.roomReport];
|
||||
// roomTypeArr = @[self.roomTypeSing,self.roomTypeAuction,self.roomTypeBoy,self.roomTypeGirl,self.roomTypeFriend];
|
||||
// moreArr = @[self.roomLeave,self.roomShare,self.roomVoiceSet,self.roomSetting,self.roomWelcome,self.roomEffects,self.roomReport];
|
||||
@@ -208,7 +208,7 @@
|
||||
// toolsArr = @[self.roomSubsidy,self.roomCompere,self.roomMessage,self.roomOrderMic,self.roomBgMusic,self.roomBgImage];
|
||||
toolsArr = @[self.roomSubsidy,self.roomCompere,self.roomMessage,self.roomOrderMic,self.roomBgImage];
|
||||
}
|
||||
roomTypeArr = @[self.roomTypeSing,self.roomTypeAuction,self.roomTypeFunny,self.roomTypeFriend];
|
||||
roomTypeArr = @[self.roomTypeSing,self.roomTypeBoy,self.roomTypeGirl];
|
||||
moreArr = @[self.roomLeave,self.roomVoiceSet,self.roomSetting,self.roomEffects,self.drifPop,self.roomReport];
|
||||
// moreArr = @[self.roomLeave,self.roomShare,self.roomVoiceSet,self.roomSetting,self.roomWelcome,self.roomEffects,self.roomReport];
|
||||
// roomTypeArr = @[self.roomTypeSing,self.roomTypeAuction,self.roomTypeBoy,self.roomTypeGirl,self.roomTypeFriend];
|
||||
@@ -229,7 +229,7 @@
|
||||
toolsArr = @[self.roomSubsidy,self.roomCompere,self.roomMessage,self.roomOrderMic,self.roomBgImage];
|
||||
}
|
||||
// roomTypeArr = @[self.roomTypeSing,self.roomTypeAuction,self.roomTypeBoy,self.roomTypeGirl,self.roomTypeFriend];
|
||||
roomTypeArr = @[self.roomTypeSing,self.roomTypeAuction,self.roomTypeFunny,self.roomTypeFriend];
|
||||
roomTypeArr = @[self.roomTypeSing,self.roomTypeBoy,self.roomTypeGirl];
|
||||
// moreArr = @[self.roomLeave,self.roomShare,self.roomVoiceSet,self.roomSetting,self.roomWelcome,self.roomEffects,self.roomReport];
|
||||
moreArr = @[self.roomLeave,self.roomVoiceSet,self.roomSetting,self.roomEffects,self.drifPop,self.roomReport];
|
||||
self.titles = @[QXText(@"房间类型"),QXText(@"常用工具"),QXText(@"更多操作")];
|
||||
@@ -240,6 +240,7 @@
|
||||
}
|
||||
self.dataDict = @{
|
||||
QXText(@"房间类型"):roomTypeArr,
|
||||
|
||||
QXText(@"常用工具"):toolsArr,
|
||||
QXText(@"更多操作"):moreArr
|
||||
};
|
||||
|
||||
@@ -198,6 +198,7 @@
|
||||
//
|
||||
self.helpBtn = [[UIButton alloc] init];
|
||||
[self.helpBtn setImage:[UIImage imageNamed:@"room_auction_help"] forState:(UIControlStateNormal)];
|
||||
[self.helpBtn addTarget:self action:@selector(helpAction) forControlEvents:(UIControlEventTouchUpInside)];
|
||||
[self.bgView addSubview:self.helpBtn];
|
||||
[self.helpBtn mas_makeConstraints:^(MASConstraintMaker *make) {
|
||||
make.top.mas_equalTo(5);
|
||||
@@ -1047,6 +1048,20 @@
|
||||
[self.rankView showInView:self.viewController.view];
|
||||
}
|
||||
|
||||
-(void)helpAction{
|
||||
NSString *Id = @"";
|
||||
if ([self.roomModel.room_info.label_id isEqualToString:@"1"]) {
|
||||
/// 真爱
|
||||
Id = @"23";
|
||||
}else{
|
||||
/// 亲密
|
||||
Id = @"22";
|
||||
}
|
||||
NSString *urlString = [NSString stringWithFormat:@"%@api/Page/page_show?id=%@",ServerUrl,Id];
|
||||
QXBaseWebViewController *vc = [[QXBaseWebViewController alloc] init];
|
||||
vc.urlStr = urlString;
|
||||
[self.viewController.navigationController pushViewController:vc animated:YES];
|
||||
}
|
||||
|
||||
-(void)changeAuctionWithType:(UIButton*)sender{
|
||||
NSString *type = @"";
|
||||
@@ -1075,6 +1090,7 @@
|
||||
}
|
||||
|
||||
-(void)auctionTypeDidChanged:(NSString *)type{
|
||||
self.roomModel.room_info.label_id = type;
|
||||
if ([type isEqualToString:@"2"]) {
|
||||
self.realLoveBtn.selected = NO;
|
||||
self.intimacyBtn.selected = YES;
|
||||
|
||||
@@ -44,7 +44,7 @@ NS_ASSUME_NONNULL_BEGIN
|
||||
@property (nonatomic,assign) BOOL isOnece;
|
||||
@property (nonatomic,strong) VAPView *playerMp4View;
|
||||
@property (nonatomic, strong) dispatch_queue_t queue;
|
||||
-(void)previewEffectWith:(NSString *)play_image;
|
||||
- (void)previewEffectWith:(NSString *)play_image;
|
||||
- (void)displayEffectView:(NSString *)play_image;
|
||||
- (void)displayEffectViewWithMorePlayImages:(NSArray *)playImages;
|
||||
- (void)openOrCloseEffectViewWith:(BOOL)isShow;
|
||||
|
||||
@@ -58,11 +58,12 @@ static NSInteger maxCount = 5;
|
||||
}
|
||||
}else{
|
||||
for (QXGiftScrollModel*md in list) {
|
||||
[self.dataArray removeLastObject];
|
||||
[self.titles removeLastObject];
|
||||
[self.dataArray insertObject:md atIndex:0];
|
||||
[self.titles insertObject:md.fromUserName atIndex:0];
|
||||
|
||||
}
|
||||
if (self.dataArray.count > 5) {
|
||||
[self.dataArray removeLastObject];
|
||||
[self.titles removeLastObject];
|
||||
}
|
||||
}
|
||||
self.cycleScrollView.imageURLStringsGroup = self.titles;
|
||||
|
||||
Reference in New Issue
Block a user