Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added the updated delivery status UI #1079

Merged
merged 3 commits into from
Jan 24, 2023

Conversation

mpretty-cyro
Copy link
Collaborator

No description provided.

@mpretty-cyro mpretty-cyro requested a review from hjubb January 16, 2023 04:02
@mpretty-cyro mpretty-cyro self-assigned this Jan 16, 2023
@mpretty-cyro mpretty-cyro changed the base branch from master to dev January 17, 2023 05:12
Copy link

@hjubb hjubb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It might be a good idea to add in this dynamic message status logic in MessageDetailActivity.kt at line 74, we get an error message which is just hard-coded, at least we should replace it with the new string and possibly use logos or something else if we want to add more to that page

val (iconID, iconColor) = getMessageStatusImage(message)
val (iconID, iconColor, textId) = getMessageStatusImage(message)
if (textId != null) {
binding.messageStatusTextView.setText(textId)
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we might have to set the text to null in the null case as well so that re-binds that should have a null message status don't keep the old value (as they won't be set this way)

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it might not be an issue if we are controlling the visibility so that this case should never happen though I guess

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I updated the visibility logic so if the textId or iconID are null then the UI elements will be hidden to prevent the chance that stale data will be shown - let me know if you also want be to null-out the data

@mpretty-cyro
Copy link
Collaborator Author

we get an error message which is just hard-coded, at least we should replace it with the new string and possibly use logos or something else if we want to add more to that page

@hjubb Where/what is this error message? (can you get a screenshot of it easily?)

@hjubb
Copy link

hjubb commented Jan 23, 2023

we get an error message which is just hard-coded, at least we should replace it with the new string and possibly use logos or something else if we want to add more to that page

@hjubb Where/what is this error message? (can you get a screenshot of it easily?)

@mpretty-cyro I think we just fallback to a generic error if we don't have a DB error message, which is usually whatever the exception message usually is so might not be that important in the end, unless we just wanted the generic message not use the hardcoded string value but get context.getString(R.string.delivery_status_failed) in place of it or something (I probably should've made the original comment on the strings.xml changes instead of a generic comment)
image

@mpretty-cyro
Copy link
Collaborator Author

@mpretty-cyro I think we just fallback to a generic error if we don't have a DB error message, which is usually whatever the exception message usually is so might not be that important in the end, unless we just wanted the generic message not use the hardcoded string value but get context.getString(R.string.delivery_status_failed) in place of it or something (I probably should've made the original comment on the strings.xml changes instead of a generic comment)

Ah, I didn't realise this screen even existed 😅

So we actually chatted about failed message errors a few days ago (in the context of iOS) and the decision was to actually show the network/server error if we have one rather than something generic (since it could help for support purposes) so I'm not sure we actually do want to make this generic

We are also likely going to need to update this UI as part of the message info improvements so we can probably get clarity (and make changes) as part of that work - let me know if you stuff want it done now though

@hjubb
Copy link

hjubb commented Jan 24, 2023

it's probably fine for now @mpretty-cyro we can improve this screen quite a bit in the future I'm sure

…updates

# Conflicts:
#	app/src/main/java/org/thoughtcrime/securesms/conversation/v2/messages/VisibleMessageView.kt
#	app/src/main/res/values/strings.xml
@mpretty-cyro mpretty-cyro requested a review from hjubb January 24, 2023 03:12
@mpretty-cyro mpretty-cyro merged commit beabc1c into oxen-io:dev Jan 24, 2023
@mpretty-cyro mpretty-cyro deleted the feature/read_status_updates branch January 24, 2023 03:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants