Add API to get any global variable from browser.
This commit is contained in:
parent
7a2734ed71
commit
a06c9b806b
2 changed files with 17 additions and 0 deletions
|
@ -54,6 +54,12 @@ ipc.on 'ATOM_BROWSER_REQUIRE', (event, processId, routingId, module) ->
|
|||
catch e
|
||||
event.result = type: 'error', value: e.message
|
||||
|
||||
ipc.on 'ATOM_BROWSER_GLOBAL', (event, processId, routingId, name) ->
|
||||
try
|
||||
event.result = new Meta(processId, routingId, global[name])
|
||||
catch e
|
||||
event.result = type: 'error', value: e.message
|
||||
|
||||
ipc.on 'ATOM_BROWSER_CURRENT_WINDOW', (event, processId, routingId) ->
|
||||
try
|
||||
windows = objectsRegistry.getAllWindows()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue