diff --git a/react/features/stream-effects/audio-mixer/AudioMixerEffect.js b/react/features/stream-effects/audio-mixer/AudioMixerEffect.js index bf25790cd..64664028b 100644 --- a/react/features/stream-effects/audio-mixer/AudioMixerEffect.js +++ b/react/features/stream-effects/audio-mixer/AudioMixerEffect.js @@ -81,10 +81,6 @@ export class AudioMixerEffect { this._mixedMediaStream = this._audioMixer.start(); this._mixedMediaTrack = this._mixedMediaStream.getTracks()[0]; - // Sync the resulting mixed track enabled state with that of the track using the effect. - this.setMuted(!this._originalTrack.enabled); - this._originalTrack.enabled = true; - return this._mixedMediaStream; } @@ -94,9 +90,6 @@ export class AudioMixerEffect { * @returns {void} */ stopEffect() { - // Match state of the original track with that of the mixer track, not doing so can - // result in an inconsistent state e.g. redux state is muted yet track is enabled. - this._originalTrack.enabled = this._mixedMediaTrack.enabled; this._audioMixer.reset(); } @@ -107,7 +100,7 @@ export class AudioMixerEffect { * @returns {void} */ setMuted(muted: boolean) { - this._mixedMediaTrack.enabled = !muted; + this._originalTrack.enabled = !muted; } /** @@ -116,6 +109,6 @@ export class AudioMixerEffect { * @returns {boolean} */ isMuted() { - return !this._mixedMediaTrack.enabled; + return !this._originalTrack.enabled; } } diff --git a/react/features/toolbox/components/web/ShareDesktopButton.js b/react/features/toolbox/components/web/ShareDesktopButton.js index 3146abc9d..163aba926 100644 --- a/react/features/toolbox/components/web/ShareDesktopButton.js +++ b/react/features/toolbox/components/web/ShareDesktopButton.js @@ -5,8 +5,7 @@ import { IconShareDesktop } from '../../../base/icons'; import JitsiMeetJS from '../../../base/lib-jitsi-meet/_'; import { connect } from '../../../base/redux'; import { AbstractButton, type AbstractButtonProps } from '../../../base/toolbox/components'; -import { getLocalVideoTrack } from '../../../base/tracks'; -import { isScreenAudioShared } from '../../../screen-share'; +import { isScreenVideoShared } from '../../../screen-share'; type Props = AbstractButtonProps & { @@ -113,7 +112,6 @@ class ShareDesktopButton extends AbstractButton { * @returns {Object} */ const mapStateToProps = state => { - const localVideo = getLocalVideoTrack(state['features/base/tracks']); let desktopSharingEnabled = JitsiMeetJS.isDesktopSharingEnabled(); const { enableFeaturesBasedOnToken } = state['features/base/config']; @@ -129,7 +127,7 @@ const mapStateToProps = state => { return { _desktopSharingDisabledTooltipKey: desktopSharingDisabledTooltipKey, _desktopSharingEnabled: desktopSharingEnabled, - _screensharing: (localVideo && localVideo.videoType === 'desktop') || isScreenAudioShared(state) + _screensharing: isScreenVideoShared(state) }; };