feat: add webContents.fromDevToolsTargetId() (#29399)
* feat: add webContents.fromDevToolsTargetId() * refactor: avoid using FromOrCreate
This commit is contained in:
parent
96131af5d3
commit
352ac21413
4 changed files with 53 additions and 0 deletions
|
@ -769,6 +769,10 @@ export function fromId (id: string) {
|
|||
return binding.fromId(id);
|
||||
}
|
||||
|
||||
export function fromDevToolsTargetId (targetId: string) {
|
||||
return binding.fromDevToolsTargetId(targetId);
|
||||
}
|
||||
|
||||
export function getFocusedWebContents () {
|
||||
let focused = null;
|
||||
for (const contents of binding.getAllWebContents()) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue