Merge pull request #16 from torjusti/fix/notifications-scrollbar

Fix notifications scrollbar
master
Stefan Otto 2018-07-17 09:05:23 +02:00 committed by GitHub
commit 637ef19d8f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 21 additions and 16 deletions

View File

@ -52,18 +52,22 @@ export default class FullView extends React.Component
this._setTracks(videoTrack);
if (fscreen.fullscreenEnabled) {
if (fscreen.fullscreenEnabled)
{
fscreen.addEventListener('fullscreenchange', this.handleExitFullscreen, false);
fscreen.requestFullscreen(this.video.current);
}
}
componentWillUnmount() {
componentWillUnmount()
{
fscreen.removeEventListener('fullscreenchange', this.handleExitFullscreen);
}
handleExitFullscreen = () => {
if (!fscreen.fullscreenElement) {
handleExitFullscreen = () =>
{
if (!fscreen.fullscreenElement)
{
this.props.toggleFullscreen();
}
};
@ -87,6 +91,7 @@ export default class FullView extends React.Component
if (videoTrack)
{
const stream = new MediaStream;
stream.addTrack(videoTrack);
video.srcObject = stream;
}
@ -101,5 +106,6 @@ FullView.propTypes =
{
videoTrack : PropTypes.any,
videoVisible : PropTypes.bool,
videoProfile : PropTypes.string
videoProfile : PropTypes.string,
toggleFullscreen : PropTypes.func.isRequired
};

View File

@ -25,12 +25,7 @@ class Peers extends React.Component
updateDimensions()
{
const n = this.props.videoStreams ? this.props.videoStreams : 0;
if (n == 0)
{
return;
}
const n = this.props.peers.length;
const width = this.refs.peers.clientWidth;
const height = this.refs.peers.clientHeight;
@ -72,10 +67,13 @@ class Peers extends React.Component
window.removeEventListener('resize', this.resizeUpdate.bind(this));
}
componentDidUpdate()
componentDidUpdate(prevProps)
{
if (prevProps.toolAreaOpen !== this.props.toolAreaOpen)
{
this.updateDimensions();
}
}
render()
{

View File

@ -29,6 +29,7 @@ html {
body {
height: 100%;
overflow-x: hidden;
}
#multiparty-meeting {