clean up in deactivate

This commit is contained in:
DD 2017-08-25 14:00:30 -04:00
parent cc50a14e1d
commit dd27974d07

View file

@ -250,6 +250,9 @@ class LineMode extends React.Component {
}
deactivateTool () {
this.props.canvas.removeEventListener('mousewheel', this.onScroll);
this.tool.remove();
this.tool = null;
this.hitResult = null;
if (this.path) {
this.path.setSelected(false);
this.path = null;