Get webContents on request.
This commit is contained in:
parent
c5f8fbf471
commit
b02bcc0016
1 changed files with 3 additions and 1 deletions
|
@ -15,7 +15,9 @@ BrowserWindow::_init = ->
|
|||
@setMenu menu if menu?
|
||||
|
||||
# Define getter for webContents.
|
||||
@webContents = @getWebContents()
|
||||
@__webContents = null
|
||||
@__defineGetter__ 'webContents', ->
|
||||
@__webContents ?= @getWebContents()
|
||||
@__devToolsWebContents = null
|
||||
@__defineGetter__ 'devToolsWebContents', ->
|
||||
if @isDevToolsOpened()
|
||||
|
|
Loading…
Add table
Reference in a new issue