asarfuckery/electronasar/canary/renderer/api/web-frame.js

14 lines
361 B
JavaScript
Raw Normal View History

2019-01-17 18:00:12 +00:00
'use strict'
const { EventEmitter } = require('events')
const { webFrame, WebFrame } = process.atomBinding('web_frame')
// WebFrame is an EventEmitter.
Object.setPrototypeOf(WebFrame.prototype, EventEmitter.prototype)
EventEmitter.call(webFrame)
// Lots of webview would subscribe to webFrame's events.
webFrame.setMaxListeners(0)
module.exports = webFrame