Fix the "Tap for X fallback" labels.

This commit is contained in:
Moxie Marlinspike 2014-06-13 17:48:56 -07:00
parent 983bf672cf
commit 0d35e2bfa9
2 changed files with 8 additions and 3 deletions

View File

@ -56,7 +56,8 @@
<string name="ConversationItem_group_action_left">%1$s has left the group.</string>
<string name="ConversationItem_group_action_joined">%1$s have joined the group.</string>
<string name="ConversationItem_group_action_modify">%1$s has updated the group.</string>
<string name="ConversationItem_click_to_approve">Tap for SMS fallback</string>
<string name="ConversationItem_click_to_approve_sms">Tap for SMS fallback</string>
<string name="ConversationItem_click_to_approve_mms">Tap for MMS fallback</string>
<string name="ConversationItem_click_to_approve_unencrypted">Tap for insecure fallback</string>
<string name="ConversationItem_click_to_approve_sms_dialog_title">Fallback to SMS?</string>
<string name="ConversationItem_click_to_approve_mms_dialog_title">Fallback to MMS?</string>

View File

@ -261,8 +261,12 @@ public class ConversationItem extends LinearLayout {
dateText.setText(R.string.ConversationItem_error_sending_message);
} else if (messageRecord.isPendingSmsFallback() && indicatorText != null) {
dateText.setText("");
if (messageRecord.isPendingSecureSmsFallback()) indicatorText.setText(R.string.ConversationItem_click_to_approve);
else indicatorText.setText(R.string.ConversationItem_click_to_approve_unencrypted);
if (messageRecord.isPendingSecureSmsFallback()) {
if (messageRecord.isMms()) indicatorText.setText(R.string.ConversationItem_click_to_approve_mms);
else indicatorText.setText(R.string.ConversationItem_click_to_approve_sms);
} else {
indicatorText.setText(R.string.ConversationItem_click_to_approve_unencrypted);
}
} else if (messageRecord.isPending()) {
dateText.setText(" ··· ");
} else {