Participant Events
Participant joined
Trigger an event when any participant joins the meeting.
class ParticipantsEventListener extends DyteParticipantEventsListener {
...
void onParticipantJoin(DyteJoinedMeetingParticipant participant) {
// your code here to handle new participant
}
...
}
Participant updated
Trigger an event when any participant update in meeting. For example, when a participant changes their name.
...
void onParticipantUpdated(DyteJoinedMeetingParticipant participant) {
// your code here to handle new participant
}
...
Participant left
Trigger an event when any participant leaves the meeting.
...
void onParticipantLeave(DyteJoinedMeetingParticipant participant) {
// your code here to handle participant left from meeting
}
...
Video update
Trigger an event when any participant starts or stops the video.
...
void onVideoUpdate({
required bool videoEnabled,
required DyteJoinedMeetingParticipant participant,
}) {
// your code here to handle participant video toggle update
}
...
Audio update
Triggers an event when a participant starts or stops the audio.
...
void onAudioUpdate({
required bool audioEnabled,
required DyteJoinedMeetingParticipant participant,
}) {
// your code here to handle participant audio toggle update
}
...
Screen share update
Triggers an event when a participant starts or stops screen share.
...
void onScreenShareStarted(DyteJoinedMeetingParticipant participant) {
/// handle screen share started of `DyteJoinedMeetingParticipant` participant
}
void onScreenShareEnded(DyteJoinedMeetingParticipant participant) {
/// handle screen share ended of `DyteJoinedMeetingParticipant` participant
}
...
Screen share participants list
Obtain the list of the screenshare participants, using the participants.screenshares
function which returns a DyteRoomParticipants
object that maintains a record of participants who have joined, pinned, and screenshared. This object updates with each onUpdate
call.
Screen share view
To get the screenshare widget, create an object of the ScreenshareView
class.
// To show screenshare of a participant
final screenshareView = ScreenShareView(meetingParticipant);
Active Participants changed
This event is triggered when the active participant changes, for example, when the user moves to the next page of participants. It provides the list of participants on the current page.
...
void onActiveParticipantsChanged(List<DyteJoinedMeetingParticipant> active) {
/// handle active participants changed
}
...
Other events:
Event | Description |
---|---|
onActiveSpeakerChanged | Triggered when active speaker is change. Updated active speaker is sent as payload. |
onNoActiveSpeaker | Triggered when there is no active participant. |
onParticipantPinned | Triggered when a participant is pinned. Pinned participant details is sent as payload. |
onParticipantUnpinned | Triggered when a participant is unpinned. Unpinned participant details is sent as payload. |