예제 #1
0
 @Override
 public void onJoinedRoom(QBChatRoom pRoom) {
   chatRoom = pRoom;
   chatRoom.addMessageListener(app.getMsgManager());
   chatRoom.addParticipantListener(pParticipantListener);
   app.setJoinedRoom(chatRoom);
   pRoom.setmRoomReceivingListener(null);
 }
예제 #2
0
 @Override
 public void release() {
   app.getMsgManager().downloadPersistentRoom();
   if (chatRoom != null) {
     chatRoom.removeMessageListener(app.getMsgManager());
     chatRoom.leave();
     app.setJoinedRoom(null);
   }
 }
예제 #3
0
  public RoomChat(UIChat pChat) {
    mChat = pChat;
    app = ChatApplication.getInstance();

    QBChat.getInstance().startWatchRoom(pInvitationListener);

    String chatRoomName = mChat.getIntent().getStringExtra(GlobalConsts.ROOM_NAME);

    join(chatRoomName);

    app.getMsgManager().setmNewRoomMessageIncome(this);

    mChat.setBarTitle(chatRoomName);

    mChat.setTopBarParams(TopBar.ROOM_ACTIVITY, View.INVISIBLE, false);
  }
예제 #4
0
 public void join(String roomName) {
   QBChat.getInstance().joinRoom(roomName, app.getQbUser(), mRoomListener);
 }