Fixed issue with the second path.

This commit is contained in:
Devine Lu Linvega 2017-01-23 15:48:32 -07:00
parent 4e235bbd36
commit e3c30aff2b
2 changed files with 5 additions and 2 deletions

View File

@ -76,6 +76,9 @@ function Cursor(rune)
if(ronin.module){
this.set_mode(ronin.module);
}
else if(event.altKey == true && event.shiftKey == true){
this.set_mode(ronin.surface.active_layer);
}
else if(event.altKey == true){
this.set_mode(ronin.surface);
}

View File

@ -6,6 +6,7 @@ function Vector(rune)
this.variables = {"fill_color" : "none","stroke_width" : 5,"stroke_color" : "#ffffff", "line_cap" : "square"};
this.layer = null;
this.coordinates = [];
this.install = function()
{
@ -27,6 +28,7 @@ function Vector(rune)
this.active = function(cmd)
{
this.coordinates = [];
this.layer.clear();
ronin.surface.active_layer.context().lineCap = cmd.variable("line_cap") ? cmd.variable("line_cap").value : "round";
ronin.surface.active_layer.context().lineWidth = cmd.variable("stroke_width") ? cmd.variable("stroke_width").value : 5;
@ -51,8 +53,6 @@ function Vector(rune)
}
}
this.coordinates = [];
this.create_command = function()
{
var command = "+ ";