1
0
mirror of https://github.com/BoostIo/Boostnote synced 2025-12-13 17:56:25 +00:00
This commit is contained in:
Dick Choi
2016-08-14 01:34:32 +09:00
parent 6bb78d3216
commit 2cbe07b373
34 changed files with 1482 additions and 765 deletions

View File

@@ -2,7 +2,7 @@ import _ from 'lodash'
const OSX = global.process.platform === 'darwin'
const electron = require('electron')
const { ipcRenderer } = electron
const { remote } = electron
const defaultConfig = {
zoom: 1,
@@ -66,17 +66,13 @@ function set (updates) {
let newConfig = Object.assign({}, defaultConfig, currentConfig, updates)
if (!validate(newConfig)) throw new Error('INVALID CONFIG')
_save(newConfig)
ipcRenderer.send('CONFIG_RENEW', {
remote.getCurrentWindow().webContents.send('config-renew', {
config: get(),
silent: false
})
}
ipcRenderer.send('CONFIG_RENEW', {
config: get(),
silent: true
})
export default {
get,
set,