forked from aurelia/skeleton-navigation
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.js
32 lines (25 loc) · 785 Bytes
/
index.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
//Note: This file is provided as an aid to help you get up and running with
//Electron for desktop apps. See the readme file for more information.
'use strict';
var app = require('app');
var BrowserWindow = require('browser-window');
require('crash-reporter').start();
var mainWindow = null;
app.on('window-all-closed', function () {
if (process.platform != 'darwin') {
app.quit();
}
});
app.on('ready', function () {
mainWindow = new BrowserWindow({
width: 800,
height: 600
});
mainWindow.loadUrl('file://' + __dirname + '/index.html');
mainWindow.webContents.on('did-finish-load', function () {
mainWindow.setTitle(app.getName());
});
mainWindow.on('closed', function () {
mainWindow = null;
});
});