chore: bump chromium to 92.0.4499.0 (master) (#29046)
This commit is contained in:
parent
cbba602eae
commit
d5f2eb5a81
56 changed files with 162 additions and 148 deletions
2
DEPS
2
DEPS
|
@ -14,7 +14,7 @@ gclient_gn_args = [
|
|||
|
||||
vars = {
|
||||
'chromium_version':
|
||||
'92.0.4498.0',
|
||||
'92.0.4499.0',
|
||||
'node_version':
|
||||
'v14.16.1',
|
||||
'nan_version':
|
||||
|
|
|
@ -158,7 +158,7 @@ class ProcessSingleton {
|
|||
|
||||
// Function to call when the other process is hung and needs to be killed.
|
||||
// Allows overriding for tests.
|
||||
base::Callback<void(int)> kill_callback_;
|
||||
base::RepeatingCallback<void(int)> kill_callback_;
|
||||
|
||||
// Path in file system to the socket.
|
||||
base::FilePath socket_path_;
|
||||
|
|
|
@ -23,10 +23,10 @@ index fa860cddc22da75967796674e9b467f8c726a368..730c7ddd2838eb50f6f5f0676f0f16f7
|
|||
int32_t world_id) {}
|
||||
virtual void DidClearWindowObject() {}
|
||||
diff --git a/content/renderer/render_frame_impl.cc b/content/renderer/render_frame_impl.cc
|
||||
index eaac22ff3405d1d53b05285ab4018090cca1570f..2d0d35843ee2ed2e13c053790fdbfd625a9a0071 100644
|
||||
index 50504820638367fc32e42583edad4f68d62a2526..abcfd464b8a92f65623bc4527123cc75ad38b712 100644
|
||||
--- a/content/renderer/render_frame_impl.cc
|
||||
+++ b/content/renderer/render_frame_impl.cc
|
||||
@@ -4150,6 +4150,12 @@ void RenderFrameImpl::DidCreateScriptContext(v8::Local<v8::Context> context,
|
||||
@@ -4146,6 +4146,12 @@ void RenderFrameImpl::DidCreateScriptContext(v8::Local<v8::Context> context,
|
||||
observer.DidCreateScriptContext(context, world_id);
|
||||
}
|
||||
|
||||
|
|
|
@ -10,10 +10,10 @@ valid use cases for setting custom exit codes of the main loop. This
|
|||
exposes a simple setter that embedders can call.
|
||||
|
||||
diff --git a/content/browser/browser_main_loop.h b/content/browser/browser_main_loop.h
|
||||
index e116a3de7fb765758793b3feecab2654193c3a96..0131d97a8b82d2339c99d1b1c6c3faeba2ae35ff 100644
|
||||
index 69b091698f04209af113af6c586ec8615ff52d41..c54ad51b6cf4b48c522ae79091697b5efa50673c 100644
|
||||
--- a/content/browser/browser_main_loop.h
|
||||
+++ b/content/browser/browser_main_loop.h
|
||||
@@ -167,6 +167,10 @@ class CONTENT_EXPORT BrowserMainLoop {
|
||||
@@ -168,6 +168,10 @@ class CONTENT_EXPORT BrowserMainLoop {
|
||||
|
||||
int GetResultCode() const { return result_code_; }
|
||||
|
||||
|
|
|
@ -9,10 +9,10 @@ potentially prevent a window from being created.
|
|||
TODO(loc): this patch is currently broken.
|
||||
|
||||
diff --git a/content/browser/renderer_host/render_frame_host_impl.cc b/content/browser/renderer_host/render_frame_host_impl.cc
|
||||
index 80e4a073dc34ee6eeca411afb663477941b2ebca..e881cd42b45d2100749c270e5abfc12664329051 100644
|
||||
index 3925d8f312ea132e0edbc610d61588af5686e2d4..f2f31f6f954b560a3c3e31dc2233292b00c21b80 100644
|
||||
--- a/content/browser/renderer_host/render_frame_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_frame_host_impl.cc
|
||||
@@ -5575,6 +5575,7 @@ void RenderFrameHostImpl::CreateNewWindow(
|
||||
@@ -5586,6 +5586,7 @@ void RenderFrameHostImpl::CreateNewWindow(
|
||||
last_committed_origin_, params->window_container_type,
|
||||
params->target_url, params->referrer.To<Referrer>(),
|
||||
params->frame_name, params->disposition, *params->features,
|
||||
|
@ -21,7 +21,7 @@ index 80e4a073dc34ee6eeca411afb663477941b2ebca..e881cd42b45d2100749c270e5abfc126
|
|||
&no_javascript_access);
|
||||
|
||||
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
|
||||
index cee128d842b530dfe00dbd6b7aa1a977fe623d83..6acb183b87ebcfb5d769517985b691b9969bb6e6 100644
|
||||
index 24f086e5798930a888ca2f78d9c36c93e046261b..b1cbf6f76c2032dd3a6c90f1c9cf97ccaa734bec 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.cc
|
||||
+++ b/content/browser/web_contents/web_contents_impl.cc
|
||||
@@ -3649,6 +3649,14 @@ RenderFrameHostDelegate* WebContentsImpl::CreateNewWindow(
|
||||
|
@ -150,7 +150,7 @@ index b1cfa654259d431adfada00a00f9bfc8ae5ab292..484d36de2ac0ef3b1d19bbd0d6c79db8
|
|||
// typically happens when popups are created.
|
||||
virtual void WebContentsCreated(WebContents* source_contents,
|
||||
diff --git a/content/renderer/render_view_impl.cc b/content/renderer/render_view_impl.cc
|
||||
index 386a38dd82433a53b82c0d35de44fdfbfce87b89..b24bbf95e879b1e04d686d703340c978d7f33bba 100644
|
||||
index bb60e5d711ab45f89c401f4c053e453a324f6881..fbe1312f13f799b4c1b3dbc663fde81fe64162c8 100644
|
||||
--- a/content/renderer/render_view_impl.cc
|
||||
+++ b/content/renderer/render_view_impl.cc
|
||||
@@ -27,6 +27,7 @@
|
||||
|
@ -161,7 +161,7 @@ index 386a38dd82433a53b82c0d35de44fdfbfce87b89..b24bbf95e879b1e04d686d703340c978
|
|||
#include "third_party/blink/public/web/modules/mediastream/web_media_stream_device_observer.h"
|
||||
#include "third_party/blink/public/web/web_frame_widget.h"
|
||||
#include "third_party/blink/public/web/web_local_frame.h"
|
||||
@@ -326,6 +327,10 @@ WebView* RenderViewImpl::CreateView(
|
||||
@@ -317,6 +318,10 @@ WebView* RenderViewImpl::CreateView(
|
||||
params->impression = blink::ConvertWebImpressionToImpression(*impression);
|
||||
}
|
||||
|
||||
|
|
|
@ -264,7 +264,7 @@ index c5c5a7b63b5b3b62a9517cbef3ae23ce57a3c89c..4f1b7e88d6d2ae89a60311c8aeb1fcee
|
|||
void AddNewContents(content::WebContents* source,
|
||||
std::unique_ptr<content::WebContents> new_contents,
|
||||
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
|
||||
index 2426eb615967cbe3d11ece998d97d63266fac184..f4c8d9e8a20f9be8c6566857fcf1d57ba7ec1af7 100644
|
||||
index 54fce2b0b6da947473e8725bf97816de9f51b12a..aa50664e5fcb88ac72118ba5d354f835d427b6fd 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.cc
|
||||
+++ b/content/browser/web_contents/web_contents_impl.cc
|
||||
@@ -3601,8 +3601,7 @@ RenderFrameHostDelegate* WebContentsImpl::CreateNewWindow(
|
||||
|
@ -404,7 +404,7 @@ index 4e4b37cc0fbbcf8f630a4e928c957261e9a03603..610848b09bba4dfa7dd645ca62354930
|
|||
->options()
|
||||
->block_new_web_contents();
|
||||
diff --git a/ui/views/controls/webview/web_dialog_view.cc b/ui/views/controls/webview/web_dialog_view.cc
|
||||
index 9b312a0604c38ea95f03b0ef9885ebaf08ed896c..87d57b3be4609dd1847620d58cb8b61a29114b89 100644
|
||||
index cd3f3c8849060fec8d9612d26c6c34caeefb3995..1ed386fd54918b24ebc81d6c2524e5d1fe02a655 100644
|
||||
--- a/ui/views/controls/webview/web_dialog_view.cc
|
||||
+++ b/ui/views/controls/webview/web_dialog_view.cc
|
||||
@@ -429,8 +429,7 @@ bool WebDialogView::IsWebContentsCreationOverridden(
|
||||
|
@ -418,7 +418,7 @@ index 9b312a0604c38ea95f03b0ef9885ebaf08ed896c..87d57b3be4609dd1847620d58cb8b61a
|
|||
return delegate_->HandleShouldOverrideWebContentsCreation();
|
||||
return false;
|
||||
diff --git a/ui/views/controls/webview/web_dialog_view.h b/ui/views/controls/webview/web_dialog_view.h
|
||||
index 8c5edd6b46b828bba2422ae11e451625ee4e6894..cc4a53e149fab62a72b321c9a3ec994fb9d87622 100644
|
||||
index 96896f5600495ff89b5209bb8cd72d7add6b404a..7df417f0509ddd993fa11bf6fb23ae68886d8008 100644
|
||||
--- a/ui/views/controls/webview/web_dialog_view.h
|
||||
+++ b/ui/views/controls/webview/web_dialog_view.h
|
||||
@@ -159,8 +159,7 @@ class WEBVIEW_EXPORT WebDialogView : public ClientView,
|
||||
|
|
|
@ -7,10 +7,10 @@ spellchecker uses a few IDS_ resources. We need to load these from
|
|||
Electrons grit header instead of Chromes
|
||||
|
||||
diff --git a/chrome/browser/BUILD.gn b/chrome/browser/BUILD.gn
|
||||
index c2359837f08332d18ac81f81f1b4d4e0728292b8..39e37edfe9d98630595e300ae000e920cfe4236b 100644
|
||||
index c0ba41010a64873c240acb337a69c0a1c2b69ccb..fb937c7d0aaf06b7120c1549cf15d6e18ac89be2 100644
|
||||
--- a/chrome/browser/BUILD.gn
|
||||
+++ b/chrome/browser/BUILD.gn
|
||||
@@ -6282,6 +6282,7 @@ static_library("browser") {
|
||||
@@ -6292,6 +6292,7 @@ static_library("browser") {
|
||||
deps += [
|
||||
"//components/spellcheck/browser",
|
||||
"//components/spellcheck/common",
|
||||
|
|
|
@ -7,10 +7,10 @@ Disable persiste licence support check for widevine cdm,
|
|||
as its not supported in the current version of chrome.
|
||||
|
||||
diff --git a/chrome/renderer/media/chrome_key_systems.cc b/chrome/renderer/media/chrome_key_systems.cc
|
||||
index 6a539eb21f8ba381fd3fe6fddc21e499befbd8a9..d7b9ef789d684c58013179b25cd40569ff773249 100644
|
||||
index 0ccd5815839ff3bc3b05e76241959912f0730b6b..36cecfb80de305a93e6dd4aef087f169630fa502 100644
|
||||
--- a/chrome/renderer/media/chrome_key_systems.cc
|
||||
+++ b/chrome/renderer/media/chrome_key_systems.cc
|
||||
@@ -15,7 +15,9 @@
|
||||
@@ -16,7 +16,9 @@
|
||||
#include "base/strings/utf_string_conversions.h"
|
||||
#include "build/build_config.h"
|
||||
#include "build/chromeos_buildflags.h"
|
||||
|
@ -20,7 +20,7 @@ index 6a539eb21f8ba381fd3fe6fddc21e499befbd8a9..d7b9ef789d684c58013179b25cd40569
|
|||
#include "components/cdm/renderer/external_clear_key_key_system_properties.h"
|
||||
#include "components/cdm/renderer/widevine_key_system_properties.h"
|
||||
#include "content/public/renderer/render_thread.h"
|
||||
@@ -200,12 +202,14 @@ static SupportedCodecs GetSupportedCodecs(
|
||||
@@ -201,12 +203,14 @@ static SupportedCodecs GetSupportedCodecs(
|
||||
// Returns persistent-license session support.
|
||||
static EmeSessionTypeSupport GetPersistentLicenseSupport(
|
||||
bool supported_by_the_cdm) {
|
||||
|
|
|
@ -17,10 +17,10 @@ only one or two specific checks fail. Then it's better to simply comment out the
|
|||
failing checks and allow the rest of the target to have them enabled.
|
||||
|
||||
diff --git a/content/browser/renderer_host/navigation_controller_impl.cc b/content/browser/renderer_host/navigation_controller_impl.cc
|
||||
index a1a67daa21f93a8e19ee57ea007967e9a0735c18..d826fc5bacf7966e3f910572dd6b0f63de25089d 100644
|
||||
index 814eebf4b641fe01a29875b9c06aea84b2ab7206..892039c0481c0c66cefbff6a37bf51fe1ae61c6b 100644
|
||||
--- a/content/browser/renderer_host/navigation_controller_impl.cc
|
||||
+++ b/content/browser/renderer_host/navigation_controller_impl.cc
|
||||
@@ -1417,8 +1417,10 @@ NavigationType NavigationControllerImpl::ClassifyNavigation(
|
||||
@@ -1416,8 +1416,10 @@ NavigationType NavigationControllerImpl::ClassifyNavigation(
|
||||
return NAVIGATION_TYPE_NEW_SUBFRAME;
|
||||
}
|
||||
|
||||
|
@ -33,7 +33,7 @@ index a1a67daa21f93a8e19ee57ea007967e9a0735c18..d826fc5bacf7966e3f910572dd6b0f63
|
|||
|
||||
if (rfh->GetParent()) {
|
||||
// All manual subframes would be did_create_new_entry and handled above, so
|
||||
@@ -1733,7 +1735,10 @@ void NavigationControllerImpl::RendererDidNavigateToNewEntry(
|
||||
@@ -1732,7 +1734,10 @@ void NavigationControllerImpl::RendererDidNavigateToNewEntry(
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -241,10 +241,10 @@ index cbb30f8900ed07d5cccbf250f2f1e6fafb66b40e..411fabb7e8c3e2a1aceb9db0fefdc4c6
|
|||
sandbox::policy::switches::kGpuSandboxAllowSysVShm,
|
||||
sandbox::policy::switches::kGpuSandboxFailuresFatal,
|
||||
diff --git a/content/browser/renderer_host/render_process_host_impl.cc b/content/browser/renderer_host/render_process_host_impl.cc
|
||||
index 43ad6054fc9c310fb78f8e718a91d29cfcc797d8..635ac52ba7615aa2dbe0c728c274c8027e651b7c 100644
|
||||
index 4208521cf4f03a154f44d5bd925f1cc12c306e20..541125c33491201b660ec06da202619219c527c1 100644
|
||||
--- a/content/browser/renderer_host/render_process_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_process_host_impl.cc
|
||||
@@ -211,6 +211,7 @@
|
||||
@@ -210,6 +210,7 @@
|
||||
#include "ui/accessibility/accessibility_switches.h"
|
||||
#include "ui/base/ui_base_switches.h"
|
||||
#include "ui/display/display_switches.h"
|
||||
|
@ -252,7 +252,7 @@ index 43ad6054fc9c310fb78f8e718a91d29cfcc797d8..635ac52ba7615aa2dbe0c728c274c802
|
|||
#include "ui/gl/gl_switches.h"
|
||||
#include "ui/native_theme/native_theme_features.h"
|
||||
#include "url/origin.h"
|
||||
@@ -3200,6 +3201,7 @@ void RenderProcessHostImpl::PropagateBrowserCommandLineToRenderer(
|
||||
@@ -3199,6 +3200,7 @@ void RenderProcessHostImpl::PropagateBrowserCommandLineToRenderer(
|
||||
// Propagate the following switches to the renderer command line (along
|
||||
// with any associated values) if present in the browser command line.
|
||||
static const char* const kSwitchNames[] = {
|
||||
|
|
|
@ -6,10 +6,10 @@ Subject: disable_hidden.patch
|
|||
Electron uses this to disable background throttling for hidden windows.
|
||||
|
||||
diff --git a/content/browser/renderer_host/render_widget_host_impl.cc b/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
index 7aaea0969a47e0e34e529863867e0a0a7b586692..06524496cdad2dfecc8a7cba98a44eac4fa87101 100644
|
||||
index 252e7992b8d9376779cb8b59aae2dc12e1e3c0ba..ac6e92d1dab80d2e9d3a48ac419102b93615d7a9 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
@@ -712,6 +712,9 @@ void RenderWidgetHostImpl::WasHidden() {
|
||||
@@ -711,6 +711,9 @@ void RenderWidgetHostImpl::WasHidden() {
|
||||
if (is_hidden_)
|
||||
return;
|
||||
|
||||
|
@ -34,7 +34,7 @@ index 81c55683ea0c08bc87487b7d0bd45160634d3aa3..bb1b37ae5cb6fce48aaa7a8e9e636a7b
|
|||
// |routing_id| must not be MSG_ROUTING_NONE.
|
||||
// If this object outlives |delegate|, DetachDelegate() must be called when
|
||||
diff --git a/content/browser/renderer_host/render_widget_host_view_aura.cc b/content/browser/renderer_host/render_widget_host_view_aura.cc
|
||||
index c3f4bf477f30bd441a42f00e90f05523f737f072..7839107b2143afd4268d1028ec2fe0dfb104b7b5 100644
|
||||
index 606051acbdc77167d4b44d4990b1e52c6acf27f8..42e8390aed5dd0b7a7dad0069db3b5c9bb0faebf 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_view_aura.cc
|
||||
+++ b/content/browser/renderer_host/render_widget_host_view_aura.cc
|
||||
@@ -595,7 +595,7 @@ void RenderWidgetHostViewAura::HideImpl() {
|
||||
|
|
|
@ -24,10 +24,10 @@ This patch temporarily disables the metrics so we can have green CI, and we
|
|||
should continue seeking for a real fix.
|
||||
|
||||
diff --git a/content/browser/renderer_host/navigator.cc b/content/browser/renderer_host/navigator.cc
|
||||
index bc2d7c7f00b2da0e32d48a2d85aeec81ee2c15aa..a69821a91841a6e28e983307bf46ca698db2a374 100644
|
||||
index e494a067dc20f2a4d95a62c3570b017f523f42bf..d2d36ed49b408c55834cfc84b5122ba6b2864459 100644
|
||||
--- a/content/browser/renderer_host/navigator.cc
|
||||
+++ b/content/browser/renderer_host/navigator.cc
|
||||
@@ -1079,6 +1079,7 @@ void Navigator::RecordNavigationMetrics(
|
||||
@@ -1078,6 +1078,7 @@ void Navigator::RecordNavigationMetrics(
|
||||
.InMilliseconds());
|
||||
}
|
||||
|
||||
|
@ -35,7 +35,7 @@ index bc2d7c7f00b2da0e32d48a2d85aeec81ee2c15aa..a69821a91841a6e28e983307bf46ca69
|
|||
// If this is a same-process navigation and we have timestamps for unload
|
||||
// durations, fill those metrics out as well.
|
||||
if (params.unload_start && params.unload_end &&
|
||||
@@ -1125,6 +1126,7 @@ void Navigator::RecordNavigationMetrics(
|
||||
@@ -1124,6 +1125,7 @@ void Navigator::RecordNavigationMetrics(
|
||||
first_before_unload_start_time)
|
||||
.InMilliseconds());
|
||||
}
|
||||
|
|
|
@ -11,10 +11,10 @@ This regressed in https://chromium-review.googlesource.com/c/chromium/src/+/2572
|
|||
Upstream: https://chromium-review.googlesource.com/c/chromium/src/+/2598393
|
||||
|
||||
diff --git a/content/renderer/render_frame_impl.cc b/content/renderer/render_frame_impl.cc
|
||||
index f4abb34513e76cf76deb58810b1b4d9387ac0fec..dbe005d4b0e3eba3f4f94493324681b55818e0e3 100644
|
||||
index 33fe8d118ced62aaba2c81ade206382395630086..9dccdd341860cfe7ee6038a99482d97fe0ffb3e6 100644
|
||||
--- a/content/renderer/render_frame_impl.cc
|
||||
+++ b/content/renderer/render_frame_impl.cc
|
||||
@@ -2286,7 +2286,7 @@ blink::WebLocalFrame* RenderFrameImpl::GetWebFrame() {
|
||||
@@ -2282,7 +2282,7 @@ blink::WebLocalFrame* RenderFrameImpl::GetWebFrame() {
|
||||
}
|
||||
|
||||
const blink::web_pref::WebPreferences& RenderFrameImpl::GetBlinkPreferences() {
|
||||
|
|
|
@ -33,7 +33,7 @@ index 0ccfe130f00ec3b6c75cd8ee04d5a2777e1fd00c..653829457d58bf92057cc36aa8a28970
|
|||
DISALLOW_COPY_AND_ASSIGN(StaticHttpUserAgentSettings);
|
||||
};
|
||||
diff --git a/services/network/network_context.cc b/services/network/network_context.cc
|
||||
index 18f9a7c1277653a4a9e0bd2303d57f40fe5f288a..0344da1de5df9ffec6e71669e3115b138420ec9e 100644
|
||||
index fa84ecca47caf78174e9f588d2a1c1f65ebb157d..8bfe1d73ee5cd3d32b9190585747faeea483fcfb 100644
|
||||
--- a/services/network/network_context.cc
|
||||
+++ b/services/network/network_context.cc
|
||||
@@ -1140,6 +1140,13 @@ void NetworkContext::SetNetworkConditions(
|
||||
|
|
|
@ -6,10 +6,10 @@ Subject: feat: allow disabling blink scheduler throttling per RenderView
|
|||
This allows us to disable throttling for hidden windows.
|
||||
|
||||
diff --git a/content/browser/renderer_host/render_view_host_impl.cc b/content/browser/renderer_host/render_view_host_impl.cc
|
||||
index 756ad32666dcf1be906e348706af4b1dbdb1bb92..c0dd093e9e396af70f7b5f7003f1e6599fa6b870 100644
|
||||
index ba94f41600d2caf5beafa4aa83127bf1cf868a72..95d0dc410cb2ae4eaedbf28435786f7dc267db59 100644
|
||||
--- a/content/browser/renderer_host/render_view_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_view_host_impl.cc
|
||||
@@ -612,6 +612,11 @@ void RenderViewHostImpl::SetBackgroundOpaque(bool opaque) {
|
||||
@@ -611,6 +611,11 @@ void RenderViewHostImpl::SetBackgroundOpaque(bool opaque) {
|
||||
GetWidget()->GetAssociatedFrameWidget()->SetBackgroundOpaque(opaque);
|
||||
}
|
||||
|
||||
|
@ -48,10 +48,10 @@ index 9f1acca2bdb697b79a01362a9a5d8dd098eca925..c57c03b838a773d41614002afee27520
|
|||
// This interface should only be implemented inside content.
|
||||
friend class RenderViewHostImpl;
|
||||
diff --git a/content/renderer/render_view_impl.h b/content/renderer/render_view_impl.h
|
||||
index 1d8ffde83fa97ff516e2cbc2add520da7b955750..4db10afe645a36ccac56d9afda95fd1fb3eaadf7 100644
|
||||
index b855cc7ce85117b3b32fe097b4c209ed5302e041..66456189bb90f2002682308a0ec83dc709d3cc72 100644
|
||||
--- a/content/renderer/render_view_impl.h
|
||||
+++ b/content/renderer/render_view_impl.h
|
||||
@@ -211,6 +211,8 @@ class CONTENT_EXPORT RenderViewImpl : public blink::WebViewClient,
|
||||
@@ -206,6 +206,8 @@ class CONTENT_EXPORT RenderViewImpl : public blink::WebViewClient,
|
||||
static WindowOpenDisposition NavigationPolicyToDisposition(
|
||||
blink::WebNavigationPolicy policy);
|
||||
|
||||
|
|
|
@ -8,7 +8,7 @@ we invoke it in order to expose contents.decrementCapturerCount([stayHidden, sta
|
|||
to users. We should try to upstream this.
|
||||
|
||||
diff --git a/content/browser/web_contents/web_contents_impl.h b/content/browser/web_contents/web_contents_impl.h
|
||||
index 860301d6374687ab8f155e5091aba6239c37af35..8b5e624cf456241c7649456ea92716e8233f4c0f 100644
|
||||
index e66c762b5093e7154920b7df8638733bd146f535..46cc6cfd3c5b9ca14321bdf4c94a7126edec6eb5 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.h
|
||||
+++ b/content/browser/web_contents/web_contents_impl.h
|
||||
@@ -1736,9 +1736,11 @@ class CONTENT_EXPORT WebContentsImpl : public WebContents,
|
||||
|
|
|
@ -6,10 +6,10 @@ Subject: frame_host_manager.patch
|
|||
Allows embedder to intercept site instances created by chromium.
|
||||
|
||||
diff --git a/content/browser/renderer_host/render_frame_host_manager.cc b/content/browser/renderer_host/render_frame_host_manager.cc
|
||||
index f2ccdb02af3278fe955ca1658f4cc50b90e81637..3a4abaad35285b9bf7e9bd77293ca0b2b982f15b 100644
|
||||
index 3bd26f70aa00f051de7eae7ec94a56aaf018514d..4b766ad4055afc09b5f0287ffc3d3b4d8a74599f 100644
|
||||
--- a/content/browser/renderer_host/render_frame_host_manager.cc
|
||||
+++ b/content/browser/renderer_host/render_frame_host_manager.cc
|
||||
@@ -2922,6 +2922,9 @@ RenderFrameHostManager::GetSiteInstanceForNavigationRequest(
|
||||
@@ -2921,6 +2921,9 @@ RenderFrameHostManager::GetSiteInstanceForNavigationRequest(
|
||||
request->ResetStateForSiteInstanceChange();
|
||||
}
|
||||
|
||||
|
|
|
@ -170,10 +170,10 @@ index e99a5a11a5f48b985aa3cc28eae2c53eec34a518..3e7d3dbd8fd39a3554d91bd15c567b8f
|
|||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
diff --git a/ui/base/BUILD.gn b/ui/base/BUILD.gn
|
||||
index 2bcb3fd35fd4505ee29d5030ce9434cbf23a8447..3990639fa204ec44a3d4e49ee200337bed86f53c 100644
|
||||
index 195e6a88cb0612cedb4b228e10fc5660b5440be2..75250a4b9cb661d9fbea3580a50ff214b1b9510e 100644
|
||||
--- a/ui/base/BUILD.gn
|
||||
+++ b/ui/base/BUILD.gn
|
||||
@@ -314,6 +314,13 @@ component("base") {
|
||||
@@ -324,6 +324,13 @@ component("base") {
|
||||
]
|
||||
}
|
||||
|
||||
|
|
|
@ -7,7 +7,7 @@ This adds a callback from the network service that's used to implement
|
|||
session.setCertificateVerifyCallback.
|
||||
|
||||
diff --git a/services/network/network_context.cc b/services/network/network_context.cc
|
||||
index eeadeb1b81259e81e73a0a31080c2803c0e84f0c..18f9a7c1277653a4a9e0bd2303d57f40fe5f288a 100644
|
||||
index 482d6022fd5076f55d339684e07d556e4cb3f220..fa84ecca47caf78174e9f588d2a1c1f65ebb157d 100644
|
||||
--- a/services/network/network_context.cc
|
||||
+++ b/services/network/network_context.cc
|
||||
@@ -117,6 +117,11 @@
|
||||
|
@ -116,7 +116,7 @@ index eeadeb1b81259e81e73a0a31080c2803c0e84f0c..18f9a7c1277653a4a9e0bd2303d57f40
|
|||
void NetworkContext::CreateURLLoaderFactory(
|
||||
mojo::PendingReceiver<mojom::URLLoaderFactory> receiver,
|
||||
mojom::URLLoaderFactoryParamsPtr params) {
|
||||
@@ -1931,6 +2016,9 @@ URLRequestContextOwner NetworkContext::MakeURLRequestContext(
|
||||
@@ -1933,6 +2018,9 @@ URLRequestContextOwner NetworkContext::MakeURLRequestContext(
|
||||
std::move(cert_verifier));
|
||||
cert_verifier = base::WrapUnique(cert_verifier_with_trust_anchors_);
|
||||
#endif // BUILDFLAG(IS_CHROMEOS_ASH)
|
||||
|
|
|
@ -108,10 +108,10 @@ index 71dad766e05ac4726e1e18159f2af5ea01079a91..ef8e55a4420288fe64c99e68d0a649a9
|
|||
const GURL& document_url,
|
||||
mojo::PendingReceiver<blink::mojom::NotificationService> receiver);
|
||||
diff --git a/content/browser/renderer_host/render_process_host_impl.cc b/content/browser/renderer_host/render_process_host_impl.cc
|
||||
index d94dbfafeb8a87434a4df8db5286527bb20cfdd6..1a01a7264f7a89c6b6f1d4e903333718adfbeb2d 100644
|
||||
index 6eee013d0401a7507cdcc0773ab0d9418c86b5c4..2afda54851efbb052371ce1e49f29cc56e93dce4 100644
|
||||
--- a/content/browser/renderer_host/render_process_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_process_host_impl.cc
|
||||
@@ -2161,7 +2161,7 @@ void RenderProcessHostImpl::CreateNotificationService(
|
||||
@@ -2160,7 +2160,7 @@ void RenderProcessHostImpl::CreateNotificationService(
|
||||
document_url = rfh->GetLastCommittedURL();
|
||||
|
||||
storage_partition_impl_->GetPlatformNotificationContext()->CreateService(
|
||||
|
|
|
@ -9,7 +9,7 @@ don't get errors for Chrome's generated resources, which are non-existent
|
|||
because we don't generate them in our build.
|
||||
|
||||
diff --git a/chrome/browser/ui/views/overlay/back_to_tab_image_button.cc b/chrome/browser/ui/views/overlay/back_to_tab_image_button.cc
|
||||
index 9c861140fec428cd6d3f0375e81d91d94b0444b6..f9dd34d2ad342b507e2b40298fbd8221fbbf14e3 100644
|
||||
index 3afa0d34a6aff1d8882592fc4a3720698124a9c4..18de9f4e9c3c9599d1ab83a638bbd887b9f7cc59 100644
|
||||
--- a/chrome/browser/ui/views/overlay/back_to_tab_image_button.cc
|
||||
+++ b/chrome/browser/ui/views/overlay/back_to_tab_image_button.cc
|
||||
@@ -5,7 +5,7 @@
|
||||
|
@ -19,10 +19,10 @@ index 9c861140fec428cd6d3f0375e81d91d94b0444b6..f9dd34d2ad342b507e2b40298fbd8221
|
|||
-#include "chrome/grit/generated_resources.h"
|
||||
+#include "electron/grit/electron_resources.h"
|
||||
#include "ui/base/l10n/l10n_util.h"
|
||||
#include "ui/base/metadata/metadata_impl_macros.h"
|
||||
#include "ui/gfx/color_palette.h"
|
||||
#include "ui/gfx/paint_vector_icon.h"
|
||||
diff --git a/chrome/browser/ui/views/overlay/close_image_button.cc b/chrome/browser/ui/views/overlay/close_image_button.cc
|
||||
index 28c00fd4f326dd7d5efa839cd7540e2f9f824904..98e77d49684ab6a267cf80122c9a9a79cea377ac 100644
|
||||
index b40d96b754118c1dd1f1fb62f441a5a870d16ed9..7e205e324f5a8604ae6624c42b5b216e3070c072 100644
|
||||
--- a/chrome/browser/ui/views/overlay/close_image_button.cc
|
||||
+++ b/chrome/browser/ui/views/overlay/close_image_button.cc
|
||||
@@ -6,7 +6,7 @@
|
||||
|
@ -32,8 +32,8 @@ index 28c00fd4f326dd7d5efa839cd7540e2f9f824904..98e77d49684ab6a267cf80122c9a9a79
|
|||
-#include "chrome/grit/generated_resources.h"
|
||||
+#include "electron/grit/electron_resources.h"
|
||||
#include "ui/base/l10n/l10n_util.h"
|
||||
#include "ui/base/metadata/metadata_impl_macros.h"
|
||||
#include "ui/gfx/color_palette.h"
|
||||
#include "ui/gfx/paint_vector_icon.h"
|
||||
diff --git a/chrome/browser/ui/views/overlay/hang_up_button.cc b/chrome/browser/ui/views/overlay/hang_up_button.cc
|
||||
index 4b741d67c4c20766e248f0799825103ba4f2a1ce..adf85811da98e1666e8e93e5b339e176ecfe64e3 100644
|
||||
--- a/chrome/browser/ui/views/overlay/hang_up_button.cc
|
||||
|
@ -91,7 +91,7 @@ index c996365b075abf026b4c26bce0ec89668cf933b8..04c6218f5f59b2d0d3d8e005461fa016
|
|||
Browser* browser =
|
||||
chrome::FindBrowserWithWebContents(controller->GetWebContents());
|
||||
diff --git a/chrome/browser/ui/views/overlay/playback_image_button.cc b/chrome/browser/ui/views/overlay/playback_image_button.cc
|
||||
index b146450f115cec9717fdb9280ed894963a11c667..df0443d82ad9a42f6965387630ac3eb7231c4994 100644
|
||||
index ab1717bd630e8f143a2ba6dddfeb04bc95beb7fd..2cf5bcd690a9db84cb14c409f31a82da6a9c0348 100644
|
||||
--- a/chrome/browser/ui/views/overlay/playback_image_button.cc
|
||||
+++ b/chrome/browser/ui/views/overlay/playback_image_button.cc
|
||||
@@ -6,7 +6,7 @@
|
||||
|
@ -102,9 +102,9 @@ index b146450f115cec9717fdb9280ed894963a11c667..df0443d82ad9a42f6965387630ac3eb7
|
|||
+#include "electron/grit/electron_resources.h"
|
||||
#include "components/vector_icons/vector_icons.h"
|
||||
#include "ui/base/l10n/l10n_util.h"
|
||||
#include "ui/gfx/paint_vector_icon.h"
|
||||
#include "ui/base/metadata/metadata_impl_macros.h"
|
||||
diff --git a/chrome/browser/ui/views/overlay/resize_handle_button.cc b/chrome/browser/ui/views/overlay/resize_handle_button.cc
|
||||
index a3236fd87a096bebcd66a3d9c2525ba7ef8f15bf..0237ed5903abe4577d0a5a1850bb6e27a8d99010 100644
|
||||
index 375efc8f931b1bfd595265829e47c8187a8d8d39..080e652f2c3e88b9a082dbd8fef82c461311cd9c 100644
|
||||
--- a/chrome/browser/ui/views/overlay/resize_handle_button.cc
|
||||
+++ b/chrome/browser/ui/views/overlay/resize_handle_button.cc
|
||||
@@ -6,7 +6,7 @@
|
||||
|
@ -115,9 +115,9 @@ index a3236fd87a096bebcd66a3d9c2525ba7ef8f15bf..0237ed5903abe4577d0a5a1850bb6e27
|
|||
+#include "electron/grit/electron_resources.h"
|
||||
#include "ui/base/hit_test.h"
|
||||
#include "ui/base/l10n/l10n_util.h"
|
||||
#include "ui/gfx/color_palette.h"
|
||||
#include "ui/base/metadata/metadata_impl_macros.h"
|
||||
diff --git a/chrome/browser/ui/views/overlay/skip_ad_label_button.cc b/chrome/browser/ui/views/overlay/skip_ad_label_button.cc
|
||||
index e803c1d3bbee5407dcfdc7b5a73cae3fc403a0e6..7bddae5d23fb6f100809c27d3636ae7ea6ca5169 100644
|
||||
index 8153a0b667383374d787ce105c177eda0cdf2171..e5f33a4c43f2571669dd2bef2260e548e20be9b4 100644
|
||||
--- a/chrome/browser/ui/views/overlay/skip_ad_label_button.cc
|
||||
+++ b/chrome/browser/ui/views/overlay/skip_ad_label_button.cc
|
||||
@@ -5,7 +5,7 @@
|
||||
|
@ -127,8 +127,8 @@ index e803c1d3bbee5407dcfdc7b5a73cae3fc403a0e6..7bddae5d23fb6f100809c27d3636ae7e
|
|||
-#include "chrome/grit/generated_resources.h"
|
||||
+#include "electron/grit/electron_resources.h"
|
||||
#include "ui/base/l10n/l10n_util.h"
|
||||
#include "ui/base/metadata/metadata_impl_macros.h"
|
||||
#include "ui/gfx/color_palette.h"
|
||||
#include "ui/views/background.h"
|
||||
diff --git a/chrome/browser/ui/views/overlay/toggle_camera_button.cc b/chrome/browser/ui/views/overlay/toggle_camera_button.cc
|
||||
index a3cff2dfa906aa469abd5f12f3f70f0acea0adfe..93ad732afe209a9f51756112a5aa4f7dcd6a8b2e 100644
|
||||
--- a/chrome/browser/ui/views/overlay/toggle_camera_button.cc
|
||||
|
@ -156,7 +156,7 @@ index a681ba4ed2de3226b20c5e89361c4bec47dfb8ea..5cd85706018fe163d1e0a9e48e3b8a4b
|
|||
#include "ui/base/l10n/l10n_util.h"
|
||||
#include "ui/gfx/paint_vector_icon.h"
|
||||
diff --git a/chrome/browser/ui/views/overlay/track_image_button.cc b/chrome/browser/ui/views/overlay/track_image_button.cc
|
||||
index 8b9911c9819f334c9c634e986e6809ed6e1140c5..e8eb76a94a459bc293f47ad08099bc707527dd7b 100644
|
||||
index 4fceb3f5d802e7f01df59d1b3e9c80cc48af714a..70075228f6104b5a16f551af56eafc6829124143 100644
|
||||
--- a/chrome/browser/ui/views/overlay/track_image_button.cc
|
||||
+++ b/chrome/browser/ui/views/overlay/track_image_button.cc
|
||||
@@ -6,7 +6,7 @@
|
||||
|
@ -167,4 +167,4 @@ index 8b9911c9819f334c9c634e986e6809ed6e1140c5..e8eb76a94a459bc293f47ad08099bc70
|
|||
+#include "electron/grit/electron_resources.h"
|
||||
#include "components/vector_icons/vector_icons.h"
|
||||
#include "ui/base/l10n/l10n_util.h"
|
||||
#include "ui/gfx/paint_vector_icon.h"
|
||||
#include "ui/base/metadata/metadata_impl_macros.h"
|
||||
|
|
|
@ -30,10 +30,10 @@ index fb25b91e254ca03002fda226861ff5b9c24f6b11..752f5e26b4f60561f38f08a8ce10cbce
|
|||
// RenderWidgetHost on the main frame, and false otherwise.
|
||||
virtual bool IsWidgetForMainFrame(RenderWidgetHostImpl*);
|
||||
diff --git a/content/browser/renderer_host/render_widget_host_impl.cc b/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
index 06524496cdad2dfecc8a7cba98a44eac4fa87101..77cdeea65429b28bbb178d797406b7362c022624 100644
|
||||
index ac6e92d1dab80d2e9d3a48ac419102b93615d7a9..b56b5031abacad5e3d7c575097999845f4efd3e1 100644
|
||||
--- a/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_widget_host_impl.cc
|
||||
@@ -1946,6 +1946,8 @@ void RenderWidgetHostImpl::FilterDropData(DropData* drop_data) {
|
||||
@@ -1945,6 +1945,8 @@ void RenderWidgetHostImpl::FilterDropData(DropData* drop_data) {
|
||||
void RenderWidgetHostImpl::SetCursor(const ui::Cursor& cursor) {
|
||||
if (view_)
|
||||
view_->UpdateCursor(WebCursor(cursor));
|
||||
|
@ -43,7 +43,7 @@ index 06524496cdad2dfecc8a7cba98a44eac4fa87101..77cdeea65429b28bbb178d797406b736
|
|||
|
||||
void RenderWidgetHostImpl::ShowContextMenuAtPoint(
|
||||
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
|
||||
index 6acb183b87ebcfb5d769517985b691b9969bb6e6..2426eb615967cbe3d11ece998d97d63266fac184 100644
|
||||
index b1cbf6f76c2032dd3a6c90f1c9cf97ccaa734bec..54fce2b0b6da947473e8725bf97816de9f51b12a 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.cc
|
||||
+++ b/content/browser/web_contents/web_contents_impl.cc
|
||||
@@ -4192,6 +4192,11 @@ TextInputManager* WebContentsImpl::GetTextInputManager() {
|
||||
|
@ -59,7 +59,7 @@ index 6acb183b87ebcfb5d769517985b691b9969bb6e6..2426eb615967cbe3d11ece998d97d632
|
|||
RenderWidgetHostImpl* render_widget_host) {
|
||||
return render_widget_host == GetMainFrame()->GetRenderWidgetHost();
|
||||
diff --git a/content/browser/web_contents/web_contents_impl.h b/content/browser/web_contents/web_contents_impl.h
|
||||
index 345cdec6cb509341b23f5870c0660029c984e0bf..860301d6374687ab8f155e5091aba6239c37af35 100644
|
||||
index 2520b412d1cb644d44dbc12d6d4d1d4ab131ca33..e66c762b5093e7154920b7df8638733bd146f535 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.h
|
||||
+++ b/content/browser/web_contents/web_contents_impl.h
|
||||
@@ -960,6 +960,7 @@ class CONTENT_EXPORT WebContentsImpl : public WebContents,
|
||||
|
|
|
@ -88,10 +88,10 @@ index 6191d4774ae35f00c3b58f62719962de616c8ad7..f717ae1d8e3bf642792f1dcfebbaa287
|
|||
// |url|. If the function returns a valid |new_url|, the request must be
|
||||
// updated to use it.
|
||||
diff --git a/content/renderer/render_frame_impl.cc b/content/renderer/render_frame_impl.cc
|
||||
index 2d0d35843ee2ed2e13c053790fdbfd625a9a0071..f4abb34513e76cf76deb58810b1b4d9387ac0fec 100644
|
||||
index abcfd464b8a92f65623bc4527123cc75ad38b712..33fe8d118ced62aaba2c81ade206382395630086 100644
|
||||
--- a/content/renderer/render_frame_impl.cc
|
||||
+++ b/content/renderer/render_frame_impl.cc
|
||||
@@ -4928,6 +4928,22 @@ void RenderFrameImpl::BeginNavigation(
|
||||
@@ -4924,6 +4924,22 @@ void RenderFrameImpl::BeginNavigation(
|
||||
// we can do a per-frame check here rather than a process-wide check.
|
||||
bool should_fork = HasWebUIScheme(url) || HasWebUIScheme(old_url) ||
|
||||
(enabled_bindings_ & kWebUIBindingsPolicyMask);
|
||||
|
|
|
@ -6,10 +6,10 @@ Subject: scroll_bounce_flag.patch
|
|||
Patch to make scrollBounce option work.
|
||||
|
||||
diff --git a/content/renderer/render_thread_impl.cc b/content/renderer/render_thread_impl.cc
|
||||
index fcb90d8024c7677ea15ff73064f51886b333a512..fa2ecae71873d4d83b805f73b8978fbadb5b1245 100644
|
||||
index 2d3f4ec3c94f669276ad8e8b5595f49100b7ad34..51321a2ee5602ae628eaad77e519b4d9c2821b3f 100644
|
||||
--- a/content/renderer/render_thread_impl.cc
|
||||
+++ b/content/renderer/render_thread_impl.cc
|
||||
@@ -1270,7 +1270,7 @@ bool RenderThreadImpl::IsLcdTextEnabled() {
|
||||
@@ -1250,7 +1250,7 @@ bool RenderThreadImpl::IsLcdTextEnabled() {
|
||||
}
|
||||
|
||||
bool RenderThreadImpl::IsElasticOverscrollEnabled() {
|
||||
|
|
|
@ -22,10 +22,10 @@ However, the patch would need to be reviewed by the security team, as it
|
|||
does touch a security-sensitive class.
|
||||
|
||||
diff --git a/content/browser/renderer_host/render_process_host_impl.cc b/content/browser/renderer_host/render_process_host_impl.cc
|
||||
index 1a01a7264f7a89c6b6f1d4e903333718adfbeb2d..43ad6054fc9c310fb78f8e718a91d29cfcc797d8 100644
|
||||
index 2afda54851efbb052371ce1e49f29cc56e93dce4..4208521cf4f03a154f44d5bd925f1cc12c306e20 100644
|
||||
--- a/content/browser/renderer_host/render_process_host_impl.cc
|
||||
+++ b/content/browser/renderer_host/render_process_host_impl.cc
|
||||
@@ -388,10 +388,18 @@ class RendererSandboxedProcessLauncherDelegate
|
||||
@@ -387,10 +387,18 @@ class RendererSandboxedProcessLauncherDelegate
|
||||
public:
|
||||
RendererSandboxedProcessLauncherDelegate() = default;
|
||||
|
||||
|
@ -44,7 +44,7 @@ index 1a01a7264f7a89c6b6f1d4e903333718adfbeb2d..43ad6054fc9c310fb78f8e718a91d29c
|
|||
const base::CommandLine& browser_command_line =
|
||||
*base::CommandLine::ForCurrentProcess();
|
||||
base::CommandLine::StringType renderer_prefix =
|
||||
@@ -409,6 +417,11 @@ class RendererSandboxedProcessLauncherDelegate
|
||||
@@ -408,6 +416,11 @@ class RendererSandboxedProcessLauncherDelegate
|
||||
sandbox::policy::SandboxType GetSandboxType() override {
|
||||
return sandbox::policy::SandboxType::kRenderer;
|
||||
}
|
||||
|
@ -56,7 +56,7 @@ index 1a01a7264f7a89c6b6f1d4e903333718adfbeb2d..43ad6054fc9c310fb78f8e718a91d29c
|
|||
};
|
||||
|
||||
#if defined(OS_WIN)
|
||||
@@ -419,6 +432,9 @@ class RendererSandboxedProcessLauncherDelegateWin
|
||||
@@ -418,6 +431,9 @@ class RendererSandboxedProcessLauncherDelegateWin
|
||||
RendererSandboxedProcessLauncherDelegateWin(base::CommandLine* cmd_line)
|
||||
: renderer_code_integrity_enabled_(
|
||||
GetContentClient()->browser()->IsRendererCodeIntegrityEnabled()) {
|
||||
|
@ -66,7 +66,7 @@ index 1a01a7264f7a89c6b6f1d4e903333718adfbeb2d..43ad6054fc9c310fb78f8e718a91d29c
|
|||
if (cmd_line->HasSwitch(switches::kJavaScriptFlags)) {
|
||||
std::string js_flags =
|
||||
cmd_line->GetSwitchValueASCII(switches::kJavaScriptFlags);
|
||||
@@ -1879,9 +1895,15 @@ bool RenderProcessHostImpl::Init() {
|
||||
@@ -1878,9 +1894,15 @@ bool RenderProcessHostImpl::Init() {
|
||||
std::unique_ptr<SandboxedProcessLauncherDelegate> sandbox_delegate =
|
||||
std::make_unique<RendererSandboxedProcessLauncherDelegateWin>(
|
||||
cmd_line.get());
|
||||
|
|
|
@ -9,7 +9,7 @@ is needed for OSR.
|
|||
Originally landed in https://github.com/electron/libchromiumcontent/pull/226.
|
||||
|
||||
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
|
||||
index f4c8d9e8a20f9be8c6566857fcf1d57ba7ec1af7..96a40070b3aab960d8e0639636f1a0ee346b0ed3 100644
|
||||
index aa50664e5fcb88ac72118ba5d354f835d427b6fd..93b554fb8e6f560ff1e1081e34430f3ad65b7ca1 100644
|
||||
--- a/content/browser/web_contents/web_contents_impl.cc
|
||||
+++ b/content/browser/web_contents/web_contents_impl.cc
|
||||
@@ -2774,6 +2774,12 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params) {
|
||||
|
|
|
@ -26,10 +26,10 @@ index a0d7f49d1e4ca4009fbebc0bd7df234eb6850b08..6191d4774ae35f00c3b58f62719962de
|
|||
// An empty URL is returned if the URL is not overriden.
|
||||
virtual GURL OverrideFlashEmbedWithHTML(const GURL& url);
|
||||
diff --git a/content/renderer/renderer_blink_platform_impl.cc b/content/renderer/renderer_blink_platform_impl.cc
|
||||
index 1db5cf167274eefc24be8071aecfae23e6b35c9c..eccb1b6257d8e57e4c20c015e96987852c90eafa 100644
|
||||
index a0bf74769bf06bb8a97b675c9eeac4d6c3829964..1f6380f738fd41906e79839560498b54461c6cea 100644
|
||||
--- a/content/renderer/renderer_blink_platform_impl.cc
|
||||
+++ b/content/renderer/renderer_blink_platform_impl.cc
|
||||
@@ -917,6 +917,12 @@ void RendererBlinkPlatformImpl::WillStopWorkerThread() {
|
||||
@@ -916,6 +916,12 @@ void RendererBlinkPlatformImpl::WillStopWorkerThread() {
|
||||
WorkerThreadRegistry::Instance()->WillStopCurrentWorkerThread();
|
||||
}
|
||||
|
||||
|
|
|
@ -35,10 +35,10 @@ index f717ae1d8e3bf642792f1dcfebbaa2870ff97694..65d3085260e054a671afbecf55062d17
|
|||
// from the worker thread.
|
||||
virtual void WillDestroyWorkerContextOnWorkerThread(
|
||||
diff --git a/content/renderer/renderer_blink_platform_impl.cc b/content/renderer/renderer_blink_platform_impl.cc
|
||||
index eccb1b6257d8e57e4c20c015e96987852c90eafa..9b6ce666b9e268bf4157e00e94d54f5b87491e3b 100644
|
||||
index 1f6380f738fd41906e79839560498b54461c6cea..bf6b13594de39cbf96df332922a2b364219b7905 100644
|
||||
--- a/content/renderer/renderer_blink_platform_impl.cc
|
||||
+++ b/content/renderer/renderer_blink_platform_impl.cc
|
||||
@@ -929,6 +929,12 @@ void RendererBlinkPlatformImpl::WorkerContextCreated(
|
||||
@@ -928,6 +928,12 @@ void RendererBlinkPlatformImpl::WorkerContextCreated(
|
||||
worker);
|
||||
}
|
||||
|
||||
|
|
|
@ -9,10 +9,10 @@ necessary for native modules to load.
|
|||
Also, some fixes relating to mksnapshot on ARM.
|
||||
|
||||
diff --git a/BUILD.gn b/BUILD.gn
|
||||
index 1a94829652fb309759927dab9b67951d14d43c01..34cfa21668d409cd0e2de2c96ee52f5b575df742 100644
|
||||
index ff0aaa30098839a1186626061363aca985c8e46d..cf0daf8006928970e8dc2e9dd2cb20985d3309ae 100644
|
||||
--- a/BUILD.gn
|
||||
+++ b/BUILD.gn
|
||||
@@ -510,7 +510,7 @@ config("internal_config") {
|
||||
@@ -507,7 +507,7 @@ config("internal_config") {
|
||||
":cppgc_header_features",
|
||||
]
|
||||
|
||||
|
@ -21,7 +21,7 @@ index 1a94829652fb309759927dab9b67951d14d43c01..34cfa21668d409cd0e2de2c96ee52f5b
|
|||
defines += [ "BUILDING_V8_SHARED" ]
|
||||
}
|
||||
}
|
||||
@@ -5183,7 +5183,7 @@ if (current_toolchain == v8_generator_toolchain) {
|
||||
@@ -5182,7 +5182,7 @@ if (current_toolchain == v8_generator_toolchain) {
|
||||
"src/interpreter/bytecodes.h",
|
||||
]
|
||||
|
||||
|
@ -30,7 +30,7 @@ index 1a94829652fb309759927dab9b67951d14d43c01..34cfa21668d409cd0e2de2c96ee52f5b
|
|||
|
||||
deps = [
|
||||
":v8_libbase",
|
||||
@@ -5221,6 +5221,8 @@ if (current_toolchain == v8_snapshot_toolchain) {
|
||||
@@ -5220,6 +5220,8 @@ if (current_toolchain == v8_snapshot_toolchain) {
|
||||
|
||||
configs = [ ":internal_config" ]
|
||||
|
||||
|
|
|
@ -12,10 +12,10 @@ This patch can be safely removed if, when it is removed, `node.lib` does not
|
|||
contain any standard C++ library exports (e.g. `std::ostringstream`).
|
||||
|
||||
diff --git a/BUILD.gn b/BUILD.gn
|
||||
index 04ded39fa48c2a46b3603e56e06e198f1ea5dc15..aefef3f07bb843bd84f6d4e5b70e98bedf189ac5 100644
|
||||
index 71afc320af85b8f0021ba3e64aacb0f1af5a45ab..98b1e1f346c5d6c8b1f6574c5154446d7c6257df 100644
|
||||
--- a/BUILD.gn
|
||||
+++ b/BUILD.gn
|
||||
@@ -510,6 +510,10 @@ config("internal_config") {
|
||||
@@ -507,6 +507,10 @@ config("internal_config") {
|
||||
":cppgc_header_features",
|
||||
]
|
||||
|
||||
|
|
|
@ -6,10 +6,10 @@ Subject: expose_mksnapshot.patch
|
|||
Needed in order to target mksnapshot for mksnapshot zip.
|
||||
|
||||
diff --git a/BUILD.gn b/BUILD.gn
|
||||
index 34cfa21668d409cd0e2de2c96ee52f5b575df742..04ded39fa48c2a46b3603e56e06e198f1ea5dc15 100644
|
||||
index cf0daf8006928970e8dc2e9dd2cb20985d3309ae..71afc320af85b8f0021ba3e64aacb0f1af5a45ab 100644
|
||||
--- a/BUILD.gn
|
||||
+++ b/BUILD.gn
|
||||
@@ -5195,7 +5195,6 @@ if (current_toolchain == v8_generator_toolchain) {
|
||||
@@ -5194,7 +5194,6 @@ if (current_toolchain == v8_generator_toolchain) {
|
||||
|
||||
if (current_toolchain == v8_snapshot_toolchain) {
|
||||
v8_executable("mksnapshot") {
|
||||
|
|
|
@ -117,7 +117,7 @@ class BrowserWindow : public BaseWindow,
|
|||
|
||||
// Closure that would be called when window is unresponsive when closing,
|
||||
// it should be cancelled when we can prove that the window is responsive.
|
||||
base::CancelableClosure window_unresponsive_closure_;
|
||||
base::CancelableRepeatingClosure window_unresponsive_closure_;
|
||||
|
||||
#if defined(OS_MAC)
|
||||
std::vector<mojom::DraggableRegionPtr> draggable_regions_;
|
||||
|
|
|
@ -73,7 +73,7 @@ void GlobalShortcut::OnKeyPressed(const ui::Accelerator& accelerator) {
|
|||
|
||||
bool GlobalShortcut::RegisterAll(
|
||||
const std::vector<ui::Accelerator>& accelerators,
|
||||
const base::Closure& callback) {
|
||||
const base::RepeatingClosure& callback) {
|
||||
if (!electron::Browser::Get()->is_ready()) {
|
||||
gin_helper::ErrorThrower(JavascriptEnvironment::GetIsolate())
|
||||
.ThrowError("globalShortcut cannot be used before the app is ready");
|
||||
|
@ -94,7 +94,7 @@ bool GlobalShortcut::RegisterAll(
|
|||
}
|
||||
|
||||
bool GlobalShortcut::Register(const ui::Accelerator& accelerator,
|
||||
const base::Closure& callback) {
|
||||
const base::RepeatingClosure& callback) {
|
||||
if (!electron::Browser::Get()->is_ready()) {
|
||||
gin_helper::ErrorThrower(JavascriptEnvironment::GetIsolate())
|
||||
.ThrowError("globalShortcut cannot be used before the app is ready");
|
||||
|
|
|
@ -35,12 +35,13 @@ class GlobalShortcut : public extensions::GlobalShortcutListener::Observer,
|
|||
~GlobalShortcut() override;
|
||||
|
||||
private:
|
||||
typedef std::map<ui::Accelerator, base::Closure> AcceleratorCallbackMap;
|
||||
typedef std::map<ui::Accelerator, base::RepeatingClosure>
|
||||
AcceleratorCallbackMap;
|
||||
|
||||
bool RegisterAll(const std::vector<ui::Accelerator>& accelerators,
|
||||
const base::Closure& callback);
|
||||
const base::RepeatingClosure& callback);
|
||||
bool Register(const ui::Accelerator& accelerator,
|
||||
const base::Closure& callback);
|
||||
const base::RepeatingClosure& callback);
|
||||
bool IsRegistered(const ui::Accelerator& accelerator);
|
||||
void Unregister(const ui::Accelerator& accelerator);
|
||||
void UnregisterSome(const std::vector<ui::Accelerator>& accelerators);
|
||||
|
|
|
@ -155,7 +155,7 @@ class Browser : public WindowListObserver {
|
|||
|
||||
#if defined(OS_MAC)
|
||||
// Set the handler which decides whether to shutdown.
|
||||
void SetShutdownHandler(base::Callback<bool()> handler);
|
||||
void SetShutdownHandler(base::RepeatingCallback<bool()> handler);
|
||||
|
||||
// Hide the application.
|
||||
void Hide();
|
||||
|
|
|
@ -93,7 +93,7 @@ v8::Local<v8::Promise> Browser::GetApplicationInfoForProtocol(
|
|||
return handle;
|
||||
}
|
||||
|
||||
void Browser::SetShutdownHandler(base::Callback<bool()> handler) {
|
||||
void Browser::SetShutdownHandler(base::RepeatingCallback<bool()> handler) {
|
||||
[[AtomApplication sharedApplication] setShutdownHandler:std::move(handler)];
|
||||
}
|
||||
|
||||
|
|
|
@ -26,7 +26,8 @@ CookieChangeNotifier::~CookieChangeNotifier() = default;
|
|||
|
||||
base::CallbackListSubscription
|
||||
CookieChangeNotifier::RegisterCookieChangeCallback(
|
||||
const base::Callback<void(const net::CookieChangeInfo& change)>& cb) {
|
||||
const base::RepeatingCallback<void(const net::CookieChangeInfo& change)>&
|
||||
cb) {
|
||||
DCHECK_CURRENTLY_ON(BrowserThread::UI);
|
||||
|
||||
return cookie_change_sub_list_.Add(cb);
|
||||
|
|
|
@ -25,7 +25,8 @@ class CookieChangeNotifier : public network::mojom::CookieChangeListener {
|
|||
|
||||
// Register callbacks that needs to notified on any cookie store changes.
|
||||
base::CallbackListSubscription RegisterCookieChangeCallback(
|
||||
const base::Callback<void(const net::CookieChangeInfo& change)>& cb);
|
||||
const base::RepeatingCallback<void(const net::CookieChangeInfo& change)>&
|
||||
cb);
|
||||
|
||||
private:
|
||||
void StartListening();
|
||||
|
|
|
@ -22,7 +22,7 @@ class ElectronDownloadManagerDelegate
|
|||
: public content::DownloadManagerDelegate {
|
||||
public:
|
||||
using CreateDownloadPathCallback =
|
||||
base::Callback<void(const base::FilePath&)>;
|
||||
base::RepeatingCallback<void(const base::FilePath&)>;
|
||||
|
||||
explicit ElectronDownloadManagerDelegate(content::DownloadManager* manager);
|
||||
~ElectronDownloadManagerDelegate() override;
|
||||
|
|
|
@ -29,11 +29,12 @@ class ElectronPermissionManager : public content::PermissionControllerDelegate {
|
|||
base::OnceCallback<void(blink::mojom::PermissionStatus)>;
|
||||
using StatusesCallback = base::OnceCallback<void(
|
||||
const std::vector<blink::mojom::PermissionStatus>&)>;
|
||||
using RequestHandler = base::Callback<void(content::WebContents*,
|
||||
using RequestHandler = base::RepeatingCallback<void(content::WebContents*,
|
||||
content::PermissionType,
|
||||
StatusCallback,
|
||||
const base::Value&)>;
|
||||
using CheckHandler = base::Callback<bool(content::WebContents*,
|
||||
using CheckHandler =
|
||||
base::RepeatingCallback<bool(content::WebContents*,
|
||||
content::PermissionType,
|
||||
const GURL& requesting_origin,
|
||||
const base::Value&)>;
|
||||
|
|
|
@ -115,7 +115,8 @@ void PowerObserverLinux::UnblockShutdown() {
|
|||
shutdown_lock_.reset();
|
||||
}
|
||||
|
||||
void PowerObserverLinux::SetShutdownHandler(base::Callback<bool()> handler) {
|
||||
void PowerObserverLinux::SetShutdownHandler(
|
||||
base::RepeatingCallback<bool()> handler) {
|
||||
// In order to delay system shutdown when e.preventDefault() is invoked
|
||||
// on a powerMonitor 'shutdown' event, we need an org.freedesktop.login1
|
||||
// shutdown delay lock. For more details see the "Taking Delay Locks"
|
||||
|
|
|
@ -22,7 +22,7 @@ class PowerObserverLinux {
|
|||
explicit PowerObserverLinux(base::PowerSuspendObserver* suspend_observer);
|
||||
~PowerObserverLinux();
|
||||
|
||||
void SetShutdownHandler(base::Callback<bool()> should_shutdown);
|
||||
void SetShutdownHandler(base::RepeatingCallback<bool()> should_shutdown);
|
||||
|
||||
private:
|
||||
void BlockSleep();
|
||||
|
|
|
@ -18,12 +18,12 @@
|
|||
NSCondition* handoffLock_;
|
||||
BOOL updateReceived_;
|
||||
BOOL userStoppedShutdown_;
|
||||
base::Callback<bool()> shouldShutdown_;
|
||||
base::RepeatingCallback<bool()> shouldShutdown_;
|
||||
}
|
||||
|
||||
+ (AtomApplication*)sharedApplication;
|
||||
|
||||
- (void)setShutdownHandler:(base::Callback<bool()>)handler;
|
||||
- (void)setShutdownHandler:(base::RepeatingCallback<bool()>)handler;
|
||||
- (void)registerURLHandler;
|
||||
|
||||
// Called when macOS itself is shutting down.
|
||||
|
|
|
@ -56,7 +56,7 @@ inline void dispatch_sync_main(dispatch_block_t block) {
|
|||
electron::Browser::Get()->Quit();
|
||||
}
|
||||
|
||||
- (void)setShutdownHandler:(base::Callback<bool()>)handler {
|
||||
- (void)setShutdownHandler:(base::RepeatingCallback<bool()>)handler {
|
||||
shouldShutdown_ = std::move(handler);
|
||||
}
|
||||
|
||||
|
|
|
@ -33,7 +33,8 @@ enum class ProtocolType {
|
|||
|
||||
using StartLoadingCallback = base::OnceCallback<void(gin::Arguments*)>;
|
||||
using ProtocolHandler =
|
||||
base::Callback<void(const network::ResourceRequest&, StartLoadingCallback)>;
|
||||
base::RepeatingCallback<void(const network::ResourceRequest&,
|
||||
StartLoadingCallback)>;
|
||||
|
||||
// scheme => (type, handler).
|
||||
using HandlersMap =
|
||||
|
|
|
@ -17,7 +17,8 @@
|
|||
|
||||
namespace electron {
|
||||
|
||||
typedef base::Callback<void(const gfx::Rect&, const SkBitmap&)> OnPaintCallback;
|
||||
typedef base::RepeatingCallback<void(const gfx::Rect&, const SkBitmap&)>
|
||||
OnPaintCallback;
|
||||
|
||||
class LayeredWindowUpdater : public viz::mojom::LayeredWindowUpdater {
|
||||
public:
|
||||
|
|
|
@ -52,8 +52,9 @@ class ElectronBeginFrameTimer;
|
|||
|
||||
class ElectronDelegatedFrameHostClient;
|
||||
|
||||
typedef base::Callback<void(const gfx::Rect&, const SkBitmap&)> OnPaintCallback;
|
||||
typedef base::Callback<void(const gfx::Rect&)> OnPopupPaintCallback;
|
||||
typedef base::RepeatingCallback<void(const gfx::Rect&, const SkBitmap&)>
|
||||
OnPaintCallback;
|
||||
typedef base::RepeatingCallback<void(const gfx::Rect&)> OnPopupPaintCallback;
|
||||
|
||||
class OffScreenRenderWidgetHostView : public content::RenderWidgetHostViewBase,
|
||||
public ui::CompositorDelegate,
|
||||
|
|
|
@ -37,7 +37,7 @@ AppIndicatorIconMenu::~AppIndicatorIconMenu() {
|
|||
|
||||
void AppIndicatorIconMenu::UpdateClickActionReplacementMenuItem(
|
||||
const char* label,
|
||||
const base::Closure& callback) {
|
||||
const base::RepeatingClosure& callback) {
|
||||
click_action_replacement_callback_ = callback;
|
||||
|
||||
if (click_action_replacement_menu_item_added_) {
|
||||
|
|
|
@ -29,8 +29,9 @@ class AppIndicatorIconMenu {
|
|||
// Sets a menu item at the top of |gtk_menu_| as a replacement for the app
|
||||
// indicator icon's click action. |callback| is called when the menu item
|
||||
// is activated.
|
||||
void UpdateClickActionReplacementMenuItem(const char* label,
|
||||
const base::Closure& callback);
|
||||
void UpdateClickActionReplacementMenuItem(
|
||||
const char* label,
|
||||
const base::RepeatingClosure& callback);
|
||||
|
||||
// Refreshes all the menu item labels and menu item checked/enabled states.
|
||||
void Refresh();
|
||||
|
@ -59,7 +60,7 @@ class AppIndicatorIconMenu {
|
|||
// Called when the click action replacement menu item is activated. When a
|
||||
// menu item from |menu_model_| is activated, MenuModel::ActivatedAt() is
|
||||
// invoked and is assumed to do any necessary processing.
|
||||
base::Closure click_action_replacement_callback_;
|
||||
base::RepeatingClosure click_action_replacement_callback_;
|
||||
|
||||
GtkWidget* gtk_menu_ = nullptr;
|
||||
|
||||
|
|
|
@ -25,7 +25,7 @@ class TaskbarHost {
|
|||
std::string tooltip;
|
||||
gfx::Image icon;
|
||||
std::vector<std::string> flags;
|
||||
base::Closure clicked_callback;
|
||||
base::RepeatingClosure clicked_callback;
|
||||
|
||||
ThumbarButton();
|
||||
ThumbarButton(const ThumbarButton&);
|
||||
|
@ -66,7 +66,7 @@ class TaskbarHost {
|
|||
// Initialize the taskbar object.
|
||||
bool InitializeTaskbar();
|
||||
|
||||
using CallbackMap = std::map<int, base::Closure>;
|
||||
using CallbackMap = std::map<int, base::RepeatingClosure>;
|
||||
CallbackMap callback_map_;
|
||||
|
||||
std::vector<ThumbarButton> last_buttons_;
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
#include "shell/common/gin_helper/function_template.h"
|
||||
#include "shell/common/gin_helper/locker.h"
|
||||
#include "shell/common/gin_helper/microtasks_scope.h"
|
||||
// Implements safe convertions between JS functions and base::Callback.
|
||||
// Implements safe convertions between JS functions and base::RepeatingCallback.
|
||||
|
||||
namespace gin_helper {
|
||||
|
||||
|
@ -111,7 +111,7 @@ struct V8FunctionInvoker<ReturnType(ArgTypes...)> {
|
|||
};
|
||||
|
||||
// Helper to pass a C++ funtion to JavaScript.
|
||||
using Translater = base::Callback<void(gin::Arguments* args)>;
|
||||
using Translater = base::RepeatingCallback<void(gin::Arguments* args)>;
|
||||
v8::Local<v8::Value> CreateFunctionFromTranslater(v8::Isolate* isolate,
|
||||
const Translater& translater,
|
||||
bool one_time);
|
||||
|
@ -127,7 +127,7 @@ struct NativeFunctionInvoker {};
|
|||
|
||||
template <typename ReturnType, typename... ArgTypes>
|
||||
struct NativeFunctionInvoker<ReturnType(ArgTypes...)> {
|
||||
static void Go(base::Callback<ReturnType(ArgTypes...)> val,
|
||||
static void Go(base::RepeatingCallback<ReturnType(ArgTypes...)> val,
|
||||
gin::Arguments* args) {
|
||||
using Indices = typename IndicesGenerator<sizeof...(ArgTypes)>::type;
|
||||
Invoker<Indices, ArgTypes...> invoker(args, 0);
|
||||
|
|
|
@ -12,19 +12,19 @@ namespace gin_helper {
|
|||
|
||||
namespace internal {
|
||||
|
||||
// This set of templates invokes a base::Callback by converting the Arguments
|
||||
// into native types. It relies on the function_template.h to provide helper
|
||||
// templates.
|
||||
// This set of templates invokes a base::RepeatingCallback by converting the
|
||||
// Arguments into native types. It relies on the function_template.h to provide
|
||||
// helper templates.
|
||||
inline WrappableBase* InvokeFactory(
|
||||
gin::Arguments* args,
|
||||
const base::Callback<WrappableBase*()>& callback) {
|
||||
const base::RepeatingCallback<WrappableBase*()>& callback) {
|
||||
return callback.Run();
|
||||
}
|
||||
|
||||
template <typename P1>
|
||||
inline WrappableBase* InvokeFactory(
|
||||
gin::Arguments* args,
|
||||
const base::Callback<WrappableBase*(P1)>& callback) {
|
||||
const base::RepeatingCallback<WrappableBase*(P1)>& callback) {
|
||||
typename CallbackParamTraits<P1>::LocalType a1;
|
||||
if (!gin_helper::GetNextArgument(args, 0, true, &a1))
|
||||
return nullptr;
|
||||
|
@ -34,7 +34,7 @@ inline WrappableBase* InvokeFactory(
|
|||
template <typename P1, typename P2>
|
||||
inline WrappableBase* InvokeFactory(
|
||||
gin::Arguments* args,
|
||||
const base::Callback<WrappableBase*(P1, P2)>& callback) {
|
||||
const base::RepeatingCallback<WrappableBase*(P1, P2)>& callback) {
|
||||
typename CallbackParamTraits<P1>::LocalType a1;
|
||||
typename CallbackParamTraits<P2>::LocalType a2;
|
||||
if (!gin_helper::GetNextArgument(args, 0, true, &a1) ||
|
||||
|
@ -46,7 +46,7 @@ inline WrappableBase* InvokeFactory(
|
|||
template <typename P1, typename P2, typename P3>
|
||||
inline WrappableBase* InvokeFactory(
|
||||
gin::Arguments* args,
|
||||
const base::Callback<WrappableBase*(P1, P2, P3)>& callback) {
|
||||
const base::RepeatingCallback<WrappableBase*(P1, P2, P3)>& callback) {
|
||||
typename CallbackParamTraits<P1>::LocalType a1;
|
||||
typename CallbackParamTraits<P2>::LocalType a2;
|
||||
typename CallbackParamTraits<P3>::LocalType a3;
|
||||
|
@ -60,7 +60,7 @@ inline WrappableBase* InvokeFactory(
|
|||
template <typename P1, typename P2, typename P3, typename P4>
|
||||
inline WrappableBase* InvokeFactory(
|
||||
gin::Arguments* args,
|
||||
const base::Callback<WrappableBase*(P1, P2, P3, P4)>& callback) {
|
||||
const base::RepeatingCallback<WrappableBase*(P1, P2, P3, P4)>& callback) {
|
||||
typename CallbackParamTraits<P1>::LocalType a1;
|
||||
typename CallbackParamTraits<P2>::LocalType a2;
|
||||
typename CallbackParamTraits<P3>::LocalType a3;
|
||||
|
@ -76,7 +76,8 @@ inline WrappableBase* InvokeFactory(
|
|||
template <typename P1, typename P2, typename P3, typename P4, typename P5>
|
||||
inline WrappableBase* InvokeFactory(
|
||||
gin::Arguments* args,
|
||||
const base::Callback<WrappableBase*(P1, P2, P3, P4, P5)>& callback) {
|
||||
const base::RepeatingCallback<WrappableBase*(P1, P2, P3, P4, P5)>&
|
||||
callback) {
|
||||
typename CallbackParamTraits<P1>::LocalType a1;
|
||||
typename CallbackParamTraits<P2>::LocalType a2;
|
||||
typename CallbackParamTraits<P3>::LocalType a3;
|
||||
|
@ -99,7 +100,8 @@ template <typename P1,
|
|||
typename P6>
|
||||
inline WrappableBase* InvokeFactory(
|
||||
gin::Arguments* args,
|
||||
const base::Callback<WrappableBase*(P1, P2, P3, P4, P5, P6)>& callback) {
|
||||
const base::RepeatingCallback<WrappableBase*(P1, P2, P3, P4, P5, P6)>&
|
||||
callback) {
|
||||
typename CallbackParamTraits<P1>::LocalType a1;
|
||||
typename CallbackParamTraits<P2>::LocalType a2;
|
||||
typename CallbackParamTraits<P3>::LocalType a3;
|
||||
|
@ -117,7 +119,7 @@ inline WrappableBase* InvokeFactory(
|
|||
}
|
||||
|
||||
template <typename Sig>
|
||||
void InvokeNew(const base::Callback<Sig>& factory,
|
||||
void InvokeNew(const base::RepeatingCallback<Sig>& factory,
|
||||
v8::Isolate* isolate,
|
||||
gin_helper::Arguments* args) {
|
||||
if (!args->IsConstructCall()) {
|
||||
|
|
|
@ -41,7 +41,8 @@ struct CallbackParamTraits<const T*> {
|
|||
typedef T* LocalType;
|
||||
};
|
||||
|
||||
// CallbackHolder and CallbackHolderBase are used to pass a base::Callback from
|
||||
// CallbackHolder and CallbackHolderBase are used to pass a
|
||||
// base::RepeatingCallback from
|
||||
// CreateFunctionTemplate through v8 (via v8::FunctionTemplate) to
|
||||
// DispatchToCallback, where it is invoked.
|
||||
|
||||
|
@ -70,10 +71,10 @@ template <typename Sig>
|
|||
class CallbackHolder : public CallbackHolderBase {
|
||||
public:
|
||||
CallbackHolder(v8::Isolate* isolate,
|
||||
const base::Callback<Sig>& callback,
|
||||
const base::RepeatingCallback<Sig>& callback,
|
||||
int flags)
|
||||
: CallbackHolderBase(isolate), callback(callback), flags(flags) {}
|
||||
base::Callback<Sig> callback;
|
||||
base::RepeatingCallback<Sig> callback;
|
||||
int flags = 0;
|
||||
|
||||
private:
|
||||
|
@ -214,7 +215,8 @@ class Invoker<IndicesHolder<indices...>, ArgTypes...>
|
|||
bool IsOK() { return And(ArgumentHolder<indices, ArgTypes>::ok...); }
|
||||
|
||||
template <typename ReturnType>
|
||||
void DispatchToCallback(base::Callback<ReturnType(ArgTypes...)> callback) {
|
||||
void DispatchToCallback(
|
||||
base::RepeatingCallback<ReturnType(ArgTypes...)> callback) {
|
||||
gin_helper::MicrotasksScope microtasks_scope(args_->isolate(), true);
|
||||
args_->Return(
|
||||
callback.Run(std::move(ArgumentHolder<indices, ArgTypes>::value)...));
|
||||
|
@ -223,7 +225,7 @@ class Invoker<IndicesHolder<indices...>, ArgTypes...>
|
|||
// In C++, you can declare the function foo(void), but you can't pass a void
|
||||
// expression to foo. As a result, we must specialize the case of Callbacks
|
||||
// that have the void return type.
|
||||
void DispatchToCallback(base::Callback<void(ArgTypes...)> callback) {
|
||||
void DispatchToCallback(base::RepeatingCallback<void(ArgTypes...)> callback) {
|
||||
gin_helper::MicrotasksScope microtasks_scope(args_->isolate(), true);
|
||||
callback.Run(std::move(ArgumentHolder<indices, ArgTypes>::value)...);
|
||||
}
|
||||
|
@ -239,7 +241,7 @@ class Invoker<IndicesHolder<indices...>, ArgTypes...>
|
|||
};
|
||||
|
||||
// DispatchToCallback converts all the JavaScript arguments to C++ types and
|
||||
// invokes the base::Callback.
|
||||
// invokes the base::RepeatingCallback.
|
||||
template <typename Sig>
|
||||
struct Dispatcher {};
|
||||
|
||||
|
@ -264,7 +266,8 @@ struct Dispatcher<ReturnType(ArgTypes...)> {
|
|||
};
|
||||
|
||||
// CreateFunctionTemplate creates a v8::FunctionTemplate that will create
|
||||
// JavaScript functions that execute a provided C++ function or base::Callback.
|
||||
// JavaScript functions that execute a provided C++ function or
|
||||
// base::RepeatingCallback.
|
||||
// JavaScript arguments are automatically converted via gin::Converter, as is
|
||||
// the return value of the C++ function, if any.
|
||||
//
|
||||
|
@ -275,7 +278,7 @@ struct Dispatcher<ReturnType(ArgTypes...)> {
|
|||
template <typename Sig>
|
||||
v8::Local<v8::FunctionTemplate> CreateFunctionTemplate(
|
||||
v8::Isolate* isolate,
|
||||
const base::Callback<Sig> callback,
|
||||
const base::RepeatingCallback<Sig> callback,
|
||||
int callback_flags = 0) {
|
||||
typedef CallbackHolder<Sig> HolderT;
|
||||
HolderT* holder = new HolderT(isolate, callback, callback_flags);
|
||||
|
@ -298,9 +301,9 @@ struct CallbackTraits {
|
|||
}
|
||||
};
|
||||
|
||||
// Specialization for base::Callback.
|
||||
// Specialization for base::RepeatingCallback.
|
||||
template <typename T>
|
||||
struct CallbackTraits<base::Callback<T>> {
|
||||
struct CallbackTraits<base::RepeatingCallback<T>> {
|
||||
static v8::Local<v8::FunctionTemplate> CreateTemplate(
|
||||
v8::Isolate* isolate,
|
||||
const base::RepeatingCallback<T>& callback) {
|
||||
|
|
|
@ -32,9 +32,9 @@ class ObjectTemplateBuilder {
|
|||
}
|
||||
|
||||
// In the following methods, T and U can be function pointer, member function
|
||||
// pointer, base::Callback, or v8::FunctionTemplate. Most clients will want to
|
||||
// use one of the first two options. Also see gin::CreateFunctionTemplate()
|
||||
// for creating raw function templates.
|
||||
// pointer, base::RepeatingCallback, or v8::FunctionTemplate. Most clients
|
||||
// will want to use one of the first two options. Also see
|
||||
// gin::CreateFunctionTemplate() for creating raw function templates.
|
||||
template <typename T>
|
||||
ObjectTemplateBuilder& SetMethod(const base::StringPiece& name,
|
||||
const T& callback) {
|
||||
|
|
|
@ -24,7 +24,7 @@ class Wrappable : public WrappableBase {
|
|||
|
||||
template <typename Sig>
|
||||
static void SetConstructor(v8::Isolate* isolate,
|
||||
const base::Callback<Sig>& constructor) {
|
||||
const base::RepeatingCallback<Sig>& constructor) {
|
||||
v8::Local<v8::FunctionTemplate> templ = gin_helper::CreateFunctionTemplate(
|
||||
isolate, base::BindRepeating(&internal::InvokeNew<Sig>, constructor));
|
||||
templ->InstanceTemplate()->SetInternalFieldCount(1);
|
||||
|
|
|
@ -16,7 +16,7 @@ namespace electron {
|
|||
|
||||
class GuestViewContainer {
|
||||
public:
|
||||
typedef base::Callback<void(const gfx::Size&)> ResizeCallback;
|
||||
typedef base::RepeatingCallback<void(const gfx::Size&)> ResizeCallback;
|
||||
|
||||
explicit GuestViewContainer(content::RenderFrame* render_frame);
|
||||
virtual ~GuestViewContainer();
|
||||
|
|
Loading…
Reference in a new issue