Merge pull request #8155 from jfsiebel/start-presentation-minimized

Give the option to start with presentation minimized
This commit is contained in:
Chad Pilkey 2019-09-26 17:19:10 -04:00 committed by GitHub
commit 830b2d1d1e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -58,18 +58,7 @@ const toggleSwapLayout = () => {
swapLayout.tracker.changed();
};
export const shouldEnableSwapLayout = () => {
const { viewParticipantsWebcams } = Settings.dataSaving;
const usersVideo = VideoService.getAllWebcamUsers();
const poll = PollingService.mapPolls();
const { current_presentation: hasPresentation } = getPresentationInfo();
return usersVideo.length > 0 // prevent swap without any webcams
&& viewParticipantsWebcams // prevent swap when dataSaving for webcams is enabled
&& !poll.pollExists // prevent swap when there is a poll running
&& !shouldShowScreenshare() // and when there's screenshare
&& !shouldShowExternalVideo() // or there's an external video
};
export const shouldEnableSwapLayout = () => !shouldShowScreenshare() && !shouldShowExternalVideo();
export const getSwapLayout = () => {
swapLayout.tracker.depend();