Fix lobby copy when another of your devices is solely already in the group call.

fork-5.53.8
Cody Henthorne 2021-08-23 10:39:36 -04:00 zatwierdzone przez Alex Hart
rodzic b7a067e954
commit 194975d068
3 zmienionych plików z 7 dodań i 1 usunięć

Wyświetl plik

@ -113,7 +113,9 @@ public final class CallParticipantsState {
return context.getString(R.string.WebRtcCallView__no_one_else_is_here);
case 1: {
if (callState == WebRtcViewModel.State.CALL_PRE_JOIN && groupCallState.isNotIdle()) {
return context.getString(R.string.WebRtcCallView__s_is_in_this_call, remoteParticipants.get(0).getShortRecipientDisplayName(context));
return context.getString(remoteParticipants.get(0).isSelf() ? R.string.WebRtcCallView__s_are_in_this_call
: R.string.WebRtcCallView__s_is_in_this_call,
remoteParticipants.get(0).getShortRecipientDisplayName(context));
} else {
if (focusedParticipant != CallParticipant.EMPTY && focusedParticipant.isScreenSharing()) {
return context.getString(R.string.WebRtcCallView__s_is_presenting, focusedParticipant.getShortRecipientDisplayName(context));

Wyświetl plik

@ -30,6 +30,9 @@ data class CallParticipant constructor(
val isPrimary: Boolean
get() = deviceOrdinal == DeviceOrdinal.PRIMARY
val isSelf: Boolean
get() = recipient.isSelf
fun getRecipientDisplayName(context: Context): String {
return if (recipient.isSelf && isPrimary) {
context.getString(R.string.CallParticipant__you)

Wyświetl plik

@ -1415,6 +1415,7 @@
<string name="WebRtcCallView__no_one_else_is_here">No one else is here</string>
<string name="WebRtcCallView__s_is_in_this_call">%1$s is in this call</string>
<string name="WebRtcCallView__s_are_in_this_call">%1$s are in this call</string>
<string name="WebRtcCallView__s_and_s_are_in_this_call">%1$s and %2$s are in this call</string>
<string name="WebRtcCallView__s_is_presenting">%1$s is presenting</string>