Update dimensions only when the tool area state changes
This commit is contained in:
1 parent
8aa7c9a8e4
commit
44058625b9
1 file changed
+4
-2
@@ -67,9 +67,11 @@ class Peers extends React.Component
|
||||
window.removeEventListener('resize', this.resizeUpdate.bind(this));
|
||||
}
|
||||
|
||||
componentDidUpdate()
|
||||
componentDidUpdate(prevProps)
|
||||
{
|
||||
this.updateDimensions();
|
||||
if (prevProps.toolAreaOpen !== this.props.toolAreaOpen) {
|
||||
this.updateDimensions();
|
||||
}
|
||||
}
|
||||
|
||||
render()
|
||||
|
||||
Reference in new issue
Block a user