Browse Source

fix(video-layout): handle undefined video type for large video update

When replace track is called in JitsiConference, there is no
guarantee a videoType update will come in presence before
the track added event. This can lead to the situation in
LargeVideoManager where an update is called with a track
with an undefined videoType.
master
Leonard Kim 7 years ago
parent
commit
5dc2aca081
1 changed files with 2 additions and 2 deletions
  1. 2
    2
      modules/UI/videolayout/VideoLayout.js

+ 2
- 2
modules/UI/videolayout/VideoLayout.js View File

4
 import {
4
 import {
5
     JitsiParticipantConnectionStatus
5
     JitsiParticipantConnectionStatus
6
 } from '../../../react/features/base/lib-jitsi-meet';
6
 } from '../../../react/features/base/lib-jitsi-meet';
7
+import { VIDEO_TYPE } from '../../../react/features/base/media';
7
 import {
8
 import {
8
     getPinnedParticipant,
9
     getPinnedParticipant,
9
     pinParticipant
10
     pinParticipant
10
 } from '../../../react/features/base/participants';
11
 } from '../../../react/features/base/participants';
11
-
12
 import { SHARED_VIDEO_CONTAINER_TYPE } from '../shared_video/SharedVideo';
12
 import { SHARED_VIDEO_CONTAINER_TYPE } from '../shared_video/SharedVideo';
13
 import SharedVideoThumb from '../shared_video/SharedVideoThumb';
13
 import SharedVideoThumb from '../shared_video/SharedVideoThumb';
14
 
14
 
977
             largeVideo.updateLargeVideo(
977
             largeVideo.updateLargeVideo(
978
                 id,
978
                 id,
979
                 smallVideo.videoStream,
979
                 smallVideo.videoStream,
980
-                videoType
980
+                videoType || VIDEO_TYPE.CAMERA
981
             ).then(() => {
981
             ).then(() => {
982
                 // update current small video and the old one
982
                 // update current small video and the old one
983
                 smallVideo.updateView();
983
                 smallVideo.updateView();

Loading…
Cancel
Save