How can I know a JitsiMeetActivity is left?

852 views Asked by At

I am trying to implement this scenario: A user receives a Jitsi Conference Call request. After accepting the request, the room name is passed to the user and a new JitsiMeetActivity is launched. The code works until here. I am able to join in on a conversation. Now the thing I want to do is, after joining a conference call if the user wants to leave the call then another activity should start. If I can know when the user leaves the call I can do this.

If a method or some sort like JitsiMeetActivity.isActive() exists, it would be helpful.

The code:

if (room_name.length() > 0) {
            JitsiMeetConferenceOptions options
                    = new JitsiMeetConferenceOptions.Builder()
                    .setRoom(room_name)
                    .build();

            JitsiMeetActivity.launch(this, options);
        }
        
        //Now if the call ends
        Intent ac = new Intent(this, nextActivity.class);
        startActivity(ac);
1

There are 1 answers

0
codertryer On BEST ANSWER

I solved this by creating a new activity and implementing JitsiMeetActivityInterface, JitsiMeetViewListener from it. Thus, whenever I want to end a conference, I have access to onConferenceTerminated method.