Enable markdown (if active) when sending emote (Fixes #734)

This commit is contained in:
Benoit Marty 2020-05-21 00:27:19 +02:00
parent 628439aa65
commit e156a62e19
2 changed files with 4 additions and 1 deletions

View File

@ -13,6 +13,7 @@ Bugfix 🐛:
- After jump to unread, newer messages are never loaded (#1008) - After jump to unread, newer messages are never loaded (#1008)
- Fix issues with FontScale switch (#69, #645) - Fix issues with FontScale switch (#69, #645)
- "Seen by" uses 12h time (#1378) - "Seen by" uses 12h time (#1378)
- Enable markdown (if active) when sending emote (#734)
Translations 🗣: Translations 🗣:
- -

View File

@ -117,8 +117,10 @@ class RoomDetailViewModel @AssistedInject constructor(
// Slot to keep a pending action during permission request // Slot to keep a pending action during permission request
var pendingAction: RoomDetailAction? = null var pendingAction: RoomDetailAction? = null
// Slot to keep a pending uri during permission request // Slot to keep a pending uri during permission request
var pendingUri: Uri? = null var pendingUri: Uri? = null
// Slot to store if we want to prevent preview of attachment // Slot to store if we want to prevent preview of attachment
var preventAttachmentPreview = false var preventAttachmentPreview = false
@ -390,7 +392,7 @@ class RoomDetailViewModel @AssistedInject constructor(
_viewEvents.post(RoomDetailViewEvents.SlashCommandNotImplemented) _viewEvents.post(RoomDetailViewEvents.SlashCommandNotImplemented)
} }
is ParsedCommand.SendEmote -> { is ParsedCommand.SendEmote -> {
room.sendTextMessage(slashCommandResult.message, msgType = MessageType.MSGTYPE_EMOTE) room.sendTextMessage(slashCommandResult.message, msgType = MessageType.MSGTYPE_EMOTE, autoMarkdown = action.autoMarkdown)
_viewEvents.post(RoomDetailViewEvents.SlashCommandHandled()) _viewEvents.post(RoomDetailViewEvents.SlashCommandHandled())
popDraft() popDraft()
} }