electron/atom/browser/default_app/default_app.js

22 lines
475 B
JavaScript
Raw Normal View History

const electron = require('electron');
const app = electron.app;
const BrowserWindow = electron.BrowserWindow;
var mainWindow = null;
// Quit when all windows are closed.
app.on('window-all-closed', function() {
app.quit();
});
app.on('ready', function() {
2014-05-15 07:29:53 +00:00
mainWindow = new BrowserWindow({
width: 800,
height: 600,
autoHideMenuBar: true,
useContentSize: true,
2014-05-15 07:29:53 +00:00
});
2015-11-13 08:03:40 +00:00
mainWindow.loadURL('file://' + __dirname + '/index.html');
mainWindow.focus();
});