Show screensharign button only if connected
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
This commit is contained in:
parent
834579f778
commit
adddb0f0d2
1 changed files with 8 additions and 4 deletions
|
@ -506,10 +506,14 @@ export default class CallView extends React.Component<IProps, IState> {
|
||||||
/> : null;
|
/> : null;
|
||||||
|
|
||||||
let screensharingButton;
|
let screensharingButton;
|
||||||
// Screensharing is possible, if we can send a second stream and identify
|
// Screensharing is possible, if we can send a second stream and
|
||||||
// it using SDPStreamMetadata or if we can replace the already existing
|
// identify it using SDPStreamMetadata or if we can replace the already
|
||||||
// usermedia track by a screensharing track
|
// existing usermedia track by a screensharing track. We also need to be
|
||||||
if (this.props.call.opponentSupportsSDPStreamMetadata() || this.props.call.type === CallType.Video) {
|
// connected to know the state of the other side
|
||||||
|
if (
|
||||||
|
(this.props.call.opponentSupportsSDPStreamMetadata() || this.props.call.type === CallType.Video) &&
|
||||||
|
this.props.call.state === CallState.Connected
|
||||||
|
) {
|
||||||
screensharingButton = (
|
screensharingButton = (
|
||||||
<AccessibleButton
|
<AccessibleButton
|
||||||
className={screensharingClasses}
|
className={screensharingClasses}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue