Improved interface

This commit is contained in:
Devine Lu Linvega
2018-08-29 09:41:41 +12:00
parent d1e1bce3e9
commit 760175af78
6 changed files with 39 additions and 8 deletions

View File

@@ -12,7 +12,7 @@ function Picker()
this.el.setAttribute("placeholder",`${dotgrid.tool.style().color}`)
try{ dotgrid.controller.set("picker"); }
catch(err){ console.log("No controller"); }
catch(err){ }
dotgrid.interface.el.className = "picker"
this.el.focus()
@@ -42,7 +42,7 @@ function Picker()
dotgrid.guide.refresh();
try{ dotgrid.controller.set(); }
catch(err){ console.log("No controller"); }
catch(err){ }
dotgrid.interface.el.className = ""
this.el.blur()
@@ -88,6 +88,12 @@ function Picker()
return;
}
if(e.key == "Escape"){
this.stop();
e.preventDefault();
return;
}
this.update();
}