drag tool as alternate mode for circle

This commit is contained in:
Val Erastov 2016-11-30 22:51:59 -08:00
parent 939b93410e
commit fba94a47f5

View file

@ -40,10 +40,14 @@ export class Circle extends SketchObject {
return Math.abs(math.distance(aim.x, aim.y, this.c.x, this.c.y) - this.r.get());
}
getDefaultTool(viewer) {
var editTool = new EditCircleTool(viewer, null);
editTool.circle = this;
return editTool;
getDefaultTool(viewer, alternative) {
if (alternative) {
return super.getDefaultTool(viewer, alternative);
} else {
const editTool = new EditCircleTool(viewer, null);
editTool.circle = this;
return editTool;
}
}
}