fix(keyboard-shortcut) Fix error on number keypress (#11680)

Fix error when pressing a number bigger than the number of participants
Fix local recording issue
This commit is contained in:
Robert Pintilii 2022-06-15 12:04:06 +01:00 committed by GitHub
parent d3b650c741
commit d06d190229
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 11 additions and 2 deletions

View File

@ -50,6 +50,7 @@ import {
isFilmstripResizable, isFilmstripResizable,
showGridInVerticalView showGridInVerticalView
} from './functions'; } from './functions';
import { isStageFilmstripAvailable } from './functions.web';
export * from './actions.any'; export * from './actions.any';
@ -334,9 +335,17 @@ export function clickOnVideo(n: number) {
// Use the list that correctly represents the current order of the participants as visible in the UI. // Use the list that correctly represents the current order of the participants as visible in the UI.
const { remoteParticipants } = state['features/filmstrip']; const { remoteParticipants } = state['features/filmstrip'];
const participants = [ localId, ...remoteParticipants ]; const participants = [ localId, ...remoteParticipants ];
if (participants.length - 1 < n) {
return;
}
const { id, pinned } = getParticipantById(state, participants[n]); const { id, pinned } = getParticipantById(state, participants[n]);
dispatch(pinParticipant(pinned ? null : id)); if (isStageFilmstripAvailable(state)) {
dispatch(togglePinStageParticipant(id));
} else {
dispatch(pinParticipant(pinned ? null : id));
}
}; };
} }

View File

@ -160,7 +160,7 @@ const LocalRecordingManager: ILocalRecordingManager = {
// @ts-ignore // @ts-ignore
const gdmStream = await navigator.mediaDevices.getDisplayMedia({ const gdmStream = await navigator.mediaDevices.getDisplayMedia({
// @ts-ignore // @ts-ignore
video: { displaySurface: 'browser', frameRate: { min: 30 } }, video: { displaySurface: 'browser', frameRate: 30 },
audio: { audio: {
autoGainControl: false, autoGainControl: false,
channelCount: 2, channelCount: 2,