Adjusted sending of mms messages to show 'Uploading' rather than 'Sending' as per SES-1721

This commit is contained in:
Al Lansley 2024-08-05 14:37:47 +10:00
parent d3f8e928b6
commit 5fe123e7b5
2 changed files with 17 additions and 7 deletions

View File

@ -268,8 +268,7 @@ class VisibleMessageView : FrameLayout {
// Method to display or hide the status of a message. // Method to display or hide the status of a message.
// Note: Although most commonly used to display the delivery status of a message, we also use the // Note: Although most commonly used to display the delivery status of a message, we also use the
// message status area to display the disappearing messages state - so in this latter case we'll // message status area to display the disappearing messages state - so in this latter case we'll
// be displaying the "Sent" and the animating clock icon for outgoing messages or "Read" and the // be displaying either "Sent" or "Read" and the animating clock icon.
// animated clock icon for incoming messages.
private fun showStatusMessage(message: MessageRecord) { private fun showStatusMessage(message: MessageRecord) {
// We'll start by hiding everything and then only make visible what we need // We'll start by hiding everything and then only make visible what we need
binding.messageStatusTextView.isVisible = false binding.messageStatusTextView.isVisible = false
@ -392,11 +391,21 @@ class VisibleMessageView : FrameLayout {
R.string.messageStatusFailedToSync R.string.messageStatusFailedToSync
) )
message.isPending -> message.isPending ->
// Non-mms messages display 'Sending'..
if (!message.isMms) {
MessageStatusInfo( MessageStatusInfo(
R.drawable.ic_delivery_status_sending, R.drawable.ic_delivery_status_sending,
context.getColorFromAttr(R.attr.message_status_color), context.getColorFromAttr(R.attr.message_status_color),
R.string.sending R.string.sending
) )
} else {
// ..and Mms messages display 'Uploading'.
MessageStatusInfo(
R.drawable.ic_delivery_status_sending,
context.getColorFromAttr(R.attr.message_status_color),
R.string.messageStatusUploading
)
}
message.isSyncing || message.isResyncing -> message.isSyncing || message.isResyncing ->
MessageStatusInfo( MessageStatusInfo(
R.drawable.ic_delivery_status_sending, R.drawable.ic_delivery_status_sending,

View File

@ -512,6 +512,7 @@
<string name="messageStatusFailedToSend">Failed to send</string> <string name="messageStatusFailedToSend">Failed to send</string>
<string name="messageStatusFailedToSync">Failed to sync</string> <string name="messageStatusFailedToSync">Failed to sync</string>
<string name="messageStatusSyncing">Syncing</string> <string name="messageStatusSyncing">Syncing</string>
<string name="messageStatusUploading">Uploading</string>
<string name="messageUnread">Unread messages</string> <string name="messageUnread">Unread messages</string>
<string name="messageVoice">Voice Message</string> <string name="messageVoice">Voice Message</string>
<string name="messageVoiceErrorShort">Hold to record a voice message</string> <string name="messageVoiceErrorShort">Hold to record a voice message</string>