Layer shortcuts

This commit is contained in:
Devine Lu Linvega
2018-01-20 11:50:38 +13:00
parent e34146ba87
commit 27d2e90965
5 changed files with 17 additions and 14 deletions

View File

@@ -168,6 +168,12 @@ function Cursor(rune)
ronin.commander.update();
}
this.select_layer = function(layer)
{
this.target = layer;
ronin.commander.update();
}
function make_offset(a,b)
{
return {x:a.x-b.x,y:a.y-b.y};

View File

@@ -82,16 +82,6 @@ function Keyboard()
ronin.io.methods.save.run();
}
if(e.key == "x"){
e.preventDefault();
ronin.cursor.swap_colors();
}
if(e.key == "z"){
e.preventDefault();
ronin.cursor.swap_layer();
}
ronin.hint.update(e);
}
}

View File

@@ -12,9 +12,6 @@ function Layer(name)
this.update = function(zoom = {scale:1,offset:{x:0,y:0}})
{
console.log(`Updated ${this.name}`);
// this.el.style.width = (ronin.frame.width)+"px";
// this.el.style.height = (ronin.frame.height)+"px";
}
this.context = function()