mirror of
https://github.com/nextcloud/talk-android.git
synced 2024-11-26 23:25:20 +03:00
hide "reply" and "forward" when chatPermission is missing
"forward" is also hidden because this would need bigger changes regarding the state of the hasChatPermission variable inside the ChatController.kt Signed-off-by: Marcel Hibbe <dev@mhibbe.de>
This commit is contained in:
parent
96721a2df6
commit
b603031011
2 changed files with 4 additions and 3 deletions
|
@ -587,7 +587,7 @@ class ChatController(args: Bundle) :
|
|||
}
|
||||
}
|
||||
|
||||
if (context != null) {
|
||||
if (context != null && hasChatPermission && !isReadOnlyConversation()) {
|
||||
val messageSwipeController = MessageSwipeCallback(
|
||||
activity!!,
|
||||
object : MessageSwipeActions {
|
||||
|
|
|
@ -74,7 +74,7 @@ class MessageActionsDialog(
|
|||
|
||||
initEmojiBar(hasChatPermission)
|
||||
initMenuItemCopy(!message.isDeleted)
|
||||
initMenuReplyToMessage(message.replyable)
|
||||
initMenuReplyToMessage(message.replyable && hasChatPermission)
|
||||
initMenuReplyPrivately(
|
||||
message.replyable &&
|
||||
hasUserId(user) &&
|
||||
|
@ -83,7 +83,8 @@ class MessageActionsDialog(
|
|||
)
|
||||
initMenuDeleteMessage(showMessageDeletionButton)
|
||||
initMenuForwardMessage(
|
||||
ChatMessage.MessageType.REGULAR_TEXT_MESSAGE == message.getMessageType() &&
|
||||
hasChatPermission &&
|
||||
ChatMessage.MessageType.REGULAR_TEXT_MESSAGE == message.getMessageType() &&
|
||||
!(message.isDeletedCommentMessage || message.isDeleted)
|
||||
)
|
||||
initMenuMarkAsUnread(
|
||||
|
|
Loading…
Reference in a new issue