2018-10-24 11:24:11 -07:00
|
|
|
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
2018-09-20 17:30:26 -07:00
|
|
|
From: deepak1556 <hop2deep@gmail.com>
|
2019-06-03 20:44:12 -07:00
|
|
|
Date: Mon, 3 Jun 2019 14:20:05 -0700
|
2018-09-20 17:30:26 -07:00
|
|
|
Subject: frame_host_manager.patch
|
|
|
|
|
2021-04-22 10:55:32 -07:00
|
|
|
Allows embedder to intercept site instances created by chromium.
|
2018-09-20 17:30:26 -07:00
|
|
|
|
2020-09-21 01:00:36 -07:00
|
|
|
diff --git a/content/browser/renderer_host/render_frame_host_manager.cc b/content/browser/renderer_host/render_frame_host_manager.cc
|
2024-03-15 14:03:42 -04:00
|
|
|
index 91521d844841ba42cc98b98ec646e0a36f2cc393..62a069836bc680bd82559eaa1eb5a7f14d3597c1 100644
|
2020-09-21 01:00:36 -07:00
|
|
|
--- a/content/browser/renderer_host/render_frame_host_manager.cc
|
|
|
|
+++ b/content/browser/renderer_host/render_frame_host_manager.cc
|
2024-03-15 14:03:42 -04:00
|
|
|
@@ -4290,6 +4290,9 @@ RenderFrameHostManager::GetSiteInstanceForNavigationRequest(
|
2020-03-03 13:35:05 -08:00
|
|
|
request->ResetStateForSiteInstanceChange();
|
|
|
|
}
|
2018-12-05 09:03:39 +01:00
|
|
|
|
|
|
|
+ GetContentClient()->browser()->RegisterPendingSiteInstance(
|
|
|
|
+ render_frame_host_.get(), dest_site_instance.get());
|
|
|
|
+
|
|
|
|
return dest_site_instance;
|
|
|
|
}
|
|
|
|
|
2018-09-13 22:02:16 -07:00
|
|
|
diff --git a/content/public/browser/content_browser_client.h b/content/public/browser/content_browser_client.h
|
2024-03-15 14:03:42 -04:00
|
|
|
index b777041ec1111444d690d1d188dd622ce4677d4c..7541c01f350b41e5b69a6d91f6ab10409615f2a8 100644
|
2018-09-13 22:02:16 -07:00
|
|
|
--- a/content/public/browser/content_browser_client.h
|
|
|
|
+++ b/content/public/browser/content_browser_client.h
|
2024-03-05 11:47:48 -05:00
|
|
|
@@ -308,6 +308,11 @@ class CONTENT_EXPORT ContentBrowserClient {
|
2020-01-17 10:41:52 -08:00
|
|
|
|
2020-12-22 14:14:44 -08:00
|
|
|
virtual ~ContentBrowserClient() = default;
|
2018-09-13 22:02:16 -07:00
|
|
|
|
2018-12-05 09:03:39 +01:00
|
|
|
+ // Electron: Registers a pending site instance during a navigation.
|
|
|
|
+ virtual void RegisterPendingSiteInstance(
|
|
|
|
+ content::RenderFrameHost* rfh,
|
2019-02-26 17:43:34 -08:00
|
|
|
+ content::SiteInstance* pending_site_instance) {}
|
2018-09-13 22:02:16 -07:00
|
|
|
+
|
|
|
|
// Allows the embedder to set any number of custom BrowserMainParts
|
|
|
|
// implementations for the browser startup code. See comments in
|
|
|
|
// browser_main_parts.h.
|