Move from ACI to a generic ServiceId.

This commit is contained in:
Greyson Parrelli
2022-02-17 15:55:54 -05:00
parent 9f1deda220
commit 7ca2420287
110 changed files with 841 additions and 824 deletions

View File

@@ -83,7 +83,7 @@ public class GroupActionProcessor extends DeviceAwareActionProcessor {
seen.add(Recipient.self());
for (GroupCall.RemoteDeviceState device : remoteDeviceStates) {
Recipient recipient = Recipient.externalPush(context, ACI.from(device.getUserId()), null, false);
Recipient recipient = Recipient.externalPush(ACI.from(device.getUserId()), null, false);
CallParticipantId callParticipantId = new CallParticipantId(device.getDemuxId(), recipient.getId());
CallParticipant callParticipant = participants.get(callParticipantId);

View File

@@ -123,8 +123,8 @@ public class GroupConnectedActionProcessor extends GroupActionProcessor {
webRtcInteractor.sendGroupCallMessage(currentState.getCallInfoState().getCallRecipient(), eraId);
List<UUID> members = new ArrayList<>(peekInfo.getJoinedMembers());
if (!members.contains(Recipient.self().requireAci().uuid())) {
members.add(Recipient.self().requireAci().uuid());
if (!members.contains(Recipient.self().requireServiceId().uuid())) {
members.add(Recipient.self().requireServiceId().uuid());
}
webRtcInteractor.updateGroupCallUpdateMessage(currentState.getCallInfoState().getCallRecipient().getId(), eraId, members, WebRtcUtil.isCallFull(peekInfo));
@@ -149,7 +149,7 @@ public class GroupConnectedActionProcessor extends GroupActionProcessor {
String eraId = WebRtcUtil.getGroupCallEraId(groupCall);
webRtcInteractor.sendGroupCallMessage(currentState.getCallInfoState().getCallRecipient(), eraId);
List<UUID> members = Stream.of(currentState.getCallInfoState().getRemoteCallParticipants()).map(p -> p.getRecipient().requireAci().uuid()).toList();
List<UUID> members = Stream.of(currentState.getCallInfoState().getRemoteCallParticipants()).map(p -> p.getRecipient().requireServiceId().uuid()).toList();
webRtcInteractor.updateGroupCallUpdateMessage(currentState.getCallInfoState().getCallRecipient().getId(), eraId, members, false);
currentState = currentState.builder()

View File

@@ -114,7 +114,7 @@ public class GroupPreJoinActionProcessor extends GroupActionProcessor {
}
List<Recipient> callParticipants = Stream.of(peekInfo.getJoinedMembers())
.map(uuid -> Recipient.externalPush(context, ACI.from(uuid), null, false))
.map(uuid -> Recipient.externalPush(ACI.from(uuid), null, false))
.toList();
WebRtcServiceStateBuilder.CallInfoStateBuilder builder = currentState.builder()

View File

@@ -138,7 +138,7 @@ public final class IncomingGroupCallActionProcessor extends DeviceAwareActionPro
.changeCallSetupState(RemotePeer.GROUP_CALL_ID)
.isRemoteVideoOffer(true)
.ringId(ringId)
.ringerRecipient(Recipient.externalPush(context, ACI.from(uuid), null, false))
.ringerRecipient(Recipient.externalPush(ACI.from(uuid), null, false))
.commit()
.changeCallInfoState()
.activePeer(new RemotePeer(currentState.getCallInfoState().getCallRecipient().getId(), RemotePeer.GROUP_CALL_ID))

View File

@@ -154,7 +154,7 @@ public final class SignalCallManager implements CallManager.Observer, GroupCall.
serviceExecutor.execute(() -> {
if (needsToSetSelfUuid) {
try {
callManager.setSelfUuid(Recipient.self().requireAci().uuid());
callManager.setSelfUuid(Recipient.self().requireServiceId().uuid());
needsToSetSelfUuid = false;
} catch (CallException e) {
Log.w(TAG, "Unable to set self UUID on CallManager", e);