mirror of
https://github.com/nextcloud/talk-android.git
synced 2024-11-27 17:08:34 +03:00
Switch if to switch :)
This commit is contained in:
parent
5a3f199f14
commit
f6b1dca677
1 changed files with 14 additions and 10 deletions
|
@ -1190,16 +1190,20 @@ public class CallController extends BaseController {
|
||||||
|
|
||||||
@Subscribe(threadMode = ThreadMode.BACKGROUND)
|
@Subscribe(threadMode = ThreadMode.BACKGROUND)
|
||||||
public void onMessageEvent(WebSocketCommunicationEvent webSocketCommunicationEvent) {
|
public void onMessageEvent(WebSocketCommunicationEvent webSocketCommunicationEvent) {
|
||||||
if (webSocketCommunicationEvent.getType().equals("hello")) {
|
switch (webSocketCommunicationEvent.getType()) {
|
||||||
callSession = webSocketClient.getSessionId();
|
case "hello":
|
||||||
webSocketClient.joinRoomWithRoomToken(roomToken);
|
callSession = webSocketClient.getSessionId();
|
||||||
alwaysGetPeerConnectionWrapperForSessionId(callSession, true);
|
webSocketClient.joinRoomWithRoomToken(roomToken);
|
||||||
} else if ("participantsUpdate".equals(webSocketCommunicationEvent.getType())) {
|
alwaysGetPeerConnectionWrapperForSessionId(callSession, true);
|
||||||
if (webSocketCommunicationEvent.getHashMap().get("roomId").equals(roomToken)) {
|
break;
|
||||||
processUsersInRoom((List<HashMap<String, Object>>) webSocketClient.getJobWithId(Integer.valueOf(webSocketCommunicationEvent.getHashMap().get("jobId"))));
|
case "participantsUpdate":
|
||||||
}
|
if (webSocketCommunicationEvent.getHashMap().get("roomId").equals(roomToken)) {
|
||||||
} else if ("signalingMessage".equals(webSocketCommunicationEvent.getType())) {
|
processUsersInRoom((List<HashMap<String, Object>>) webSocketClient.getJobWithId(Integer.valueOf(webSocketCommunicationEvent.getHashMap().get("jobId"))));
|
||||||
processMessage((NCSignalingMessage) webSocketClient.getJobWithId(Integer.valueOf(webSocketCommunicationEvent.getHashMap().get("jobId"))));
|
}
|
||||||
|
break;
|
||||||
|
case "signalingMessage":
|
||||||
|
processMessage((NCSignalingMessage) webSocketClient.getJobWithId(Integer.valueOf(webSocketCommunicationEvent.getHashMap().get("jobId"))));
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue