screenshare layout values
This commit is contained in:
parent
d2e2a34dfe
commit
e1f1b2e49f
@ -914,6 +914,34 @@ const reducer = (state, action) => {
|
||||
},
|
||||
};
|
||||
}
|
||||
case ACTIONS.SET_SCREEN_SHARE_OUTPUT: {
|
||||
const {
|
||||
width,
|
||||
height,
|
||||
top,
|
||||
left,
|
||||
} = action.value;
|
||||
const { screenShare } = state.output;
|
||||
if (screenShare.width === width
|
||||
&& screenShare.height === height
|
||||
&& screenShare.top === top
|
||||
&& screenShare.left === left) {
|
||||
return state;
|
||||
}
|
||||
return {
|
||||
...state,
|
||||
output: {
|
||||
...state.output,
|
||||
screenShare: {
|
||||
...screenShare,
|
||||
width,
|
||||
height,
|
||||
top,
|
||||
left,
|
||||
},
|
||||
},
|
||||
};
|
||||
}
|
||||
|
||||
// EXTERNAL VIDEO
|
||||
case ACTIONS.SET_HAS_EXTERNAL_VIDEO: {
|
||||
|
@ -794,6 +794,16 @@ class CustomLayout extends Component {
|
||||
zIndex: presentationBounds.zIndex,
|
||||
},
|
||||
});
|
||||
|
||||
newLayoutContextDispatch({
|
||||
type: ACTIONS.SET_SCREEN_SHARE_OUTPUT,
|
||||
value: {
|
||||
width: presentationBounds.width,
|
||||
height: presentationBounds.height,
|
||||
top: presentationBounds.top,
|
||||
left: presentationBounds.left,
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
render() {
|
||||
|
@ -571,6 +571,16 @@ class PresentationFocusLayout extends Component {
|
||||
zIndex: presentationBounds.zIndex,
|
||||
},
|
||||
});
|
||||
|
||||
newLayoutContextDispatch({
|
||||
type: ACTIONS.SET_SCREEN_SHARE_OUTPUT,
|
||||
value: {
|
||||
width: presentationBounds.width,
|
||||
height: presentationBounds.height,
|
||||
top: presentationBounds.top,
|
||||
left: presentationBounds.left,
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
render() {
|
||||
|
@ -598,6 +598,16 @@ class SmartLayout extends Component {
|
||||
zIndex: presentationBounds.zIndex,
|
||||
},
|
||||
});
|
||||
|
||||
newLayoutContextDispatch({
|
||||
type: ACTIONS.SET_SCREEN_SHARE_OUTPUT,
|
||||
value: {
|
||||
width: presentationBounds.width,
|
||||
height: presentationBounds.height,
|
||||
top: presentationBounds.top,
|
||||
left: presentationBounds.left,
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
render() {
|
||||
|
@ -590,6 +590,16 @@ class VideoFocusLayout extends Component {
|
||||
left: false,
|
||||
},
|
||||
});
|
||||
|
||||
newLayoutContextDispatch({
|
||||
type: ACTIONS.SET_SCREEN_SHARE_OUTPUT,
|
||||
value: {
|
||||
width: presentationBounds.width,
|
||||
height: presentationBounds.height,
|
||||
top: presentationBounds.top,
|
||||
left: presentationBounds.left,
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
render() {
|
||||
|
@ -14,10 +14,10 @@ const ScreenshareContainer = (props) => {
|
||||
const NewLayoutManager = useContext(NLayoutContext);
|
||||
const { newLayoutContextState } = NewLayoutManager;
|
||||
const { output, layoutLoaded } = newLayoutContextState;
|
||||
const { presentation } = output;
|
||||
const { screenShare } = output;
|
||||
|
||||
if (isVideoBroadcasting()) {
|
||||
return <ScreenshareComponent {...props} {...presentation} layoutLoaded={layoutLoaded}/>;
|
||||
return <ScreenshareComponent {...props} {...screenShare} layoutLoaded={layoutLoaded} />;
|
||||
}
|
||||
return null;
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user