logo
On this page

Event


ZegoTurnOnYourMicrophoneRequestListener

onTurnOnYourMicrophoneRequest

This callback will be triggered when other user try to open your microphone.

  • function prototype:
Untitled
void onTurnOnYourMicrophoneRequest(ZegoUIKitUser fromUser)
1
Copied!
  • example:
Untitled
ZegoUIKitPrebuiltLiveAudioRoomFragment fragment ;
// ...
fragment.setTurnOnYourMicrophoneRequestListener(new ZegoTurnOnYourMicrophoneRequestListener() {
    @Override
    public void onTurnOnYourMicrophoneRequest(ZegoUIKitUser fromUser) {
        
    }
});
1
Copied!

ZegoUserCountOrPropertyChangedListener

onUserCountOrPropertyChanged

This callback will be triggered when room user count changed or property changed.

  • function prototype:
Untitled
void onUserCountOrPropertyChanged(List<ZegoUIKitUser> userList)
1
Copied!
  • example:
Untitled
ZegoUIKitPrebuiltLiveAudioRoomFragment fragment ;
// ...
fragment.setUserCountOrPropertyChangedListener(new ZegoUserCountOrPropertyChangedListener() {
    @Override
    public void onUserCountOrPropertyChanged(List<ZegoUIKitUser> userList) {
        
    }
});
1
Copied!

ZegoSeatTakingRequestAudienceListener

onSeatTakingRequestRejected

This callback will be triggered to audience when room user request take seat and is rejected by room host.

  • function prototype:
Untitled
void onSeatTakingRequestRejected()
1
Copied!
  • example:
Untitled
ZegoUIKitPrebuiltLiveAudioRoomFragment fragment ;
// ...
fragment.setSeatTakingRequestAudienceListener(new ZegoSeatTakingRequestAudienceListener() {
    @Override
    public void onSeatTakingRequestRejected() {
        
    }
});
1
Copied!

onHostSeatTakingInviteSent

This callback will be triggered to audience when room host invite users to be a speaker.

  • function prototype:
Untitled
void onHostSeatTakingInviteSent()
1
Copied!
  • example:
Untitled
ZegoUIKitPrebuiltLiveAudioRoomFragment fragment ;
// ...
fragment.setSeatTakingRequestAudienceListener(new ZegoSeatTakingRequestAudienceListener() {
    @Override
    public void onHostSeatTakingInviteSent() {
        
    }
});
1
Copied!

ZegoSeatTakingRequestHostListener

onSeatTakingRequested

This callback will be triggered to host when room host receive user's request to be a speaker.

  • function prototype:
Untitled
onSeatTakingRequested(ZegoUIKitUser audience)
1
Copied!
  • example:
Untitled
ZegoUIKitPrebuiltLiveAudioRoomFragment fragment ;
// ...
fragment.setSeatTakingRequestHostListener(new setSeatTakingRequestHostListener() {
    @Override
    public void onSeatTakingRequested(ZegoUIKitUser audience) {
        
    }
});
1
Copied!

onSeatTakingRequestCancelled

This callback will be triggered to host when room host receive audience's request to be a speaker and then canceled the request.

  • function prototype:
Untitled
 onSeatTakingRequestCancelled(ZegoUIKitUser audience)
1
Copied!
  • example:
Untitled
ZegoUIKitPrebuiltLiveAudioRoomFragment fragment ;
// ...
fragment.setSeatTakingRequestHostListener(new setSeatTakingRequestHostListener() {
    @Override
    public void onSeatTakingRequestCancelled(ZegoUIKitUser audience) {
        
    }
});
1
Copied!

onSeatTakingInviteRejected

This callback will be triggered to host when room host invite audience to be speaker and is rejected by audience.

  • function prototype:
Untitled
onSeatTakingInviteRejected()
1
Copied!
  • example:
Untitled
ZegoUIKitPrebuiltLiveAudioRoomFragment fragment ;
// ...
fragment.setSeatTakingRequestHostListener(new setSeatTakingRequestHostListener() {
    @Override
    public void onSeatTakingInviteRejected() {
        
    }
});
1
Copied!

ZegoSeatsChangedListener

onSeatsChanged

This callback will be triggered when room speaker changed.

  • function prototype:
Untitled
void onSeatsChanged(Map<Integer, ZegoUIKitUser> takenSeats, List<Integer> untakenSeats)
1
Copied!
  • example:
Untitled
ZegoUIKitPrebuiltLiveAudioRoomFragment fragment ;
// ...
fragment.setSeatsChangedListener(new ZegoSeatsChangedListener() {
    @Override
    public void onSeatsChanged(Map<Integer, ZegoUIKitUser> takenSeats, List<Integer> untakenSeats) {
        
    }
});
1
Copied!

ZegoSeatsClosedListener

onSeatsClosed

This callback will be triggered when room host close all seats

  • function prototype:
Untitled
void onSeatsClosed()
1
Copied!
  • example:
Untitled
ZegoUIKitPrebuiltLiveAudioRoomFragment fragment ;
// ...
fragment.setSeatsClosedListener(new ZegoSeatsClosedListener() {
    @Override
    public void onSeatsClosed() {
        
    }
});
1
Copied!

onSeatsOpened

This callback will be triggered when room host open all seats.

  • function prototype:
Untitled
void onSeatsOpened()
1
Copied!
  • example:
Untitled
ZegoUIKitPrebuiltLiveAudioRoomFragment fragment ;
// ...
fragment.setSeatsClosedListener(new ZegoSeatsClosedListener() {
    @Override
    public void onSeatsOpened() {
        
    }
});
1
Copied!