This commit is contained in:
启星
2025-09-23 09:13:16 +08:00
parent 048b9339eb
commit 0f6df9fb87
17 changed files with 188 additions and 25 deletions

View File

@@ -14,7 +14,7 @@
#import "QXMeetLotteryView.h"
#import "QXDiamondViewController.h"
@interface QXMeetActivityView()<UIGestureRecognizerDelegate,QXMeetLotteryViewDelegate>
@interface QXMeetActivityView()<UIGestureRecognizerDelegate,QXMeetLotteryViewDelegate,QXMeetActivityViewDelegate>
@property (nonatomic,strong)UIView *bgView;
@property (nonatomic,strong)UIImageView *bgImageView;
///
@@ -146,6 +146,7 @@
[self.bgView addSubview:self.recordBtn];
self.timeDownView = [[QXMeetTimeDownView alloc] initWithFrame:CGRectMake((self.bgView.width-ScaleWidth(122))/2, self.rankBtn.top-4, ScaleWidth(122), ScaleWidth(29))];
self.timeDownView.delegate = self;
[self.bgView addSubview:self.timeDownView];
self.giftImageView = [[UIImageView alloc] initWithFrame:CGRectMake((self.bgView.width-ScaleWidth(118))/2, self.timeDownView.bottom+11, ScaleWidth(118), ScaleWidth(118))];
@@ -325,6 +326,9 @@
}
}
}
-(void)timeDownDidFinished{
[self hide];
}
-(BOOL)gestureRecognizer:(UIGestureRecognizer *)gestureRecognizer shouldReceiveTouch:(UITouch *)touch{
return touch.view == self;
}
@@ -624,10 +628,10 @@
NSString *time = [NSString stringWithFormat:@"%02ld%02ld",min,second];
if (time.length == 4) {
self.timeLabel1.text = [time substringWithRange:NSMakeRange(0, 1)];
self.timeLabel2.text = [time substringWithRange:NSMakeRange(1, 1)];
self.timeLabel3.text = [time substringWithRange:NSMakeRange(2, 1)];
self.timeLabel4.text = [time substringWithRange:NSMakeRange(3, 1)];
weakSelf.timeLabel1.text = [time substringWithRange:NSMakeRange(0, 1)];
weakSelf.timeLabel2.text = [time substringWithRange:NSMakeRange(1, 1)];
weakSelf.timeLabel3.text = [time substringWithRange:NSMakeRange(2, 1)];
weakSelf.timeLabel4.text = [time substringWithRange:NSMakeRange(3, 1)];
}
if (weakSelf.startTime<=0) {
[weakSelf stopTimer];
@@ -635,6 +639,9 @@
weakSelf.timeLabel2.text = @"0";
weakSelf.timeLabel3.text = @"0";
weakSelf.timeLabel4.text = @"0";
if (weakSelf.delegate && [weakSelf.delegate respondsToSelector:@selector(timeDownDidFinished)]) {
[weakSelf.delegate timeDownDidFinished];
}
}
});
}];