From 47919382e9f77a0558455c0fa814ea40ce652a95 Mon Sep 17 00:00:00 2001 From: Alan Evans Date: Wed, 10 Jun 2020 12:55:57 -0300 Subject: [PATCH] Show 'Add to another group' when launched from a group context. --- .../ui/bottomsheet/RecipientBottomSheetDialogFragment.java | 1 + app/src/main/res/layout/recipient_bottom_sheet.xml | 2 +- app/src/main/res/values/strings.xml | 1 + 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/org/thoughtcrime/securesms/recipients/ui/bottomsheet/RecipientBottomSheetDialogFragment.java b/app/src/main/java/org/thoughtcrime/securesms/recipients/ui/bottomsheet/RecipientBottomSheetDialogFragment.java index 5699d8f8f..abae9a95f 100644 --- a/app/src/main/java/org/thoughtcrime/securesms/recipients/ui/bottomsheet/RecipientBottomSheetDialogFragment.java +++ b/app/src/main/java/org/thoughtcrime/securesms/recipients/ui/bottomsheet/RecipientBottomSheetDialogFragment.java @@ -149,6 +149,7 @@ public final class RecipientBottomSheetDialogFragment extends BottomSheetDialogF }); } + addToGroupButton.setText(groupId == null ? R.string.RecipientBottomSheet_add_to_a_group : R.string.RecipientBottomSheet_add_to_another_group); addToGroupButton.setVisibility(recipient.isRegistered() && !recipient.isGroup() ? View.VISIBLE : View.GONE); }); diff --git a/app/src/main/res/layout/recipient_bottom_sheet.xml b/app/src/main/res/layout/recipient_bottom_sheet.xml index 6d017a253..4aff55258 100644 --- a/app/src/main/res/layout/recipient_bottom_sheet.xml +++ b/app/src/main/res/layout/recipient_bottom_sheet.xml @@ -126,9 +126,9 @@ android:layout_height="56dp" android:paddingStart="20dp" android:paddingEnd="20dp" - android:text="@string/RecipientBottomSheet_add_to_a_group" android:visibility="gone" app:drawableStartCompat="?attr/recipient_make_admin_icon" + tools:text="@string/RecipientBottomSheet_add_to_a_group" tools:visibility="visible" />