finish standardizing!

This commit is contained in:
Zeke Sikelianos 2016-03-28 18:00:30 -07:00 committed by Kevin Sawicki
parent 4e2f1311e0
commit 42e7ee2b4a
6 changed files with 22 additions and 13 deletions

View file

@ -53,12 +53,11 @@ BrowserWindow.prototype._init = function () {
this.webContents.on('page-title-updated', (event, title) => {
// The page-title-updated event is not emitted immediately (see #3645), so
// when the callback is called the BrowserWindow might have been closed.
if (this.isDestroyed())
return
if (this.isDestroyed()) return
// Route the event to BrowserWindow.
this.emit('page-title-updated', event, title)
if (!event.defaultPrevented)
this.setTitle(title)
if (!event.defaultPrevented) this.setTitle(title)
})
// Sometimes the webContents doesn't get focus when window is shown, so we have