fix(raised-hand) Preserve raised hand order for active speaker
- fixes: https://github.com/jitsi/jitsi-meet/issues/10609
This commit is contained in:
parent
eb010061e0
commit
8236764501
|
@ -225,13 +225,14 @@ export function getSortedParticipantIds(stateful: Object | Function): Array<stri
|
||||||
}
|
}
|
||||||
|
|
||||||
const dominant = [];
|
const dominant = [];
|
||||||
|
const dominantId = dominantSpeaker?.id;
|
||||||
const local = remoteRaisedHandParticipants.has(id) ? [] : [ id ];
|
const local = remoteRaisedHandParticipants.has(id) ? [] : [ id ];
|
||||||
|
|
||||||
// Remove dominant speaker.
|
// In case dominat speaker has raised hand, keep the order in the raised hand queue.
|
||||||
if (dominantSpeaker && dominantSpeaker.id !== id) {
|
// In case they don't have raised hand, goes first in the participants list.
|
||||||
remoteRaisedHandParticipants.delete(dominantSpeaker.id);
|
if (dominantId && dominantId !== id && !remoteRaisedHandParticipants.has(dominantId)) {
|
||||||
reorderedParticipants.delete(dominantSpeaker.id);
|
reorderedParticipants.delete(dominantId);
|
||||||
dominant.push(dominantSpeaker.id);
|
dominant.push(dominantId);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Move self and participants with raised hand to the top of the list.
|
// Move self and participants with raised hand to the top of the list.
|
||||||
|
|
Loading…
Reference in New Issue