mirror of
https://github.com/SchildiChat/SchildiChat-android.git
synced 2025-02-16 20:10:04 +03:00
cleaning
This commit is contained in:
parent
c4ea2507f8
commit
3ac54c51f6
3 changed files with 8 additions and 5 deletions
|
@ -41,8 +41,8 @@ enum class Command(val command: String, val parameters: String, @StringRes val d
|
|||
RAINBOW_EMOTE("/rainbowme", "<message>", R.string.command_description_rainbow_emote),
|
||||
CLEAR_SCALAR_TOKEN("/clear_scalar_token", "", R.string.command_description_clear_scalar_token),
|
||||
SPOILER("/spoiler", "<message>", R.string.command_description_spoiler),
|
||||
POLL("/poll", "Question | Option 1 | Option 2 ...", R.string.command_description_poll),
|
||||
SHRUG("/shrug", "<message>", R.string.command_description_shrug),
|
||||
SPOILER("/spoiler", "<message>", R.string.command_description_spoiler),
|
||||
// TODO temporary command
|
||||
VERIFY_USER("/verify", "<user-id>", R.string.command_description_verify);
|
||||
|
||||
|
|
|
@ -80,12 +80,12 @@ object CommandParser {
|
|||
|
||||
ParsedCommand.SendEmote(message)
|
||||
}
|
||||
Command.RAINBOW.command -> {
|
||||
Command.RAINBOW.command -> {
|
||||
val message = textMessage.subSequence(Command.RAINBOW.command.length, textMessage.length).trim()
|
||||
|
||||
ParsedCommand.SendRainbow(message)
|
||||
}
|
||||
Command.RAINBOW_EMOTE.command -> {
|
||||
Command.RAINBOW_EMOTE.command -> {
|
||||
val message = textMessage.subSequence(Command.RAINBOW_EMOTE.command.length, textMessage.length).trim()
|
||||
|
||||
ParsedCommand.SendRainbowEmote(message)
|
||||
|
@ -258,7 +258,6 @@ object CommandParser {
|
|||
|
||||
ParsedCommand.SendShrug(message)
|
||||
}
|
||||
|
||||
Command.VERIFY_USER.command -> {
|
||||
val message = textMessage.substring(Command.VERIFY_USER.command.length).trim()
|
||||
|
||||
|
|
|
@ -145,7 +145,11 @@ class MessageItemFactory @Inject constructor(
|
|||
}
|
||||
}
|
||||
|
||||
private fun buildPollMessageItem(messageContent: MessageOptionsContent, informationData: MessageInformationData, highlight: Boolean, callback: TimelineEventController.Callback?, attributes: AbsMessageItem.Attributes): VectorEpoxyModel<*>? {
|
||||
private fun buildPollMessageItem(messageContent: MessageOptionsContent,
|
||||
informationData: MessageInformationData,
|
||||
highlight: Boolean,
|
||||
callback: TimelineEventController.Callback?,
|
||||
attributes: AbsMessageItem.Attributes): VectorEpoxyModel<*>? {
|
||||
return MessagePollItem_()
|
||||
.attributes(attributes)
|
||||
.callback(callback)
|
||||
|
|
Loading…
Add table
Reference in a new issue