Switch a whiteboard
This document describes how to switch the displayed whiteboard.
Prerequisites
Create a whiteboard by referring to Create a super board.
Implementation steps
Listen for remote whiteboard switching
Call the onRemoteSuperBoardSubViewSwitched interface to listen for remote whiteboard switching.
await ZegoSuperBoardManager.onRemoteSuperBoardSubViewSwitched = ((uniqueID) {
// Receive the remote whiteboard, no further action is required here.
// You can update the UI based on the information of the current currentSuperBoardSubView, such as updating the current displayed whiteboard name.}); Switch a whiteboard
Call the switchSuperBoardSubView method to switch white boards.
ZegoSuperBoardView superBoardView = ZegoSuperBoardManager.instance.superBoardView;
// Switch the whiteboard
// subViewModel is the shared-whiteboard list
await ZegoSuperBoardManager.instance.switchSuperBoardSubView(uniqueID: subViewModel.uniqueID); 
