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