|
@@ -3,6 +3,7 @@ package com.swago.room.dialog
|
|
|
import android.annotation.SuppressLint
|
|
|
import android.os.Bundle
|
|
|
import android.view.Gravity
|
|
|
+import android.view.View
|
|
|
import com.bumptech.glide.Glide
|
|
|
import com.swago.baseswago.baseroom.SwagoRoomManager
|
|
|
import com.swago.baseswago.dialog.BaseXDFragment
|
|
@@ -23,11 +24,12 @@ class AnchorCloseDialog : BaseXDFragment<DialogAnchorCloseBinding>(){
|
|
|
private var roomType:Int = 1
|
|
|
|
|
|
companion object{
|
|
|
- fun newInstance(anchorCloseModel:AnchorClosedModel ,roomType: Int):AnchorCloseDialog{
|
|
|
+ fun newInstance(anchorCloseModel:AnchorClosedModel ,roomType: Int , checkPassword: Boolean):AnchorCloseDialog{
|
|
|
val dialog = AnchorCloseDialog()
|
|
|
val bundle = Bundle()
|
|
|
bundle.putParcelable("model",anchorCloseModel)
|
|
|
bundle.putInt("roomType",roomType)
|
|
|
+ bundle.putBoolean("checkPassword",checkPassword)
|
|
|
dialog.arguments = bundle
|
|
|
return dialog
|
|
|
}
|
|
@@ -47,6 +49,12 @@ class AnchorCloseDialog : BaseXDFragment<DialogAnchorCloseBinding>(){
|
|
|
arguments?.let {
|
|
|
anchorCloseModel = it.getParcelable("model")
|
|
|
roomType = it.getInt("roomType")
|
|
|
+ val checkPassword = it.getBoolean("checkPassword")
|
|
|
+ if (checkPassword){
|
|
|
+ binding.tvPassword.visibility = View.VISIBLE
|
|
|
+ } else {
|
|
|
+ binding.tvPassword.visibility = View.GONE
|
|
|
+ }
|
|
|
if (roomType == RoomType.VIDEO.type){
|
|
|
binding.tvIncome.text = getString(R.string.income_of_this_live)
|
|
|
binding.tvTime.text = getString(R.string.duration_of_this_live)
|