Skip to content
This repository has been archived by the owner on Sep 11, 2024. It is now read-only.

Commit

Permalink
Something something call upgrades
Browse files Browse the repository at this point in the history
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
  • Loading branch information
SimonBrandner committed Aug 4, 2021
1 parent 972e345 commit 393ed0e
Showing 1 changed file with 8 additions and 14 deletions.
22 changes: 8 additions & 14 deletions src/components/views/voip/CallView.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -214,6 +214,8 @@ export default class CallView extends React.Component<IProps, IState> {
this.setState({
primaryFeed: primary,
secondaryFeeds: secondary,
micMuted: this.props.call.isMicrophoneMuted(),
vidMuted: this.props.call.isLocalVideoMuted(),
});
};

Expand Down Expand Up @@ -475,17 +477,6 @@ export default class CallView extends React.Component<IProps, IState> {
mx_CallView_callControls_hidden: !this.state.controlsVisible,
});

// We don't support call upgrades (yet) so hide the video mute button in voice calls
let vidMuteButton;
if (this.props.call.type === CallType.Video) {
vidMuteButton = (
<AccessibleButton
className={vidClasses}
onClick={this.onVidMuteClick}
/>
);
}

// Screensharing is possible, if we can send a second stream and
// identify it using SDPStreamMetadata or if we can replace the already
// existing usermedia track by a screensharing track. We also need to be
Expand Down Expand Up @@ -587,7 +578,10 @@ export default class CallView extends React.Component<IProps, IState> {
className={micClasses}
onClick={this.onMicMuteClick}
/>
{ vidMuteButton }
<AccessibleButton
className={vidClasses}
onClick={this.onVidMuteClick}
/>
<div className={micCacheClasses} />
<div className={vidCacheClasses} />
{ screensharingButton }
Expand Down Expand Up @@ -669,8 +663,8 @@ export default class CallView extends React.Component<IProps, IState> {
if (
!isOnHold &&
!transfereeCall &&
sidebarShown &&
(isVideoCall || someoneIsScreensharing)
sidebarShown //&&
//(isVideoCall || someoneIsScreensharing)
) {
sidebar = (
<CallViewSidebar
Expand Down

0 comments on commit 393ed0e

Please sign in to comment.