feat(noise-suppression): add toggle noise-suppression API (#11968)

* add toggle noise-suppression API

* switch NS API from toggle to set
This commit is contained in:
Andrei Gavrilescu 2022-08-04 15:47:49 +03:00 committed by GitHub
parent ca259287be
commit 1abc6b1e4a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 1 deletions

View File

@ -75,6 +75,7 @@ import {
resizeLargeVideo
} from '../../react/features/large-video/actions.web';
import { toggleLobbyMode, answerKnockingParticipant } from '../../react/features/lobby/actions';
import { setNoiseSuppressionEnabled } from '../../react/features/noise-suppression/actions';
import {
hideNotification,
NOTIFICATION_TIMEOUT_TYPE,
@ -380,6 +381,9 @@ function initCommands() {
sendAnalytics(createApiEvent('screen.sharing.toggled'));
toggleScreenSharing(options.enable);
},
'set-noise-suppression-enabled': (options = {}) => {
APP.store.dispatch(setNoiseSuppressionEnabled(options.enabled));
},
'toggle-subtitles': () => {
APP.store.dispatch(toggleRequestingSubtitles());
},

View File

@ -60,6 +60,7 @@ const commands = {
setFollowMe: 'set-follow-me',
setLargeVideoParticipant: 'set-large-video-participant',
setMediaEncryptionKey: 'set-media-encryption-key',
setNoiseSuppressionEnabled: 'set-noise-suppression-enabled',
setParticipantVolume: 'set-participant-volume',
setSubtitles: 'set-subtitles',
setTileView: 'set-tile-view',
@ -79,9 +80,9 @@ const commands = {
toggleFilmStrip: 'toggle-film-strip',
toggleLobby: 'toggle-lobby',
toggleModeration: 'toggle-moderation',
toggleNoiseSuppression: 'toggle-noise-suppression',
toggleParticipantsPane: 'toggle-participants-pane',
toggleRaiseHand: 'toggle-raise-hand',
toggleShareAudio: 'toggle-share-audio',
toggleShareScreen: 'toggle-share-screen',
toggleSubtitles: 'toggle-subtitles',
toggleTileView: 'toggle-tile-view',