mirror of
https://github.com/oxen-io/session-android.git
synced 2025-06-10 04:38:33 +00:00
Hide group link when not enabled.
This commit is contained in:
parent
ee3d7a9a35
commit
a635f27c68
@ -73,15 +73,16 @@ public final class ShareableGroupLinkDialogFragment extends DialogFragment {
|
||||
}
|
||||
|
||||
private void initializeViews(@NonNull View view) {
|
||||
SwitchCompat shareableGroupLinkSwitch = view.findViewById(R.id.shareable_group_link_enable_switch);
|
||||
TextView shareableGroupLinkDisplay = view.findViewById(R.id.shareable_group_link_display);
|
||||
SwitchCompat approveNewMembersSwitch = view.findViewById(R.id.shareable_group_link_approve_new_members_switch);
|
||||
View shareableGroupLinkRow = view.findViewById(R.id.shareable_group_link_row);
|
||||
View shareRow = view.findViewById(R.id.shareable_group_link_share_row);
|
||||
View resetLinkRow = view.findViewById(R.id.shareable_group_link_reset_link_row);
|
||||
View approveNewMembersRow = view.findViewById(R.id.shareable_group_link_approve_new_members_row);
|
||||
View membersSectionHeader = view.findViewById(R.id.shareable_group_link_member_requests_section_header);
|
||||
View descriptionRow = view.findViewById(R.id.shareable_group_link_display_row2);
|
||||
SwitchCompat shareableGroupLinkSwitch = view.findViewById(R.id.shareable_group_link_enable_switch);
|
||||
TextView shareableGroupLinkDisplay = view.findViewById(R.id.shareable_group_link_display);
|
||||
View shareableGroupLinkDisplayRow = view.findViewById(R.id.shareable_group_link_display_row);
|
||||
SwitchCompat approveNewMembersSwitch = view.findViewById(R.id.shareable_group_link_approve_new_members_switch);
|
||||
View shareableGroupLinkRow = view.findViewById(R.id.shareable_group_link_row);
|
||||
View shareRow = view.findViewById(R.id.shareable_group_link_share_row);
|
||||
View resetLinkRow = view.findViewById(R.id.shareable_group_link_reset_link_row);
|
||||
View approveNewMembersRow = view.findViewById(R.id.shareable_group_link_approve_new_members_row);
|
||||
View membersSectionHeader = view.findViewById(R.id.shareable_group_link_member_requests_section_header);
|
||||
View descriptionRow = view.findViewById(R.id.shareable_group_link_display_row2);
|
||||
|
||||
Toolbar toolbar = view.findViewById(R.id.shareable_group_link_toolbar);
|
||||
|
||||
@ -92,7 +93,7 @@ public final class ShareableGroupLinkDialogFragment extends DialogFragment {
|
||||
approveNewMembersSwitch.setChecked(groupLink.isRequiresApproval());
|
||||
shareableGroupLinkDisplay.setText(formatForFullWidthWrapping(groupLink.getUrl()));
|
||||
|
||||
ViewUtil.setEnabledRecursive(shareableGroupLinkDisplay, groupLink.isEnabled());
|
||||
shareableGroupLinkDisplayRow.setVisibility(groupLink.isEnabled() ? View.VISIBLE : View.GONE);
|
||||
ViewUtil.setEnabledRecursive(shareRow, groupLink.isEnabled());
|
||||
ViewUtil.setEnabledRecursive(resetLinkRow, groupLink.isEnabled());
|
||||
ViewUtil.setEnabledRecursive(membersSectionHeader, groupLink.isEnabled());
|
||||
|
@ -85,7 +85,6 @@
|
||||
android:layout_height="match_parent"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:layout_weight="1"
|
||||
android:enabled="false"
|
||||
android:gravity="center_vertical|start"
|
||||
android:text="@string/ShareableGroupLinkDialogFragment__share"
|
||||
android:textAlignment="viewStart"
|
||||
|
Loading…
x
Reference in New Issue
Block a user