feat: add event.senderId property to IPCs sent via ipcRenderer.sendTo (#14395)

This commit is contained in:
Milan Burda 2018-09-01 03:13:51 +02:00 committed by Charles Kerr
parent b89848d683
commit c17a1b37ea
11 changed files with 90 additions and 31 deletions

View file

@ -9,8 +9,8 @@ const ipcNative = process.atomBinding('ipc')
// private/public APIs.
v8Util.setHiddenValue(global, 'ipcNative', ipcNative)
ipcNative.onMessage = function (channel, args) {
ipcRenderer.emit(channel, {sender: ipcRenderer}, ...args)
ipcNative.onMessage = function (channel, args, senderId) {
ipcRenderer.emit(channel, {sender: ipcRenderer, senderId}, ...args)
}
ipcNative.onExit = function () {