Allow to create strokes from the position of a handle

This commit is contained in:
Devine Lu Linvega 2017-11-14 10:16:49 +13:00
parent 2042b541a8
commit 317f04e00d

View File

@ -160,11 +160,13 @@ function Dotgrid(width,height,grid_x,grid_y,block_x,block_y,thickness = 3,lineca
if(e.altKey){ return; } if(e.altKey){ return; }
if(dotgrid.translation){ if(dotgrid.translation && !dotgrid.translation.to.is_equal(dotgrid.translation.from)){
dotgrid.translate(dotgrid.translation); dotgrid.translate(dotgrid.translation);
return; return;
} }
dotgrid.translation = null;
if(pos.x>0) return; if(pos.x>0) return;
if(from === null){ this.set_from(pos.scale(1/this.scale)); } if(from === null){ this.set_from(pos.scale(1/this.scale)); }