diff options
author | brynnchernosky <56202540+brynnchernosky@users.noreply.github.com> | 2023-02-22 22:37:37 -0500 |
---|---|---|
committer | brynnchernosky <56202540+brynnchernosky@users.noreply.github.com> | 2023-02-22 22:37:37 -0500 |
commit | dffb5bdfdcffc7e1f85888b7222468bfb95a05ac (patch) | |
tree | 3b11843d719edd651088b7b1b8e42daa7b1fb499 /src/client/views/nodes/PhysicsSimulationWedge.tsx | |
parent | 4c0336f3d7380595f9a5e074ec8c0e31f061a709 (diff) |
improvements
Diffstat (limited to 'src/client/views/nodes/PhysicsSimulationWedge.tsx')
-rw-r--r-- | src/client/views/nodes/PhysicsSimulationWedge.tsx | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/client/views/nodes/PhysicsSimulationWedge.tsx b/src/client/views/nodes/PhysicsSimulationWedge.tsx index c5a186f18..6134a6bc0 100644 --- a/src/client/views/nodes/PhysicsSimulationWedge.tsx +++ b/src/client/views/nodes/PhysicsSimulationWedge.tsx @@ -49,11 +49,9 @@ export default class Wedge extends React.Component<IWedgeProps, IState> { } componentDidUpdate(prevProps: Readonly<IWedgeProps>, prevState: Readonly<IState>, snapshot?: any): void { - if (prevState.coordinates != this.state.coordinates) { - this.updateCoordinates(); - } if (prevProps.startHeight != this.props.startHeight || prevProps.startWidth != this.props.startWidth) { this.setState({angleInRadians: Math.atan(this.props.startHeight / this.props.startWidth)}); + this.updateCoordinates(); } } |