This commit is contained in:
Devine Lu Linvega 2018-01-26 17:11:55 +13:00
parent 1c1fb8d75d
commit 5615e8de87
3 changed files with 10 additions and 6 deletions

View File

@ -55,6 +55,8 @@ function Cursor(rune)
var pos = ronin.cursor.mouse_pos(e); var pos = ronin.cursor.mouse_pos(e);
ronin.cursor.pos = pos; ronin.cursor.pos = pos;
ronin.commander.blur();
// Color Pick // Color Pick
if(ronin.commander.input_el.value == "~"){ if(ronin.commander.input_el.value == "~"){
ronin.brush.methods.pick.run({x:pos.x,y:pos.y}) ronin.brush.methods.pick.run({x:pos.x,y:pos.y})
@ -93,8 +95,7 @@ function Cursor(rune)
ronin.cursor.line.to = {x:pos.x,y:pos.y}; ronin.cursor.line.to = {x:pos.x,y:pos.y};
if(ronin.commander.active_module()){ } if(e.altKey && e.shiftKey){ ronin.brush.methods.pick.run(pos); }
else if(e.altKey && e.shiftKey){ ronin.brush.methods.pick.run(pos); }
else if(e.shiftKey){ ronin.cursor.drag(ronin.cursor.line); } else if(e.shiftKey){ ronin.cursor.drag(ronin.cursor.line); }
else{ ronin.brush.stroke(ronin.cursor.line); } else{ ronin.brush.stroke(ronin.cursor.line); }

View File

@ -161,8 +161,13 @@ function Guide()
{ {
var color = "black" var color = "black"
this.draw_line({x:ronin.frame.width/2,y:0},{x:ronin.frame.width/2,y:ronin.frame.height},color); // Center
this.draw_line({x:0,y:ronin.frame.height/2},{x:ronin.frame.width,y:ronin.frame.height/2},color); this.draw_line({x:0,y:ronin.frame.height/2},{x:10,y:ronin.frame.height/2},color);
this.draw_line({x:ronin.frame.width-10,y:ronin.frame.height/2},{x:ronin.frame.width,y:ronin.frame.height/2},color);
this.draw_line({x:(ronin.frame.width/2)-10,y:ronin.frame.height/2},{x:(ronin.frame.width/2)+10,y:ronin.frame.height/2},color);
this.draw_line({x:ronin.frame.width/2,y:0},{x:ronin.frame.width/2,y:10},color);
this.draw_line({x:ronin.frame.width/2,y:ronin.frame.height-10},{x:ronin.frame.width/2,y:ronin.frame.height},color);
this.draw_line({x:ronin.frame.width/2,y:(ronin.frame.height/2)-10},{x:ronin.frame.width/2,y:(ronin.frame.height/2)+10},color);
var ctx = this.context(); var ctx = this.context();

View File

@ -42,8 +42,6 @@ function Brush()
this.stroke = function(line) this.stroke = function(line)
{ {
ronin.commander.blur();
this.speed = distance_between(line.from,line.to); this.speed = distance_between(line.from,line.to);
for(pointer_id in this.pointers){ for(pointer_id in this.pointers){