Merge pull request #11224 from electron/browser-view-window

feature: Add `BrowserWindow.fromBrowserView()`
This commit is contained in:
Charles Kerr 2017-11-23 14:41:36 +01:00 committed by GitHub
commit 9c217fc6c7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 38 additions and 1 deletions

View file

@ -580,6 +580,12 @@ Returns `BrowserWindow` - The window that is focused in this application, otherw
Returns `BrowserWindow` - The window that owns the given `webContents`.
#### `BrowserWindow.fromBrowserView(browserView)`
* `browserView` [BrowserView](browser-view.md)
Returns `BrowserWindow | null` - The window that owns the given `browserView`. If the given view is not attached to any window, returns `null`.
#### `BrowserWindow.fromId(id)`
* `id` Integer