mirror of
https://github.com/electron/electron.git
synced 2026-01-24 14:57:58 -05:00
Make remote.getCurrentWindow work for devtools.
This commit is contained in:
@@ -98,6 +98,7 @@ ipc.on 'ATOM_BROWSER_CURRENT_WINDOW', (event, processId, routingId) ->
|
||||
try
|
||||
BrowserWindow = require 'browser-window'
|
||||
window = BrowserWindow.fromProcessIdAndRoutingId processId, routingId
|
||||
window = BrowserWindow.fromDevTools processId, routingId unless window?
|
||||
event.returnValue = valueToMeta processId, routingId, window
|
||||
catch e
|
||||
event.returnValue = errorToMeta e
|
||||
|
||||
Reference in New Issue
Block a user