diff --git a/assets/css/main.css b/assets/css/main.css index d0300f2..2e64796 100644 --- a/assets/css/main.css +++ b/assets/css/main.css @@ -2375,6 +2375,13 @@ input, select, textarea { background: #022b3a; } + .select5 option { + color: #ffffff; + background: #022b3a; + padding-top: 4px; + padding-left: 4px; + } + .select1 { height: 1.75em; width: 12em; @@ -2732,7 +2739,7 @@ input, select, textarea { width: 100%; } - @media screen and (max-width: 480px) { + @media screen and (max-width: 380px) { ul.actions:not(.fixed) { -moz-flex-direction: column; @@ -2867,6 +2874,15 @@ input, select, textarea { } +/* Modal dialog centering */ + .modal { + padding-left: 8px; + padding-right: 8px; + display: flex; + justify-content: center; + text-align: center; + } + /* Section/Article */ section.special, article.special { @@ -3270,12 +3286,18 @@ input, select, textarea { .wrapper.style4 { background-color: #022b3a; + background-color: #3e4094; } .wrapper.style4-alt { background-color: #022b3a; } + .wrapper.style5 { + background-color: #022b3a; + background-color: #bd2d2d; + } + .wrapper.fullscreen { display: -moz-flex; display: -webkit-flex; diff --git a/index.html b/index.html index 0df69b5..6524b22 100644 --- a/index.html +++ b/index.html @@ -11,9 +11,7 @@ - - + @@ -156,12 +154,12 @@

Available Tunes - +

diff --git a/main.js b/main.js index 6676029..39208d5 100644 --- a/main.js +++ b/main.js @@ -14,7 +14,8 @@ var avrdudeIsRunning = false; var teensyLoaderIsRunning = false; var teensyLoaderErr = "" -function createWindow () { +function createWindow () +{ // Create the browser window. win = new BrowserWindow({ width: 800, @@ -56,8 +57,6 @@ function createWindow () { }); } - - //Required for newer versions of Electron to work with serialport app.allowRendererProcessReuse = false diff --git a/renderer.js b/renderer.js index 37d6a8f..9f77a35 100644 --- a/renderer.js +++ b/renderer.js @@ -430,8 +430,33 @@ function downloadIni() } +function showBasetuneWarning() +{ + let mainWindow = remote.BrowserWindow.getFocusedWindow(); + warningWindow = new remote.BrowserWindow({ width: 550, height: 330, modal: true, parent: mainWindow, show: false }) + + warningWindow.loadURL(`file://${__dirname}/warning.html?board=` + "test"); + + warningWindow.once('ready-to-show', () => { + warningWindow.show(); + }) + + warningWindow.on('close', () => { + warningWindow = null; + downloadBasetune(); + }); + + +} + function downloadBasetune() { + console.log("downloading"); + let dialogWindow = remote.BrowserWindow.getFocussedWindow(); //Close the warning dialog + dialogWindow.close(); + + let mainWindow = remote.BrowserWindow.getAllWindows()[0]; //Close the warning dialog + mainWindow.focus(); var basetuneSelect = document.getElementById('basetunesSelect'); var basetuneOption = basetuneSelect.options[basetuneSelect.selectedIndex]; //var version = document.getElementById('versionsSelect'); diff --git a/warning.html b/warning.html new file mode 100644 index 0000000..c15dbda --- /dev/null +++ b/warning.html @@ -0,0 +1,35 @@ + + + + + + +
+ + +
+

WARNING

+
+ + +
+ + + \ No newline at end of file