Faster startup time (50ms)

This commit is contained in:
Feross Aboukhadijeh
2016-04-07 00:58:37 -07:00
parent 1947a03e94
commit d49a8e772f
3 changed files with 8 additions and 7 deletions

View File

@@ -1,6 +1,6 @@
# WebTorrent Desktop Version History
## UNRELEASED
## v0.3.2 - 2016-04-07
### Added
@@ -8,7 +8,10 @@
### Changed
- Faster startup time (50ms)
- Update Electron to 0.37.5
- Remove the white flash when loading pages and resizing the window
- Fix crash when sending IPC messages
### Fixed

View File

@@ -20,10 +20,8 @@ function init () {
ipcMain.on('ipcReady', function (e) {
app.ipcReady = true
app.emit('ipcReady')
setTimeout(function () {
windows.main.show()
try { console.timeEnd('init') } catch (err) {}
}, 50)
windows.main.show()
console.timeEnd('init')
})
var messageQueueMainToWebTorrent = []

View File

@@ -49,7 +49,7 @@ function createAboutWindow () {
function createWebTorrentHiddenWindow () {
var win = windows.webtorrent = new electron.BrowserWindow({
backgroundColor: '#282828',
backgroundColor: '#1E1E1E',
show: false,
center: true,
title: 'webtorrent-hidden-window',
@@ -79,7 +79,7 @@ function createMainWindow () {
return focusWindow(windows.main)
}
var win = windows.main = new electron.BrowserWindow({
backgroundColor: '#282828',
backgroundColor: '#1E1E1E',
darkTheme: true, // Forces dark theme (GTK+3)
icon: config.APP_ICON + '.png',
minWidth: 425,