mirror of
https://github.com/electron/electron.git
synced 2026-05-02 03:00:22 -04:00
* chore: bump chromium in DEPS to 144.0.7543.0 Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com> * Pass PipScreenCaptureCoordinatorProxy to ScreenCaptureKitDeviceMac https://chromium-review.googlesource.com/c/chromium/src/+/7157590 Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org> * chore: update patches Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org> * chore: update filenames.libcxx.gni Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org> * 7142359: Spanification of process_singleton_posix.cc https: //chromium-review.googlesource.com/c/chromium/src/+/7142359 Co-Authored-By: Charles Kerr <70381+ckerr@users.noreply.github.com> Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org> * Move logging::LoggingSettings to base/logging/logging_settings.h https://chromium-review.googlesource.com/c/chromium/src/+/7173024 Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org> * chore: bump chromium in DEPS to 144.0.7545.0 Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com> * 7159368: update PluginService API for sync GetPlugins Upstream removed async PluginService APIs: - GetPluginsAsync() removed, use synchronous GetPlugins() - RegisterInternalPlugin() now takes single argument (remove add_at_beginning) - RefreshPlugins() removed entirely Updated ElectronPluginInfoHostImpl to use synchronous plugin loading and simplified ElectronBrowserMainParts internal plugin registration. Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7159368 Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7159328 Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7159056 (cherry picked from commit88cdf50b0a) Co-authored-by: Samuel Attard <sattard@anthropic.com> * 7159184: add missing base/files/file_path.h include Add explicit include for base/files/file_path.h in electron_browser_context.h. After removal of superfluous Mojo includes from content headers, base::FilePath is no longer transitively included via content/public/browser/browser_context.h. Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7159184 (cherry picked from commit6ca8ea03ec) Co-authored-by: Samuel Attard <sattard@anthropic.com> * 7126479: add ShouldForceRefreshTextCheckService parameter to SpellCheckClient Upstream added a force-refresh parameter to WebTextCheckClient::RequestCheckingOfText to bypass spell check cache. Add the new ShouldForceRefreshTextCheckService parameter to SpellCheckClient's override (currently unused in Electron). Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7126479 (cherry picked from commit879c0401c4) Co-authored-by: Samuel Attard <sattard@anthropic.com> * 7083663: remove fingerprinting_protection_ruleset_service override Upstream deleted external references to Fingerprinting Protection Filter (FPF) component. Remove the fingerprinting_protection_ruleset_service() override from BrowserProcessImpl as the method no longer exists in the base class. Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7083663 (cherry picked from commit8350d152f9) Co-authored-by: Samuel Attard <sattard@anthropic.com> * 7155287: implement WebContentsView::GetSize and Resize Upstream delegated WebContents::GetSize() and Resize() to WebContentsView, making them pure virtual. Add const qualifier to GetSize() and implement the Resize() override in OffScreenWebContentsView (no-op for offscreen). Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7155287 (cherry picked from commit084eaa568e) Co-authored-by: Samuel Attard <sattard@anthropic.com> * 7184238: add OnUnconfirmedTapConvertedToTap override Upstream added OnUnconfirmedTapConvertedToTap as a pure virtual method to RenderWidgetHostViewBase to inform root view when child frame converts an unconfirmed tap. Add empty override for offscreen rendering. Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7184238 (cherry picked from commitef03400d9a) Co-authored-by: Samuel Attard <sattard@anthropic.com> * 7143586: add widget parameter to OnCommandsChanged GlobalAcceleratorListener::OnCommandsChanged gained a gfx::AcceleratedWidget parameter for window association in the GlobalShortcutListenerLinux implementation. Pass gfx::kNullAcceleratedWidget for Electron's usage. Ref: : Pass parent handle to GlobalAcceleratorListenerLinux::BindShortcuts | https://chromium-review.googlesource.com/c/chromium/src/+/7143586 (cherry picked from commit38306e2bfc) Co-Authored-By: Samuel Attard <MarshallOfSound@users.noreply.github.com> Co-authored-by: Samuel Attard <sattard@anthropic.com> * chore: update patches Co-Authored-By: Samuel Attard <MarshallOfSound@users.noreply.github.com> Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org> * chore: bump chromium in DEPS to 144.0.7547.0 Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com> * chore: update patches Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org> * 7189232: Add support for UnownedUserData in GlobalFeatures https: //chromium-review.googlesource.com/c/chromium/src/+/7189232 Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org> * Refactor: Use std::u16string for extension load error messages https://chromium-review.googlesource.com/c/chromium/src/+/7185844 Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org> * fixup Add support for UnownedUserData in GlobalFeatures Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org> * 7165650: Remove ResourceContext https://chromium-review.googlesource.com/c/chromium/src/+/7165650 Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org> * fixup BUILD.gn for lint Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org> * 7202164: Reland "Reland "Remove GenericScopedHandle:IsValid"" https://chromium-review.googlesource.com/c/chromium/src/+/7202164 Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org> * advance deprecation of v8::ReturnValue<void>::Set(Local<S>). 7168624: [runtime][api] Relax requirements for setter/definer/deleter callbacks | https://chromium-review.googlesource.com/c/v8/v8/+/7168624 Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org> * fixup advance deprecation of v8::ReturnValue<void>::Set(Local<S>) Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org> * chore: skip setting LPAC ACLs Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org> * Revert "chore: skip setting LPAC ACLs" This reverts commite187aec488. Co-authored-by: John Kleinschmidt <kleinschmidtorama@gmail.com> * chore: revert Convert to UNSAFE_TODO in sandbox revert https://chromium-review.googlesource.com/c/chromium/src/+/7131661 to see if it fixes the Windows sandbox issue. Co-authored-by: John Kleinschmidt <kleinschmidtorama@gmail.com> * Revert "chore: revert Convert to UNSAFE_TODO in sandbox" This reverts commit57afbfefe5. Co-authored-by: John Kleinschmidt <kleinschmidtorama@gmail.com> * chore: Revert "Enable network sandbox by default on Windows" see if this fixes the Windows sandbox issue Co-authored-by: John Kleinschmidt <kleinschmidtorama@gmail.com> * Enable network sandbox by default on Windows https://chromium-review.googlesource.com/c/chromium/src/+/7204292 Co-authored-by: John Kleinschmidt <kleinschmidtorama@gmail.com> * Revert "chore: Revert "Enable network sandbox by default on Windows"" This reverts commit530ab6af82. Co-authored-by: John Kleinschmidt <kleinschmidtorama@gmail.com> * fixup! Enable network sandbox by default on Windows | https://chromium-review.googlesource.com/c/chromium/src/+/7204292 Co-authored-by: Keeley Hammond <khammond@slack-corp.com> * fixup!: Correct flag name, add kLocalNetworkAccessChecks to all platforms Co-authored-by: Keeley Hammond <khammond@slack-corp.com> * chore: remove patch that hasn't been backported See https://github.com/electron/electron/pull/48675 --------- Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com> Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com> Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org> Co-authored-by: Samuel Attard <sattard@anthropic.com> Co-authored-by: John Kleinschmidt <kleinschmidtorama@gmail.com> Co-authored-by: Keeley Hammond <khammond@slack-corp.com> Co-authored-by: Niklas Wenzel <dev@nikwen.de>
78 lines
3.5 KiB
Diff
78 lines
3.5 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Cheng Zhao <zcbenz@gmail.com>
|
|
Date: Thu, 20 Sep 2018 17:45:03 -0700
|
|
Subject: blink_local_frame.patch
|
|
|
|
According to electron/electron#3699, it is unreliable to use |unload|
|
|
event for process.exit('exit'), so we have to do that in
|
|
willReleaseScriptContext.
|
|
|
|
Refs changes in:
|
|
* https://codereview.chromium.org/1657583002
|
|
* https://chromium-review.googlesource.com/c/chromium/src/+/2596880
|
|
* https://chromium-review.googlesource.com/c/chromium/src/+/2597169
|
|
|
|
This patch reverts the changes to fix associated crashes in Electron.
|
|
|
|
diff --git a/third_party/blink/renderer/core/frame/frame.cc b/third_party/blink/renderer/core/frame/frame.cc
|
|
index 2670ea1361ccd8a9e3bac507e94dd25b7205ecf9..c12f78d925e4ccb4ac2fd3851a9c61e87058dc75 100644
|
|
--- a/third_party/blink/renderer/core/frame/frame.cc
|
|
+++ b/third_party/blink/renderer/core/frame/frame.cc
|
|
@@ -134,14 +134,6 @@ bool Frame::Detach(FrameDetachType type) {
|
|
|
|
DCHECK(!IsDetached());
|
|
|
|
- // TODO(dcheng): FocusController::FrameDetached() *should* fire JS events,
|
|
- // hence the above check for `client_` being null. However, when this was
|
|
- // previously placed before the `FrameDetached()` call, nothing crashes, which
|
|
- // is suspicious. Investigate if we really don't need to fire JS events--and
|
|
- // if we don't, move `forbid_scripts` up to be instantiated sooner and
|
|
- // simplify this code.
|
|
- ScriptForbiddenScope forbid_scripts;
|
|
-
|
|
if (type == FrameDetachType::kRemove) {
|
|
if (provisional_frame_) {
|
|
provisional_frame_->Detach(FrameDetachType::kRemove);
|
|
@@ -166,6 +158,14 @@ bool Frame::Detach(FrameDetachType type) {
|
|
GetWindowProxyManager()->ClearForSwap();
|
|
}
|
|
|
|
+ // TODO(dcheng): FocusController::FrameDetached() *should* fire JS events,
|
|
+ // hence the above check for `client_` being null. However, when this was
|
|
+ // previously placed before the `FrameDetached()` call, nothing crashes, which
|
|
+ // is suspicious. Investigate if we really don't need to fire JS events--and
|
|
+ // if we don't, move `forbid_scripts` up to be instantiated sooner and
|
|
+ // simplify this code.
|
|
+ ScriptForbiddenScope forbid_scripts;
|
|
+
|
|
// After this, we must no longer talk to the client since this clears
|
|
// its owning reference back to our owning LocalFrame.
|
|
client_->Detached(type);
|
|
diff --git a/third_party/blink/renderer/core/frame/local_frame.cc b/third_party/blink/renderer/core/frame/local_frame.cc
|
|
index 5ecfabc35eea65e17bcb13509186ac5d1db61021..cc1bccf5d168760532cc962ab7f7775e91255108 100644
|
|
--- a/third_party/blink/renderer/core/frame/local_frame.cc
|
|
+++ b/third_party/blink/renderer/core/frame/local_frame.cc
|
|
@@ -753,10 +753,6 @@ bool LocalFrame::DetachImpl(FrameDetachType type) {
|
|
}
|
|
DCHECK(!view_ || !view_->IsAttached());
|
|
|
|
- // This is the earliest that scripting can be disabled:
|
|
- // - FrameLoader::Detach() can fire XHR abort events
|
|
- // - Document::Shutdown() can dispose plugins which can run script.
|
|
- ScriptForbiddenScope forbid_script;
|
|
if (!Client())
|
|
return false;
|
|
|
|
@@ -810,6 +806,11 @@ bool LocalFrame::DetachImpl(FrameDetachType type) {
|
|
DCHECK(!view_->IsAttached());
|
|
Client()->WillBeDetached();
|
|
|
|
+ // This is the earliest that scripting can be disabled:
|
|
+ // - FrameLoader::Detach() can fire XHR abort events
|
|
+ // - Document::Shutdown() can dispose plugins which can run script.
|
|
+ ScriptForbiddenScope forbid_script;
|
|
+
|
|
// TODO(crbug.com/729196): Trace why LocalFrameView::DetachFromLayout crashes.
|
|
CHECK(!view_->IsAttached());
|
|
SetView(nullptr);
|