修复bug

This commit is contained in:
liyuhua
2023-09-20 14:01:55 +08:00
parent d87ac12794
commit 665df1a770
5 changed files with 12 additions and 2 deletions

View File

@@ -34,7 +34,7 @@ target 'xplan-ios' do
#文字自动滚动
pod 'MarqueeLabel-ObjC'
#声网
pod 'AgoraRtcEngine_iOS', '~> 3.0.1'
pod 'AgoraRtcEngine_iOS', '~> 4.2.2'
#TRTC
pod 'TXLiteAVSDK_TRTC', '~> 10.3.12271'
#pop动画

View File

@@ -395,6 +395,9 @@
GiftSendType sendType = GiftSendType_OnMic;
///
GiftSourceType sourceType = giftInfo.sourceType;
if(sourceType != GiftSourceType_Normal && sourceType != GiftSourceType_Pack){
sourceType = _segmentType == GiftSegmentType_Pack ? GiftSourceType_Pack :GiftSourceType_Normal;
}
///
RoomSendGiftType roomSendType = [self dealRoomSendGiftType:giftInfo giftCount:giftCount];
if (roomSendType == -1) {
@@ -418,6 +421,9 @@
GiftSendType sendType = GiftSendType_Chat;
///
GiftSourceType sourceType = giftInfo.sourceType;
if(sourceType != GiftSourceType_Normal && sourceType != GiftSourceType_Pack){
sourceType = _segmentType == GiftSegmentType_Pack ? GiftSourceType_Pack :GiftSourceType_Normal;
}
///
RoomSendGiftType roomSendType = RoomSendGiftType_ToOne;
self.giftBarView.sendButtonIsEnable = NO;

View File

@@ -12,6 +12,7 @@
NS_ASSUME_NONNULL_BEGIN
@interface XPRoomAnimationView : XPRoomAnimationHitView <RoomGuestDelegate>
-(void)resumeTimer;
- (instancetype)initWithDelegate:(id<RoomHostDelegate>)delegate;
@end

View File

@@ -144,6 +144,9 @@
- (void)dealloc {
[NSObject cancelPreviousPerformRequestsWithTarget:self];
[[NIMSDK sharedSDK].broadcastManager removeDelegate:self];
}
-(void)resumeTimer{
if(self.giftEffectTimer != nil){
dispatch_resume(self.giftEffectTimer);
self.giftEffectTimer = nil;
@@ -157,7 +160,6 @@
self.giftTimer = nil;
}
}
- (instancetype)initWithDelegate:(id<RoomHostDelegate>)delegate {
self = [super init];
if (self) {

View File

@@ -1378,6 +1378,7 @@ NSString * const kHadQuitOtherRoomKey = @"kHadQuitOtherRoomKey";//是否退出
- (void)exitRoom {
[self.menuContainerView menuResignFirstResponder];
[self.animationView resumeTimer];
if (self.roomInfo.roomModeType == RoomModeType_Open_Micro_Mode || self.roomInfo.roomModeType == RoomModeType_Open_Blind) {
NSString * roomUid = [NSString stringWithFormat:@"%ld", self.roomInfo.uid];
NSString * uid = [AccountInfoStorage instance].getUid;