feat: webFrameMain.fromFrameToken (#47850)
* feat: webFrameMain.fromFrameToken * refactor: return null instead of undefined * docs: mention renderer webFrame property * chore: undo null->undefined in wfm.fromId api this will be updated in another pr
This commit is contained in:
parent
18af498cf1
commit
25e2459f31
5 changed files with 55 additions and 3 deletions
|
@ -1,7 +1,7 @@
|
|||
import { IpcMainImpl } from '@electron/internal/browser/ipc-main-impl';
|
||||
import { MessagePortMain } from '@electron/internal/browser/message-port-main';
|
||||
|
||||
const { WebFrameMain, fromId } = process._linkedBinding('electron_browser_web_frame_main');
|
||||
const { WebFrameMain, fromId, fromFrameToken } = process._linkedBinding('electron_browser_web_frame_main');
|
||||
|
||||
Object.defineProperty(WebFrameMain.prototype, 'ipc', {
|
||||
get () {
|
||||
|
@ -43,5 +43,6 @@ WebFrameMain.prototype.postMessage = function (...args) {
|
|||
};
|
||||
|
||||
export default {
|
||||
fromId
|
||||
fromId,
|
||||
fromFrameToken
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue