mirror of
https://github.com/nextcloud/talk-android
synced 2025-03-11 18:10:44 +00:00
Remove no longer needed code after removing EventBus message
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
This commit is contained in:
parent
5e224c5a24
commit
c4c64df5a6
@ -173,11 +173,6 @@ import static com.nextcloud.talk.utils.bundle.BundleKeys.KEY_PARTICIPANT_PERMISS
|
||||
import static com.nextcloud.talk.utils.bundle.BundleKeys.KEY_ROOM_ID;
|
||||
import static com.nextcloud.talk.utils.bundle.BundleKeys.KEY_ROOM_TOKEN;
|
||||
import static com.nextcloud.talk.utils.bundle.BundleKeys.KEY_USER_ENTITY;
|
||||
import static com.nextcloud.talk.webrtc.Globals.JOB_ID;
|
||||
import static com.nextcloud.talk.webrtc.Globals.PARTICIPANTS_UPDATE;
|
||||
import static com.nextcloud.talk.webrtc.Globals.ROOM_TOKEN;
|
||||
import static com.nextcloud.talk.webrtc.Globals.UPDATE_ALL;
|
||||
import static com.nextcloud.talk.webrtc.Globals.UPDATE_IN_CALL;
|
||||
|
||||
@AutoInjector(NextcloudTalkApplication.class)
|
||||
public class CallActivity extends CallBaseActivity {
|
||||
|
@ -1,31 +0,0 @@
|
||||
/*
|
||||
* Nextcloud Talk application
|
||||
*
|
||||
* @author Mario Danic
|
||||
* Copyright (C) 2017-2018 Mario Danic <mario@lovelyhq.com>
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
package com.nextcloud.talk.utils
|
||||
|
||||
import java.util.concurrent.ConcurrentHashMap
|
||||
|
||||
class MagicMap : ConcurrentHashMap<Int, Any>() {
|
||||
fun add(element: Any): Int {
|
||||
val key = System.identityHashCode(element)
|
||||
super.put(key, element)
|
||||
return key
|
||||
}
|
||||
}
|
@ -2,17 +2,6 @@ package com.nextcloud.talk.webrtc;
|
||||
|
||||
public class Globals {
|
||||
public static final String ROOM_TOKEN = "roomToken";
|
||||
public static final String JOB_ID = "jobId";
|
||||
|
||||
public static final String PARTICIPANTS_UPDATE = "participantsUpdate";
|
||||
|
||||
public static final String TARGET_PARTICIPANTS = "participants";
|
||||
|
||||
public static final String EVENT_TYPE = "type";
|
||||
public static final String EVENT_TYPE_UPDATE = "update";
|
||||
|
||||
public static final String UPDATE_ALL = "all";
|
||||
public static final String UPDATE_IN_CALL = "incall";
|
||||
public static final String UPDATE_ROOM_ID = "roomid";
|
||||
public static final String UPDATE_USERS = "users";
|
||||
}
|
||||
|
@ -41,7 +41,6 @@ import com.nextcloud.talk.models.json.websocket.EventOverallWebSocketMessage;
|
||||
import com.nextcloud.talk.models.json.websocket.HelloResponseOverallWebSocketMessage;
|
||||
import com.nextcloud.talk.models.json.websocket.JoinedRoomOverallWebSocketMessage;
|
||||
import com.nextcloud.talk.signaling.SignalingMessageReceiver;
|
||||
import com.nextcloud.talk.utils.MagicMap;
|
||||
import com.nextcloud.talk.utils.bundle.BundleKeys;
|
||||
|
||||
import org.greenrobot.eventbus.EventBus;
|
||||
@ -66,16 +65,8 @@ import okio.ByteString;
|
||||
|
||||
import static com.nextcloud.talk.models.json.participants.Participant.ActorType.GUESTS;
|
||||
import static com.nextcloud.talk.models.json.participants.Participant.ActorType.USERS;
|
||||
import static com.nextcloud.talk.webrtc.Globals.EVENT_TYPE;
|
||||
import static com.nextcloud.talk.webrtc.Globals.EVENT_TYPE_UPDATE;
|
||||
import static com.nextcloud.talk.webrtc.Globals.JOB_ID;
|
||||
import static com.nextcloud.talk.webrtc.Globals.PARTICIPANTS_UPDATE;
|
||||
import static com.nextcloud.talk.webrtc.Globals.ROOM_TOKEN;
|
||||
import static com.nextcloud.talk.webrtc.Globals.TARGET_PARTICIPANTS;
|
||||
import static com.nextcloud.talk.webrtc.Globals.UPDATE_ALL;
|
||||
import static com.nextcloud.talk.webrtc.Globals.UPDATE_IN_CALL;
|
||||
import static com.nextcloud.talk.webrtc.Globals.UPDATE_ROOM_ID;
|
||||
import static com.nextcloud.talk.webrtc.Globals.UPDATE_USERS;
|
||||
|
||||
@AutoInjector(NextcloudTalkApplication.class)
|
||||
public class MagicWebSocketInstance extends WebSocketListener {
|
||||
@ -99,7 +90,6 @@ public class MagicWebSocketInstance extends WebSocketListener {
|
||||
private boolean connected;
|
||||
private WebSocketConnectionHelper webSocketConnectionHelper;
|
||||
private WebSocket internalWebSocket;
|
||||
private MagicMap magicMap;
|
||||
private String connectionUrl;
|
||||
|
||||
private String currentRoomToken;
|
||||
@ -120,7 +110,6 @@ public class MagicWebSocketInstance extends WebSocketListener {
|
||||
this.webSocketTicket = webSocketTicket;
|
||||
this.webSocketConnectionHelper = new WebSocketConnectionHelper();
|
||||
this.usersHashMap = new HashMap<>();
|
||||
magicMap = new MagicMap();
|
||||
|
||||
connected = false;
|
||||
eventBus.register(this);
|
||||
@ -368,12 +357,6 @@ public class MagicWebSocketInstance extends WebSocketListener {
|
||||
}
|
||||
}
|
||||
|
||||
public Object getJobWithId(Integer id) {
|
||||
Object copyJob = magicMap.get(id);
|
||||
magicMap.remove(id);
|
||||
return copyJob;
|
||||
}
|
||||
|
||||
public void requestOfferForSessionIdWithType(String sessionIdParam, String roomType) {
|
||||
try {
|
||||
String message = LoganSquare.serialize(webSocketConnectionHelper.getAssembledRequestOfferModel(sessionIdParam, roomType));
|
||||
|
Loading…
Reference in New Issue
Block a user