electron/browser/api/lib/auto-updater.coffee

12 lines
375 B
CoffeeScript
Raw Normal View History

2013-06-03 09:59:34 +00:00
AutoUpdater = process.atomBinding('auto_updater').AutoUpdater
EventEmitter = require('events').EventEmitter
AutoUpdater::__proto__ = EventEmitter.prototype
autoUpdater = new AutoUpdater
2014-01-21 14:13:34 +00:00
autoUpdater.on 'update-downloaded-raw', (args...) ->
2014-02-03 20:39:54 +00:00
args[3] = new Date(args[3]) # releaseDate
2014-01-21 14:13:34 +00:00
@emit 'update-downloaded', args..., => @quitAndInstall()
module.exports = autoUpdater