Browse Source

fix(filmstrip): Separate remote videos and local video

The 1:1 call UI and vertical filmstrip act on remote videos
while leaving local video alone. To facilitate acting only on
remote videos, place remote videos into their own container element.
master
Leonard Kim 8 years ago
parent
commit
82ecfac4ee

+ 8
- 0
css/_filmstrip.scss View File

62
         videos. */
62
         videos. */
63
         font-size: 0pt;
63
         font-size: 0pt;
64
 
64
 
65
+        #filmstripLocalVideo {
66
+            padding-left: 0;
67
+        }
68
+
65
         &.hidden {
69
         &.hidden {
66
             bottom: -196px;
70
             bottom: -196px;
67
         }
71
         }
68
 
72
 
73
+        .remote-videos-container {
74
+            display: flex;
75
+        }
76
+
69
         .videocontainer {
77
         .videocontainer {
70
             display: none;
78
             display: none;
71
             position: relative;
79
             position: relative;

+ 1
- 1
modules/UI/shared_video/SharedVideo.js View File

656
     avatar.src = "https://img.youtube.com/vi/" + this.url + "/0.jpg";
656
     avatar.src = "https://img.youtube.com/vi/" + this.url + "/0.jpg";
657
     container.appendChild(avatar);
657
     container.appendChild(avatar);
658
 
658
 
659
-    var remotes = document.getElementById('remoteVideos');
659
+    var remotes = document.getElementById('filmstripRemoteVideosContainer');
660
     return remotes.appendChild(container);
660
     return remotes.appendChild(container);
661
 };
661
 };
662
 
662
 

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

14
         this.iconMenuUpClassName = 'icon-menu-up';
14
         this.iconMenuUpClassName = 'icon-menu-up';
15
         this.filmstripContainerClassName = 'filmstrip';
15
         this.filmstripContainerClassName = 'filmstrip';
16
         this.filmstrip = $('#remoteVideos');
16
         this.filmstrip = $('#remoteVideos');
17
+        this.filmstripRemoteVideos = $('#filmstripRemoteVideosContainer');
17
         this.eventEmitter = eventEmitter;
18
         this.eventEmitter = eventEmitter;
18
 
19
 
19
         // Show the toggle button and add event listeners only when out of
20
         // Show the toggle button and add event listeners only when out of
456
         }
457
         }
457
 
458
 
458
         let localThumb = $("#localVideoContainer");
459
         let localThumb = $("#localVideoContainer");
459
-        let remoteThumbs = this.filmstrip.children(selector)
460
-            .not("#localVideoContainer");
460
+        let remoteThumbs = this.filmstripRemoteVideos.children(selector);
461
 
461
 
462
         // Exclude the local video container if it has been hidden.
462
         // Exclude the local video container if it has been hidden.
463
         if (localThumb.hasClass("hidden")) {
463
         if (localThumb.hasClass("hidden")) {

+ 1
- 1
modules/UI/videolayout/RemoteVideo.js View File

800
     overlay.className = "videocontainer__hoverOverlay";
800
     overlay.className = "videocontainer__hoverOverlay";
801
     container.appendChild(overlay);
801
     container.appendChild(overlay);
802
 
802
 
803
-    var remotes = document.getElementById('remoteVideos');
803
+    var remotes = document.getElementById('filmstripRemoteVideosContainer');
804
     return remotes.appendChild(container);
804
     return remotes.appendChild(container);
805
 };
805
 };
806
 
806
 

+ 61
- 29
react/features/conference/components/Conference.web.js View File

106
                                 src = 'images/spin.svg' />
106
                                 src = 'images/spin.svg' />
107
                         </span>
107
                         </span>
108
                     </div>
108
                     </div>
109
-                    <div className = 'filmstrip'>
110
-                        <div
111
-                            className = 'filmstrip__videos'
112
-                            id = 'remoteVideos'>
113
-                            <span
114
-                                className = 'videocontainer'
115
-                                id = 'localVideoContainer'>
116
-                                <div className = 'videocontainer__background' />
117
-                                <span id = 'localVideoWrapper' />
118
-                                <audio
119
-                                    autoPlay = { true }
120
-                                    id = 'localAudio'
121
-                                    muted = { true } />
122
-                                <div className = 'videocontainer__toolbar' />
123
-                                <div className = 'videocontainer__toptoolbar' />
124
-                                <div
125
-                                    className
126
-                                        = 'videocontainer__hoverOverlay' />
127
-                            </span>
128
-                            <audio
129
-                                id = 'userJoined'
130
-                                preload = 'auto'
131
-                                src = 'sounds/joined.wav' />
132
-                            <audio
133
-                                id = 'userLeft'
134
-                                preload = 'auto'
135
-                                src = 'sounds/left.wav' />
136
-                        </div>
137
-                    </div>
109
+                    { this._renderFilmstrip() }
138
                 </div>
110
                 </div>
139
 
111
 
140
                 <DialogContainer />
112
                 <DialogContainer />
143
             </div>
115
             </div>
144
         );
116
         );
145
     }
117
     }
118
+
119
+    /**
120
+     * Creates a React Element for displaying filmstrip videos.
121
+     *
122
+     * @private
123
+     * @returns {ReactElement}
124
+     */
125
+    _renderFilmstrip() {
126
+        return (
127
+            <div className = 'filmstrip'>
128
+                <div
129
+                    className = 'filmstrip__videos'
130
+                    id = 'remoteVideos'>
131
+                    <div
132
+                        className = 'filmstrip__videos'
133
+                        id = 'filmstripLocalVideo'>
134
+                        <span
135
+                            className = 'videocontainer'
136
+                            id = 'localVideoContainer'>
137
+                            <div className = 'videocontainer__background' />
138
+                            <span id = 'localVideoWrapper' />
139
+                            <audio
140
+                                autoPlay = { true }
141
+                                id = 'localAudio'
142
+                                muted = { true } />
143
+                            <div className = 'videocontainer__toolbar' />
144
+                            <div className = 'videocontainer__toptoolbar' />
145
+                            <div
146
+                                className
147
+                                    = 'videocontainer__hoverOverlay' />
148
+                        </span>
149
+                    </div>
150
+                    <div
151
+                        className = 'filmstrip__videos'
152
+                        id = 'filmstripRemoteVideos'>
153
+                        {
154
+
155
+                            /*
156
+                                This extra video container is needed for
157
+                                scrolling thumbnails in firefox, otherwise the
158
+                                flex thumbnails resize instead of causing
159
+                                overflow.
160
+                            */
161
+                        }
162
+                        <div
163
+                            className = 'remote-videos-container'
164
+                            id = 'filmstripRemoteVideosContainer' />
165
+                    </div>
166
+                    <audio
167
+                        id = 'userJoined'
168
+                        preload = 'auto'
169
+                        src = 'sounds/joined.wav' />
170
+                    <audio
171
+                        id = 'userLeft'
172
+                        preload = 'auto'
173
+                        src = 'sounds/left.wav' />
174
+                </div>
175
+            </div>
176
+        );
177
+    }
146
 }
178
 }
147
 
179
 
148
 export default reactReduxConnect()(Conference);
180
 export default reactReduxConnect()(Conference);

Loading…
Cancel
Save