Make send and loadUrl also supported methods of BrowserWindow.
This commit is contained in:
parent
272effd470
commit
1815f8b40d
1 changed files with 4 additions and 1 deletions
|
@ -87,8 +87,11 @@ BrowserWindow.fromDevTools = (processId, routingId) ->
|
|||
return window if devtools.processId == processId and
|
||||
devtools.routingId == routingId
|
||||
|
||||
# Helpers.
|
||||
BrowserWindow::loadUrl = -> @webContents.loadUrl.apply @webContents, arguments
|
||||
BrowserWindow::send = -> @webContents.send.apply @webContents, arguments
|
||||
|
||||
# Be compatible with old API.
|
||||
BrowserWindow::loadUrl = (url) -> @webContents.loadUrl(url)
|
||||
BrowserWindow::getUrl = -> @webContents.getUrl()
|
||||
BrowserWindow::reload = -> @webContents.reload()
|
||||
BrowserWindow::reloadIgnoringCache = -> @webContents.reloadIgnoringCache()
|
||||
|
|
Loading…
Reference in a new issue