feat: [extensions] implement a couple of tabs APIs (#21779)

This commit is contained in:
Jeremy Apthorp 2020-01-15 15:11:51 -08:00 committed by GitHub
parent 8278a64e00
commit b9eb68c0b4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
21 changed files with 568 additions and 17 deletions

View file

@ -361,6 +361,7 @@ WebContents::WebContents(v8::Isolate* isolate,
#if BUILDFLAG(ENABLE_ELECTRON_EXTENSIONS)
extensions::AtomExtensionWebContentsObserver::CreateForWebContents(
web_contents);
script_executor_.reset(new extensions::ScriptExecutor(web_contents));
#endif
registry_.AddInterface(base::BindRepeating(&WebContents::BindElectronBrowser,
base::Unretained(this)));
@ -521,6 +522,7 @@ void WebContents::InitWithSessionAndOptions(
#if BUILDFLAG(ENABLE_ELECTRON_EXTENSIONS)
extensions::AtomExtensionWebContentsObserver::CreateForWebContents(
web_contents());
script_executor_.reset(new extensions::ScriptExecutor(web_contents()));
#endif
registry_.AddInterface(base::BindRepeating(&WebContents::BindElectronBrowser,