댓글 입력 비어 있을 때 전송 방지
This commit is contained in:
@@ -81,7 +81,12 @@ class UserProfileCheersAdapter(
|
||||
binding.tvModify.setOnClickListener {
|
||||
binding.rlContentModify.visibility = View.GONE
|
||||
binding.tvContent.visibility = View.VISIBLE
|
||||
modifyCheers(cheers.cheersId, binding.etContentModify.text.toString())
|
||||
|
||||
val content = binding.etContentModify.text.toString()
|
||||
binding.etContentModify.setText("")
|
||||
if (content.isEmpty()) return@setOnClickListener
|
||||
|
||||
modifyCheers(cheers.cheersId, content)
|
||||
}
|
||||
} else {
|
||||
binding.ivMenu.visibility = View.GONE
|
||||
@@ -100,6 +105,8 @@ class UserProfileCheersAdapter(
|
||||
binding.rlCheerReply.visibility = View.VISIBLE
|
||||
binding.tvSend.setOnClickListener {
|
||||
val content = binding.etCheerReply.text.toString()
|
||||
binding.etCheerReply.setText("")
|
||||
if (content.isEmpty()) return@setOnClickListener
|
||||
modifyReply(reply.cheersId, content)
|
||||
}
|
||||
}
|
||||
@@ -114,6 +121,8 @@ class UserProfileCheersAdapter(
|
||||
binding.rlCheerReply.visibility = View.VISIBLE
|
||||
binding.tvSend.setOnClickListener {
|
||||
val content = binding.etCheerReply.text.toString()
|
||||
binding.etCheerReply.setText("")
|
||||
if (content.isEmpty()) return@setOnClickListener
|
||||
enterReply(cheers.cheersId, content)
|
||||
}
|
||||
}
|
||||
@@ -122,6 +131,8 @@ class UserProfileCheersAdapter(
|
||||
}
|
||||
}
|
||||
|
||||
binding.etCheerReply.setText("")
|
||||
binding.etContentModify.setText("")
|
||||
binding.tvReply.requestLayout()
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user