From a84b1019f10b5c0e138ef67b8a56042837c27687 Mon Sep 17 00:00:00 2001 From: mmcw-dev Date: Thu, 4 Jan 2018 23:52:06 -0500 Subject: [PATCH] When devices are discovered, represent that in the UI. --- app/index.html | 8 ++++---- app/js/app.js | 2 +- app/lib/devices-ui.js | 9 +++++++-- app/main.js | 4 ++-- 4 files changed, 14 insertions(+), 9 deletions(-) diff --git a/app/index.html b/app/index.html index 9ada48c..bdb70fb 100644 --- a/app/index.html +++ b/app/index.html @@ -202,21 +202,21 @@

Devices

-

Projector

-

Camera

-

Light

-
diff --git a/app/js/app.js b/app/js/app.js index b3e1292..90eae4c 100644 --- a/app/js/app.js +++ b/app/js/app.js @@ -3059,7 +3059,7 @@ var { remote, ipcRenderer } = require('electron'), mscript = require('./lib/mscript.js'); -mcopy.cfg = JSON.parse(fs.readFileSync('./data/cfg.json'), 'utf8'); +mcopy.cfg = require('./data/cfg.json') /****** State shared by ALL interfaces diff --git a/app/lib/devices-ui.js b/app/lib/devices-ui.js index fcf510f..4db67ae 100644 --- a/app/lib/devices-ui.js +++ b/app/lib/devices-ui.js @@ -8,9 +8,14 @@ devices.init = function () { }; devices.listen = function () { 'use strict'; + let opt ipcRenderer.on('ready', function (event, arg) { - //console.log(arg.camera); - //console.log(arg.projector); + opt = $('