Implement GuestViewInternal.createGuest and destroyGuest
This commit is contained in:
parent
d34cff2eef
commit
a22a5c67bd
8 changed files with 124 additions and 16 deletions
12
atom/renderer/lib/guest-view-internal.coffee
Normal file
12
atom/renderer/lib/guest-view-internal.coffee
Normal file
|
@ -0,0 +1,12 @@
|
|||
ipc = require 'ipc'
|
||||
|
||||
requestId = 0
|
||||
|
||||
module.exports =
|
||||
createGuest: (type, params, callback) ->
|
||||
requestId++
|
||||
ipc.send 'ATOM_SHELL_GUEST_VIEW_MANAGER_CREATE_GUEST', type, params, requestId
|
||||
ipc.on "ATOM_SHELL_RESPONSE_#{requestId}", callback
|
||||
|
||||
destroyGuest: (guestInstanceId) ->
|
||||
ipc.send 'ATOM_SHELL_GUEST_VIEW_MANAGER_DESTROY_GUEST', guestInstanceId
|
Loading…
Add table
Add a link
Reference in a new issue