Commit dc229f8e by suolong

修改部分 修改需求

parent fc0f0608
...@@ -189,7 +189,7 @@ typedef NS_ENUM(NSUInteger, FUSLiveChatToolBeautyType) { //美颜工具按钮 ...@@ -189,7 +189,7 @@ typedef NS_ENUM(NSUInteger, FUSLiveChatToolBeautyType) { //美颜工具按钮
/// @param type 按钮类型 /// @param type 按钮类型
/// @param image 图片 /// @param image 图片
/// @param state 按钮的状态 /// @param state 按钮的状态
- (void)fus_updateBtnImageWithType:(FUSLiveBottomToolType)type image:(UIImage *)image state:(UIControlState *)state; - (void)fus_updateBtnImageWithType:(FUSLiveBottomToolType)type image:(UIImage *)image state:(UIControlState)state;
/** /**
停止pk匹配计时器 停止pk匹配计时器
......
...@@ -583,7 +583,7 @@ ...@@ -583,7 +583,7 @@
} }
} }
- (void)fus_updateBtnImageWithType:(FUSLiveBottomToolType)type image:(UIImage *)image state:(UIControlState *)state{ - (void)fus_updateBtnImageWithType:(FUSLiveBottomToolType)type image:(UIImage *)image state:(UIControlState)state{
for (UIButton *btn in _allBtns) { for (UIButton *btn in _allBtns) {
if (btn.tag == type) { if (btn.tag == type) {
......
...@@ -993,6 +993,7 @@ ...@@ -993,6 +993,7 @@
- (void)fus_bottomToolView:(FUSLiveBottomToolView *)bottomToolView didClickShowTimeOnView:(UIView *)containerView { - (void)fus_bottomToolView:(FUSLiveBottomToolView *)bottomToolView didClickShowTimeOnView:(UIView *)containerView {
UIView *popContainer = (containerView ?: [UIViewController fus_topViewController].view); UIView *popContainer = (containerView ?: [UIViewController fus_topViewController].view);
__weak typeof(self) weakSelf = self; __weak typeof(self) weakSelf = self;
__weak typeof(bottomToolView) weakBottomToolView = bottomToolView;
FUSRoomTicketShowConfig *ticketShowConfig = [FUSLiveHelper shareInstance].liveBeforeReadyInfo.ticketShowConfig; FUSRoomTicketShowConfig *ticketShowConfig = [FUSLiveHelper shareInstance].liveBeforeReadyInfo.ticketShowConfig;
NSString *defaultThemeText = [FUSLiveHelper shareInstance].roomInfoModel.introduce; NSString *defaultThemeText = [FUSLiveHelper shareInstance].roomInfoModel.introduce;
FUSLiveShowTimePopView *popView = [FUSLiveShowTimePopView fus_showOnView:popContainer ticketShowConfig:ticketShowConfig themeText:defaultThemeText]; FUSLiveShowTimePopView *popView = [FUSLiveShowTimePopView fus_showOnView:popContainer ticketShowConfig:ticketShowConfig themeText:defaultThemeText];
...@@ -1002,6 +1003,11 @@ ...@@ -1002,6 +1003,11 @@
return; return;
} }
BOOL tool2ExistedBeforeStart = NO;
if (weakBottomToolView) {
tool2ExistedBeforeStart = !CGRectEqualToRect([weakBottomToolView fus_getBtnFrameWithToolType:FUSLiveBottomToolTypeTool2], CGRectZero);
}
UIView *onView = [[FUSLiveHelper shareInstance].currentFunctionView fus_viewWithLayer:FUSLiveFunctionLayerFunctionButtons]; UIView *onView = [[FUSLiveHelper shareInstance].currentFunctionView fus_viewWithLayer:FUSLiveFunctionLayerFunctionButtons];
if (!onView) { if (!onView) {
onView = [FUSLiveHelper shareInstance].currentLiveVCView ?: popContainer; onView = [FUSLiveHelper shareInstance].currentLiveVCView ?: popContainer;
...@@ -1049,6 +1055,15 @@ ...@@ -1049,6 +1055,15 @@
[innerSelf.showTimeFrostedView removeFromSuperview]; [innerSelf.showTimeFrostedView removeFromSuperview];
} }
if (FUSLiveHelper.shareInstance.liveType == FUSLiveTypeAnchor && weakBottomToolView) {
[weakBottomToolView fus_removeBtnWithType:FUSLiveBottomToolTypeTool2];
UIImage *ticketImage = [FUSShowRoomCenterBunble imageNamed:@"Live_bottom_ticket"];
if (ticketImage) {
[weakBottomToolView fus_updateBtnImageWithType:FUSLiveBottomToolTypeRoomScope image:ticketImage state:UIControlStateNormal];
[weakBottomToolView fus_updateBtnImageWithType:FUSLiveBottomToolTypeRoomScope image:ticketImage state:UIControlStateHighlighted];
}
}
FUSLiveShowTimeCollectFrostedView *bar = [FUSLiveShowTimeCollectFrostedView fus_showOnView:onView]; FUSLiveShowTimeCollectFrostedView *bar = [FUSLiveShowTimeCollectFrostedView fus_showOnView:onView];
innerSelf.showTimeFrostedView = bar; innerSelf.showTimeFrostedView = bar;
innerSelf.showTimeRoundId = model.stageData.roundId ?: @""; innerSelf.showTimeRoundId = model.stageData.roundId ?: @"";
...@@ -1071,6 +1086,12 @@ ...@@ -1071,6 +1086,12 @@
[FUSLoadingView fus_dismissProgressView]; [FUSLoadingView fus_dismissProgressView];
[cancelSelf fus_destroyShowTimeFrostedIfNeeded]; [cancelSelf fus_destroyShowTimeFrostedIfNeeded];
cancelSelf.showTimeRoundId = @""; cancelSelf.showTimeRoundId = @"";
if (FUSLiveHelper.shareInstance.liveType == FUSLiveTypeAnchor && weakBottomToolView) {
if (tool2ExistedBeforeStart) {
[weakBottomToolView fus_insertBtnWithType:FUSLiveBottomToolTypeTool2 index:2];
}
[weakBottomToolView fus_updateRoomScoreType];
}
}); });
} failure:^(NSString * _Nonnull msg, NSInteger code) { } failure:^(NSString * _Nonnull msg, NSInteger code) {
dispatch_async(dispatch_get_main_queue(), ^{ dispatch_async(dispatch_get_main_queue(), ^{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment