fix(filmstrip) Fix pinning (#11889)

This commit is contained in:
Robert Pintilii 2022-07-20 18:34:46 +03:00 committed by GitHub
parent cb712eb4ab
commit 5dbb17bc81
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 3 deletions

View File

@ -72,6 +72,7 @@ StateListenerRegistry.register(
/* listener */ ({ layout }, store) => {
switch (layout) {
case LAYOUTS.TILE_VIEW:
store.dispatch(clearStageParticipants());
store.dispatch(pinParticipant(null));
store.dispatch(setTileViewDimensions());
break;
@ -196,9 +197,9 @@ StateListenerRegistry.register(
* there's just one).
*/
StateListenerRegistry.register(
/* selector */ state => state['features/filmstrip'].activeParticipants.length,
/* listener */(length, store) => {
if (length <= 1) {
/* selector */ state => state['features/filmstrip'].activeParticipants,
/* listener */(activeParticipants, store) => {
if (activeParticipants.length <= 1) {
store.dispatch(selectParticipantInLargeVideo());
}
});