Add app.getBrowserWindows() API.

This commit is contained in:
Cheng Zhao 2013-10-05 13:13:04 +08:00
parent 61cc0bba25
commit 666f6b3a01
3 changed files with 11 additions and 3 deletions

View file

@ -1,4 +1,5 @@
bindings = process.atomBinding 'app'
objectsRegistry = require '../../atom/objects-registry.js'
EventEmitter = require('events').EventEmitter
Application = bindings.Application
@ -9,6 +10,9 @@ app = new Application
app.getHomeDir = ->
process.env[if process.platform is 'win32' then 'USERPROFILE' else 'HOME']
app.getBrowserWindows = ->
objectsRegistry.getAllWindows()
app.commandLine =
appendSwitch: bindings.appendSwitch,
appendArgument: bindings.appendArgument