diff --git a/index.js b/index.js index a5658cd..3b3a0fd 100644 --- a/index.js +++ b/index.js @@ -65,11 +65,9 @@ app.on('ready', () => { createWindow() win.on('focus', () => { - console.log("win focus") }) win.on('blur', () => { - console.log("win blur") }) }) diff --git a/ui/arduino/store.js b/ui/arduino/store.js index 5b8e45d..04889b4 100644 --- a/ui/arduino/store.js +++ b/ui/arduino/store.js @@ -24,7 +24,6 @@ async function confirmDialog(msg, cancelMsg, confirmMsg) { cancelId: 1, message: msg }) - console.log('confirm', response) return Promise.resolve(response) } @@ -103,14 +102,17 @@ async function store(state, emitter) { } emitter.emit('render') }) + emitter.on('change-view', (view) => { - if (state.view === 'file-manager') { if (view != state.view) { state.selectedFiles = [] } emitter.emit('refresh-files') } + if(view === 'file-manager') { + emitter.emit('stop') + } state.view = view emitter.emit('render') updateMenu() @@ -158,7 +160,6 @@ async function store(state, emitter) { cancelId: 0, message: "Could not connect to the board. Reset it and try again." }) - console.log('Reset request acknowledged', response) emitter.emit('connection-timeout') }, 3500) try { @@ -1194,7 +1195,6 @@ async function store(state, emitter) { && f.source == selectedFile.source && f.parentFolder == selectedFile.parentFolder }) - console.log('already open', alreadyOpen) if (!alreadyOpen) { // This file is not open yet, @@ -1544,19 +1544,16 @@ async function store(state, emitter) { function filterDoubleRun(onlySelected = false) { if (preventDoubleRun) return - console.log('>>> RUN CODE ACTUAL <<<') emitter.emit('run', onlySelected) timedReset() } function runCode() { - console.log('>>> RUN CODE REQUEST <<<') if (canExecute({ view: state.view, isConnected: state.isConnected })) { filterDoubleRun() } } function runCodeSelection() { - console.log('>>> RUN CODE REQUEST <<<') if (canExecute({ view: state.view, isConnected: state.isConnected })) { filterDoubleRun(true) } @@ -1629,13 +1626,12 @@ async function store(state, emitter) { } const tabExists = state.openFiles.find(f => f.parentFolder === newFile.parentFolder && f.fileName === newFile.fileName && f.source === newFile.source) if (tabExists || fullPathExists) { - const confirmation = confirmDialog(`File ${newFile.fileName} already exists on ${source}. Please choose another name.`, 'OK') + const confirmation = await confirmDialog(`File ${newFile.fileName} already exists on ${source}. Please choose another name.`, 'OK') return false } // LEAK > listeners keep getting added and not removed when tabs are closed // additionally I found that closing a tab has actually added an extra listener newFile.editor.onChange = function() { - console.log('editor has changes') newFile.hasChanges = true emitter.emit('render') }
Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.
Alternative Proxies: