Π·Π΅ΡΠΊΠ°Π»ΠΎ ΠΈΠ· https://github.com/Unity-Technologies/electron.git
π§ Add BrowserWindow.fromBrowserView()
This commit is contained in:
Π ΠΎΠ΄ΠΈΡΠ΅Π»Ρ
fded32dc4f
ΠΠΎΠΌΠΌΠΈΡ
8c5aad8b17
|
@ -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) => {
|
||||
for (const window of BrowserWindow.getAllWindows()) {
|
||||
const {devToolsWebContents} = window
|
||||
|
|
ΠΠ°Π³ΡΡΠ·ΠΊΠ°β¦
Π‘ΡΡΠ»ΠΊΠ° Π² Π½ΠΎΠ²ΠΎΠΉ Π·Π°Π΄Π°ΡΠ΅