英文:
How can I know a JitsiMeetActivity is left?
问题
我正在尝试实现这个场景:用户收到一个Jitsi会议呼叫请求。在接受请求后,房间名称传递给用户,然后启动新的JitsiMeetActivity
。代码在这一部分起作用。我能够加入对话。现在我想做的是,加入会议通话后,如果用户想要离开通话,那么应该启动另一个活动。如果我能知道用户何时离开通话,我就可以做到这一点。
如果存在像JitsiMeetActivity.isActive()
这样的方法或类似的东西,那会很有帮助。
代码:
if (room_name.length() > 0) {
JitsiMeetConferenceOptions options
= new JitsiMeetConferenceOptions.Builder()
.setRoom(room_name)
.build();
JitsiMeetActivity.launch(this, options);
}
// 现在如果通话结束
Intent ac = new Intent(this, nextActivity.class);
startActivity(ac);
英文:
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
得分: 0
我通过创建一个新的活动并从中实现JitsiMeetActivityInterface
、JitsiMeetViewListener
来解决了这个问题。因此,每当我想结束一个会议时,我都可以访问onConferenceTerminated
方法。
英文:
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.
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论