'use strict';

This commit is contained in:
Devine Lu Linvega 2018-08-28 16:34:17 +12:00
parent 8dae514ebf
commit d1e1bce3e9
12 changed files with 26 additions and 2 deletions

View File

@ -1,3 +1,5 @@
'use strict';
function Cursor() function Cursor()
{ {
this.pos = {x:0,y:0}; this.pos = {x:0,y:0};

View File

@ -1,3 +1,5 @@
'use strict';
function Dotgrid(width,height,grid_x,grid_y,block_x,block_y) function Dotgrid(width,height,grid_x,grid_y,block_x,block_y)
{ {
this.controller = null; this.controller = null;
@ -126,7 +128,7 @@ function Dotgrid(width,height,grid_x,grid_y,block_x,block_y)
// Basics // Basics
this.set_size = function(size = {width:300,height:300},interface = true,scale = 1) this.set_size = function(size = {width:300,height:300},ui = true,scale = 1)
{ {
size = { width:clamp(step(size.width,15),105,1080),height:clamp(step(size.height,15),120,1080)} size = { width:clamp(step(size.width,15),105,1080),height:clamp(step(size.height,15),120,1080)}
@ -135,7 +137,7 @@ function Dotgrid(width,height,grid_x,grid_y,block_x,block_y)
try{ try{
let win = require('electron').remote.getCurrentWindow(); let win = require('electron').remote.getCurrentWindow();
win.setSize((size.width+100)*scale,(size.height+100+(interface ? 10 : 0))*scale,true); win.setSize((size.width+100)*scale,(size.height+100+(ui ? 10 : 0))*scale,true);
} }
catch(err){ catch(err){
console.log("No window") console.log("No window")

View File

@ -1,3 +1,5 @@
'use strict';
function Generator(layer,style) function Generator(layer,style)
{ {
this.layer = layer; this.layer = layer;

View File

@ -1,3 +1,5 @@
'use strict';
function Guide() function Guide()
{ {
this.el = document.createElement("canvas"); this.el = document.createElement("canvas");

View File

@ -1,3 +1,5 @@
'use strict';
function Interface() function Interface()
{ {
this.el = document.createElement("div"); this.el = document.createElement("div");

View File

@ -1,3 +1,5 @@
'use strict';
function Controller() function Controller()
{ {
this.menu = {default:{}}; this.menu = {default:{}};

View File

@ -1,3 +1,5 @@
'use strict';
function History() function History()
{ {
this.index = 0; this.index = 0;

View File

@ -1,3 +1,5 @@
'use strict';
function Theme() function Theme()
{ {
let app = this; let app = this;

View File

@ -1,3 +1,5 @@
'use strict';
function Picker() function Picker()
{ {
this.memory = ""; this.memory = "";

View File

@ -1,3 +1,5 @@
'use strict';
function Renderer() function Renderer()
{ {
// Create SVG parts // Create SVG parts

View File

@ -1,3 +1,5 @@
'use strict';
function Tool() function Tool()
{ {
this.index = 0; this.index = 0;

View File

@ -1,3 +1,5 @@
'use strict';
document.onkeyup = (e) => document.onkeyup = (e) =>
{ {
let ch = e.key.toLowerCase(); let ch = e.key.toLowerCase();