Revert "Don't show members button if there are no remote people."

This reverts commit d4748efd42.
This commit is contained in:
Alex Hart 2020-12-01 12:19:03 -04:00
parent 55c9124c54
commit b59a5c8609
3 changed files with 10 additions and 11 deletions

View file

@ -222,13 +222,6 @@ public class WebRtcCallView extends FrameLayout {
int statusBarHeight = ViewUtil.getStatusBarHeight(this);
statusBarGuideline.setGuidelineBegin(statusBarHeight);
toolbar.inflateMenu(R.menu.group_call);
View showParticipants = toolbar.getMenu().findItem(R.id.menu_group_call_participants_list).getActionView();
showParticipants.setOnClickListener(unused -> showParticipantsList());
participantCount = showParticipants.findViewById(R.id.show_participants_menu_counter);
}
@Override
@ -369,6 +362,14 @@ public class WebRtcCallView extends FrameLayout {
if (recipient.isGroup()) {
recipientName.setText(getContext().getString(R.string.WebRtcCallView__s_group_call, recipient.getDisplayName(getContext())));
if (toolbar.getMenu().findItem(R.id.menu_group_call_participants_list) == null) {
toolbar.inflateMenu(R.menu.group_call);
View showParticipants = toolbar.getMenu().findItem(R.id.menu_group_call_participants_list).getActionView();
showParticipants.setOnClickListener(unused -> showParticipantsList());
participantCount = showParticipants.findViewById(R.id.show_participants_menu_counter);
}
} else {
recipientName.setText(recipient.getDisplayName(getContext()));
}

View file

@ -57,7 +57,7 @@ public final class WebRtcControls {
}
boolean displayGroupMembersButton() {
return groupCallState.isAtLeast(GroupCallState.CONNECTING) && hasAtLeastOneRemote;
return groupCallState.isAtLeast(GroupCallState.CONNECTING);
}
boolean displayEndCall() {

View file

@ -6,10 +6,8 @@
<item
android:id="@+id/menu_group_call_participants_list"
android:title="@string/WebRtcCallView__view_participants_list"
android:visible="false"
app:actionLayout="@layout/show_participants_menu_view"
app:showAsAction="always"
tools:ignore="AlwaysShowAction"
tools:visible="true" />
tools:ignore="AlwaysShowAction" />
</menu>