|
@@ -263,33 +263,6 @@ void ElectronSandboxedRendererClient::SetupMainWorldOverrides(
|
|
|
&isolated_bundle_params, &isolated_bundle_args, nullptr);
|
|
|
}
|
|
|
|
|
|
-void ElectronSandboxedRendererClient::SetupExtensionWorldOverrides(
|
|
|
- v8::Handle<v8::Context> context,
|
|
|
- content::RenderFrame* render_frame,
|
|
|
- int world_id) {
|
|
|
-#if BUILDFLAG(ENABLE_ELECTRON_EXTENSIONS)
|
|
|
- NOTREACHED();
|
|
|
-#else
|
|
|
- auto* isolate = context->GetIsolate();
|
|
|
-
|
|
|
- gin_helper::Dictionary process = gin::Dictionary::CreateEmpty(isolate);
|
|
|
- process.SetMethod("_linkedBinding", GetBinding);
|
|
|
-
|
|
|
- std::vector<v8::Local<v8::String>> isolated_bundle_params = {
|
|
|
- node::FIXED_ONE_BYTE_STRING(isolate, "nodeProcess"),
|
|
|
- node::FIXED_ONE_BYTE_STRING(isolate, "isolatedWorld"),
|
|
|
- node::FIXED_ONE_BYTE_STRING(isolate, "worldId")};
|
|
|
-
|
|
|
- std::vector<v8::Local<v8::Value>> isolated_bundle_args = {
|
|
|
- process.GetHandle(),
|
|
|
- GetContext(render_frame->GetWebFrame(), isolate)->Global(),
|
|
|
- v8::Integer::New(isolate, world_id)};
|
|
|
-
|
|
|
- util::CompileAndCall(context, "electron/js2c/content_script_bundle",
|
|
|
- &isolated_bundle_params, &isolated_bundle_args, nullptr);
|
|
|
-#endif
|
|
|
-}
|
|
|
-
|
|
|
void ElectronSandboxedRendererClient::WillReleaseScriptContext(
|
|
|
v8::Handle<v8::Context> context,
|
|
|
content::RenderFrame* render_frame) {
|