No need to route via ATOM_INTERNAL_MESSAGE
This commit is contained in:
parent
ad16e9ea49
commit
20431f4f2f
2 changed files with 2 additions and 5 deletions
|
@ -9,8 +9,8 @@ module.exports.wrap = (webContents) ->
|
||||||
webContents.__proto__ = EventEmitter.prototype
|
webContents.__proto__ = EventEmitter.prototype
|
||||||
|
|
||||||
# WebContents::send(channel, args..)
|
# WebContents::send(channel, args..)
|
||||||
webContents.send = (args...) ->
|
webContents.send = (channel, args...) ->
|
||||||
@_send 'ATOM_INTERNAL_MESSAGE', [args...]
|
@_send channel, [args...]
|
||||||
|
|
||||||
# Make sure webContents.executeJavaScript would run the code only when the
|
# Make sure webContents.executeJavaScript would run the code only when the
|
||||||
# web contents has been loaded.
|
# web contents has been loaded.
|
||||||
|
|
|
@ -4,9 +4,6 @@ v8Util = process.atomBinding 'v8_util'
|
||||||
# Created by init.coffee.
|
# Created by init.coffee.
|
||||||
ipc = v8Util.getHiddenValue global, 'ipc'
|
ipc = v8Util.getHiddenValue global, 'ipc'
|
||||||
|
|
||||||
ipc.on 'ATOM_INTERNAL_MESSAGE', (args...) ->
|
|
||||||
@emit args...
|
|
||||||
|
|
||||||
ipc.send = (args...) ->
|
ipc.send = (args...) ->
|
||||||
binding.send 'ipc-message', [args...]
|
binding.send 'ipc-message', [args...]
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue