룰렛 변경
- 확률 수동 설정 - 여러개의 룰렛이 켜져있을 때 선택하여 돌리기 - 후원 히스토리에 룰렛 히스토리
This commit is contained in:
@@ -168,76 +168,46 @@ struct LiveRoomViewV2: View {
|
||||
.padding(.top, 16)
|
||||
|
||||
VStack(alignment: .trailing, spacing: 0) {
|
||||
Image(viewModel.isSpeakerMute ? "ic_speaker_off" : "ic_speaker_on")
|
||||
.resizable()
|
||||
.frame(width: 26.7, height: 26.7)
|
||||
.padding(11)
|
||||
.background(Color(hex: "525252").opacity(0.6))
|
||||
.cornerRadius(10)
|
||||
.onTapGesture {
|
||||
viewModel.toggleSpeakerMute()
|
||||
}
|
||||
.padding(.top, 26.7)
|
||||
.padding(.trailing, 13.3)
|
||||
LiveRoomRightBottomButton(
|
||||
imageName: viewModel.isSpeakerMute ? "ic_speaker_off" : "ic_speaker_on",
|
||||
onClick: { viewModel.toggleSpeakerMute() }
|
||||
)
|
||||
.padding(.top, 26.7)
|
||||
.padding(.trailing, 13.3)
|
||||
|
||||
Spacer()
|
||||
|
||||
VStack(spacing: 13.3) {
|
||||
if liveRoomInfo.creatorId == UserDefaults.int(forKey: .userId) {
|
||||
Image("ic_roulette_settings")
|
||||
.resizable()
|
||||
.frame(width: 26.7, height: 26.7)
|
||||
.padding(11)
|
||||
.background(Color(hex: "525252").opacity(0.6))
|
||||
.cornerRadius(10)
|
||||
.onTapGesture {
|
||||
viewModel.isShowRouletteSettings = true
|
||||
}
|
||||
LiveRoomRightBottomButton(
|
||||
imageName: "ic_roulette_settings",
|
||||
onClick: { viewModel.isShowRouletteSettings = true }
|
||||
)
|
||||
} else if liveRoomInfo.creatorId != UserDefaults.int(forKey: .userId) && viewModel.isActiveRoulette {
|
||||
Image("ic_roulette")
|
||||
.resizable()
|
||||
.frame(width: 26.7, height: 26.7)
|
||||
.padding(11)
|
||||
.background(Color(hex: "525252").opacity(0.6))
|
||||
.cornerRadius(10)
|
||||
.onTapGesture {
|
||||
viewModel.showRoulette()
|
||||
}
|
||||
LiveRoomRightBottomButton(
|
||||
imageName: "ic_roulette",
|
||||
onClick: { viewModel.showRoulette() }
|
||||
)
|
||||
}
|
||||
|
||||
if viewModel.role == .SPEAKER {
|
||||
Image(viewModel.isMute ? "ic_mic_off" : "ic_mic_on")
|
||||
.resizable()
|
||||
.frame(width: 26.7, height: 26.7)
|
||||
.padding(11)
|
||||
.background(Color(hex: "525252").opacity(0.6))
|
||||
.cornerRadius(10)
|
||||
.onTapGesture {
|
||||
viewModel.toggleMute()
|
||||
}
|
||||
LiveRoomRightBottomButton(
|
||||
imageName: viewModel.isMute ? "ic_mic_off" : "ic_mic_on",
|
||||
onClick: { viewModel.toggleMute() }
|
||||
)
|
||||
}
|
||||
|
||||
if liveRoomInfo.creatorId == UserDefaults.int(forKey: .userId) &&
|
||||
UserDefaults.string(forKey: .role) == MemberRole.CREATOR.rawValue {
|
||||
Image("ic_donation_message_list")
|
||||
.resizable()
|
||||
.frame(width: 26.7, height: 26.7)
|
||||
.padding(11)
|
||||
.background(Color(hex: "525252").opacity(0.6))
|
||||
.cornerRadius(10)
|
||||
.onTapGesture {
|
||||
viewModel.isShowDonationMessagePopup = true
|
||||
}
|
||||
LiveRoomRightBottomButton(
|
||||
imageName: "ic_donation_message_list",
|
||||
onClick: { viewModel.isShowDonationMessagePopup = true }
|
||||
)
|
||||
} else {
|
||||
Image("ic_donation")
|
||||
.resizable()
|
||||
.frame(width: 26.7, height: 26.7)
|
||||
.padding(11)
|
||||
.background(Color(hex: "525252").opacity(0.6))
|
||||
.cornerRadius(10)
|
||||
.onTapGesture {
|
||||
viewModel.isShowDonationPopup = true
|
||||
}
|
||||
LiveRoomRightBottomButton(
|
||||
imageName: "ic_donation",
|
||||
onClick: { viewModel.isShowDonationPopup = true }
|
||||
)
|
||||
}
|
||||
}
|
||||
.padding(.trailing, 13.3)
|
||||
@@ -629,12 +599,12 @@ struct LiveRoomViewV2: View {
|
||||
}
|
||||
}
|
||||
|
||||
if let preview = viewModel.roulettePreview, viewModel.isShowRoulettePreview {
|
||||
if !viewModel.roulettePreviewList.isEmpty && viewModel.isShowRoulettePreview {
|
||||
RoulettePreviewDialog(
|
||||
isShowing: $viewModel.isShowRoulettePreview,
|
||||
title: nil,
|
||||
onClickSpin: { viewModel.spinRoulette() },
|
||||
preview: preview
|
||||
onClickSpin: { viewModel.spinRoulette(rouletteId: $0) },
|
||||
previewList: viewModel.roulettePreviewList
|
||||
)
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user