fix(layout): set external-video/screen share initial states on all layouts
Only smart layout takes screen sharing/external video states in account when populating its initial state. The others don't, and that causes some weird issues when switching back-and-forth between layout types due to their input states becoming inconsistent - ie having an active screen sharing and transitioning from Smart -> Custom would mark it as false (due to its absence from the initial state) and pollute its state for subsequent layouts. This commit guarantees those features are taken into account when populating initial input states for Focus On*/Custom layouts.
This commit is contained in:
parent
495aa2be0c
commit
6f13961018
@ -179,6 +179,12 @@ const CustomLayout = (props) => {
|
||||
cameraDock: {
|
||||
numCameras: cameraDockInput.numCameras,
|
||||
},
|
||||
externalVideo: {
|
||||
hasExternalVideo: input.externalVideo.hasExternalVideo,
|
||||
},
|
||||
screenShare: {
|
||||
hasScreenShare: input.screenShare.hasScreenShare,
|
||||
},
|
||||
}, INITIAL_INPUT_STATE),
|
||||
});
|
||||
}
|
||||
|
@ -95,6 +95,12 @@ const PresentationFocusLayout = (props) => {
|
||||
cameraDock: {
|
||||
numCameras: cameraDockInput.numCameras,
|
||||
},
|
||||
externalVideo: {
|
||||
hasExternalVideo: input.externalVideo.hasExternalVideo,
|
||||
},
|
||||
screenShare: {
|
||||
hasScreenShare: input.screenShare.hasScreenShare,
|
||||
},
|
||||
}, INITIAL_INPUT_STATE),
|
||||
});
|
||||
} else {
|
||||
|
@ -128,6 +128,12 @@ const VideoFocusLayout = (props) => {
|
||||
cameraDock: {
|
||||
numCameras: cameraDockInput.numCameras,
|
||||
},
|
||||
externalVideo: {
|
||||
hasExternalVideo: input.externalVideo.hasExternalVideo,
|
||||
},
|
||||
screenShare: {
|
||||
hasScreenShare: input.screenShare.hasScreenShare,
|
||||
},
|
||||
},
|
||||
INITIAL_INPUT_STATE,
|
||||
),
|
||||
|
Loading…
Reference in New Issue
Block a user