mirror of
https://github.com/xibyte/jsketcher
synced 2025-12-10 02:13:58 +01:00
make tool clean on every switch
This commit is contained in:
parent
ccd33ca7e0
commit
94b0c276e5
1 changed files with 1 additions and 1 deletions
|
|
@ -59,6 +59,7 @@ export class ToolManager {
|
|||
}
|
||||
|
||||
takeControl(tool) {
|
||||
this.tool.cleanup();
|
||||
this.switchTool(tool);
|
||||
this.tool.restart();
|
||||
}
|
||||
|
|
@ -69,7 +70,6 @@ export class ToolManager {
|
|||
}
|
||||
|
||||
releaseControl() {
|
||||
this.tool.cleanup();
|
||||
this.takeControl(this.defaultTool);
|
||||
}
|
||||
}
|
||||
Loading…
Reference in a new issue