🔧 Add BrowserWindow.fromBrowserView()
This commit is contained in:
parent
fded32dc4f
commit
8c5aad8b17
1 changed files with 6 additions and 0 deletions
|
@ -144,6 +144,12 @@ BrowserWindow.fromWebContents = (webContents) => {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
BrowserWindow.fromBrowserView = (browserView) => {
|
||||||
|
for (const window of BrowserWindow.getAllWindows()) {
|
||||||
|
if (window.getBrowserView() === browserView) return window
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
BrowserWindow.fromDevToolsWebContents = (webContents) => {
|
BrowserWindow.fromDevToolsWebContents = (webContents) => {
|
||||||
for (const window of BrowserWindow.getAllWindows()) {
|
for (const window of BrowserWindow.getAllWindows()) {
|
||||||
const {devToolsWebContents} = window
|
const {devToolsWebContents} = window
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue