All native objects have prototype now
This commit is contained in:
parent
8cd4612fe0
commit
6e0cde5b24
9 changed files with 12 additions and 12 deletions
|
@ -10,7 +10,7 @@ const electron = require('electron')
|
|||
const {deprecate, Menu} = electron
|
||||
const {EventEmitter} = require('events')
|
||||
|
||||
Object.setPrototypeOf(app, EventEmitter.prototype)
|
||||
Object.setPrototypeOf(app.__proto__, EventEmitter.prototype)
|
||||
|
||||
let appPath = null
|
||||
|
||||
|
@ -78,5 +78,5 @@ for (let name of events) {
|
|||
// Wrappers for native classes.
|
||||
process.atomBinding('download_item')._setWrapDownloadItem((downloadItem) => {
|
||||
// downloadItem is an EventEmitter.
|
||||
Object.setPrototypeOf(downloadItem, EventEmitter.prototype)
|
||||
Object.setPrototypeOf(downloadItem.__proto__, EventEmitter.prototype)
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue