mirror of
https://github.com/electron/electron.git
synced 2026-01-09 15:38:08 -05:00
* chore: bump chromium in DEPS to 139.0.7205.0 * 6543986: Mac: decouple deserializing and applying sandbox policy Refs https://chromium-review.googlesource.com/c/chromium/src/+/6543986 * 6580079: Reland 'Remove the third-party blocking feature' Refs https://chromium-review.googlesource.com/c/chromium/src/+/6580079 * 6505716: guest-contents: Add components/guest_contents Refs https://chromium-review.googlesource.com/c/chromium/src/+/6505716 * 6572556: Move LogMessageManager out of gpu_service_impl.cc. Refs https://chromium-review.googlesource.com/c/chromium/src/+/6572556 * 6566111: Change UtilityProcessHost to manage its instance internally Refs https://chromium-review.googlesource.com/c/chromium/src/+/6566111 * 6550237: Rename ReconnectEventObserver to ConnectionChangeObserverClient Refs https://chromium-review.googlesource.com/c/chromium/src/+/6550237 * 6565918: Validate path is valid UTF8 in SelectFileDialogLinuxPortal Refs https://chromium-review.googlesource.com/c/chromium/src/+/6565918 * 6579713: Remove base::NotFatalUntil::M130 usage 6566111: Change UtilityProcessHost to manage its instance internally Refs https://chromium-review.googlesource.com/c/chromium/src/+/6579713 https://chromium-review.googlesource.com/c/chromium/src/+/6566111 * chore: update chromium patches * chore: update remaining patches * fixup! 6566111: Change UtilityProcessHost to manage its instance internally Refs https://chromium-review.googlesource.com/c/chromium/src/+/6566111 * 6577970: Remove superfluous includes for base/strings/stringprintf.h in headers Refs https://chromium-review.googlesource.com/c/chromium/src/+/6577970 * 6568811: Add FunctionCall structured metrics event for DevTools Refs https://chromium-review.googlesource.com/c/chromium/src/+/6568811 * [PDF Ink Signatures] Support PdfAnnotationsEnabled policy https://chromium-review.googlesource.com/c/chromium/src/+/6558970 * build: disable libcxx modules for rbe * chore: bump chromium in DEPS to 139.0.7217.0 * chore: bump chromium in DEPS to 139.0.7218.0 * chore: update patches fix_use_delegated_generic_capturer_when_available.patch was updated to handle a small change: 6582142: Use content::Create*Capturer in DesktopCaptureDevice. | https://chromium-review.googlesource.com/c/chromium/src/+/6582142 * chore: bump chromium in DEPS to 139.0.7219.0 * chore: update patches * 6594615: Change Chromium's deployment target to macOS 12 https://chromium-review.googlesource.com/c/chromium/src/+/6594615 Updated the assertion message to match the docs structure now too. I removed the callout to the supported versions doc because it has moved and doesn't contain minimum platform version information. * 6606232: [views] Remove DesktopWindowTreeHostWin::window_enlargement_ https://chromium-review.googlesource.com/c/chromium/src/+/6606232 |NativeWindow::GetContentMinimumSize| and |NativeWindow::GetContentMaximumSize| may be good opportunities for a refactor now. * add squirrel.mac patch for removed function This was triggered by the macOS 12.0 deployment upgrade change. See: https://developer.apple.com/documentation/coreservices/1444079-uttypeconformsto?language=objc * 6582142: Use content::Create*Capturer in DesktopCaptureDevice. https://chromium-review.googlesource.com/c/chromium/src/+/6582142 * 6579732: Two minor API "quality of life" cleanups in OSCrypt Async https://chromium-review.googlesource.com/c/chromium/src/+/6579732 * chore: add include for base::SingleThreadTaskRunner Not sure what change caused this, I expect it would be a removed include somewhere else, but it's likely not important to track down. * chore: update libcxx filenames * chore: update CI build-tools commit target for macOS SDK 15.4 The following change uses an API that was added in the macOS 15.4 SDK. Support for that SDK version was added later than the current build-tools commit target. 6575804: Use a quick-and-dirty solution to avoid glitching with paste-and-go | https://chromium-review.googlesource.com/c/chromium/src/+/6575804 See: https://developer.apple.com/documentation/appkit/nspasteboard/accessbehavior-swift.enum?language=objc * fixup! 6606232: [views] Remove DesktopWindowTreeHostWin::window_enlargement_ https://chromium-review.googlesource.com/c/chromium/src/+/6606232 * chore: bump chromium in DEPS to 139.0.7220.0 * chore: update patches Minor changes due to: 6613978: pwa: let events fall through in the transparent area of TopContainerView | https://chromium-review.googlesource.com/c/chromium/src/+/6613978 6614778: Refactor auto pip tab observer for Android support | https://chromium-review.googlesource.com/c/chromium/src/+/6614778 * 6543986: Mac: decouple deserializing and applying sandbox policy https://chromium-review.googlesource.com/c/chromium/src/+/6543986 The DecodeVarInt and DecodeString functions look benign from a MAS perspective. I suspect they were patched out to avoid "unused function" errors. Their complements for encoding are unpatched, supporting this idea. The code that uses these functions was refactored out of the section that we patch out. Instead of patching out that new function, I decided to treat it the same as the serialization function that is unpatched. * chore: bump chromium in DEPS to 139.0.7222.0 * chore: bump chromium in DEPS to 139.0.7224.0 * chore: bump chromium in DEPS to 139.0.7226.0 * chore: bump chromium in DEPS to 139.0.7228.0 * chore: update patches * Don't use static variable for UseExternalPopupMenus https://chromium-review.googlesource.com/c/chromium/src/+/6534657 * Reland "Roll libc++ from a01c02c9d4ac to a9cc573e7c59 https://chromium-review.googlesource.com/c/chromium/src/+/6607589 * chore: bump chromium in DEPS to 139.0.7219.0 * chore: update patches * revert Don't use static variable for UseExternalPopupMenus * tls: remove deprecated tls.createSecurePair and SecurePair https://github.com/nodejs/node/pull/57361 * Revert "Reland "Roll libc++ from a01c02c9d4ac to a9cc573e7c59" This reverts commit33e1436a0c. * test: cleanup api-desktop-capturer-spec.ts * test: more cleanup of api-desktop-capturer-spec.ts * chore: debug dcheck error in webrtc on linux * fixup patch * add debugging to desktop capturer spec * test: fixup api-desktop-capturer-spec.ts for linux * chore: remove debugging patch * Revert "fixup! 6606232: [views] Remove DesktopWindowTreeHostWin::window_enlargement_ https://chromium-review.googlesource.com/c/chromium/src/+/6606232" This reverts commit32e75651c1. * Revert "6606232: [views] Remove DesktopWindowTreeHostWin::window_enlargement_" This reverts commit89c51aa1c7. * [views] Remove DesktopWindowTreeHostWin::window_enlargement_ https://chromium-review.googlesource.com/c/chromium/src/+/6606232 Reverting as we need this functionality for now. * fixup: remove patch that was accidentally added back --------- Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com> Co-authored-by: Samuel Maddock <smaddock@slack-corp.com> Co-authored-by: deepak1556 <hop2deep@gmail.com> Co-authored-by: clavin <clavin@electronjs.org> Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
428 lines
24 KiB
Diff
428 lines
24 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Andy Locascio <andy@slack-corp.com>
|
|
Date: Wed, 9 Sep 2020 16:56:06 -0700
|
|
Subject: chore: provide IsWebContentsCreationOverridden with full params
|
|
|
|
Pending upstream patch, this gives us fuller access to the window.open params
|
|
so that we will be able to decide whether to cancel it or not.
|
|
|
|
diff --git a/chrome/browser/media/offscreen_tab.cc b/chrome/browser/media/offscreen_tab.cc
|
|
index 7a9effeec99682ef063ebe71f209e6ed9fc4cad4..71ef44be47a8665ee36449a38333ddf9cff33ad4 100644
|
|
--- a/chrome/browser/media/offscreen_tab.cc
|
|
+++ b/chrome/browser/media/offscreen_tab.cc
|
|
@@ -287,8 +287,7 @@ bool OffscreenTab::IsWebContentsCreationOverridden(
|
|
content::SiteInstance* source_site_instance,
|
|
content::mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) {
|
|
+ const content::mojom::CreateNewWindowParams& params) {
|
|
// Disallow creating separate WebContentses. The WebContents implementation
|
|
// uses this to spawn new windows/tabs, which is also not allowed for
|
|
// offscreen tabs.
|
|
diff --git a/chrome/browser/media/offscreen_tab.h b/chrome/browser/media/offscreen_tab.h
|
|
index 231e3595f218aeebe28d0b13ce6182e7a4d6f4e1..609bd205d1cd0404cab3471765bef8b0e053d061 100644
|
|
--- a/chrome/browser/media/offscreen_tab.h
|
|
+++ b/chrome/browser/media/offscreen_tab.h
|
|
@@ -108,8 +108,7 @@ class OffscreenTab final : public ProfileObserver,
|
|
content::SiteInstance* source_site_instance,
|
|
content::mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) final;
|
|
+ const content::mojom::CreateNewWindowParams& params) override;
|
|
void EnterFullscreenModeForTab(
|
|
content::RenderFrameHost* requesting_frame,
|
|
const blink::mojom::FullscreenOptions& options) final;
|
|
diff --git a/chrome/browser/ui/ash/keyboard/chrome_keyboard_web_contents.cc b/chrome/browser/ui/ash/keyboard/chrome_keyboard_web_contents.cc
|
|
index a17c406b59530a8f57f6cb48905a697dd208a41f..0e22e90c1d570eb4c86ac1f24c5a6e9159be8ea1 100644
|
|
--- a/chrome/browser/ui/ash/keyboard/chrome_keyboard_web_contents.cc
|
|
+++ b/chrome/browser/ui/ash/keyboard/chrome_keyboard_web_contents.cc
|
|
@@ -80,8 +80,7 @@ class ChromeKeyboardContentsDelegate : public content::WebContentsDelegate,
|
|
content::SiteInstance* source_site_instance,
|
|
content::mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) override {
|
|
+ const content::mojom::CreateNewWindowParams& params) override {
|
|
return true;
|
|
}
|
|
|
|
diff --git a/chrome/browser/ui/ash/web_view/ash_web_view_impl.cc b/chrome/browser/ui/ash/web_view/ash_web_view_impl.cc
|
|
index 08c84ca91f7e477e4e8d6370513d90d2fb9801f1..41e04444274f40fdedbf8d97bfd149f2ac682e53 100644
|
|
--- a/chrome/browser/ui/ash/web_view/ash_web_view_impl.cc
|
|
+++ b/chrome/browser/ui/ash/web_view/ash_web_view_impl.cc
|
|
@@ -121,10 +121,9 @@ bool AshWebViewImpl::IsWebContentsCreationOverridden(
|
|
content::SiteInstance* source_site_instance,
|
|
content::mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) {
|
|
+ const content::mojom::CreateNewWindowParams& params) {
|
|
if (params_.suppress_navigation) {
|
|
- NotifyDidSuppressNavigation(target_url,
|
|
+ NotifyDidSuppressNavigation(params.target_url,
|
|
WindowOpenDisposition::NEW_FOREGROUND_TAB,
|
|
/*from_user_gesture=*/true);
|
|
return true;
|
|
diff --git a/chrome/browser/ui/ash/web_view/ash_web_view_impl.h b/chrome/browser/ui/ash/web_view/ash_web_view_impl.h
|
|
index b6582b4013d9682d32bd524b4053b443a4df00f8..afcbce72e0f247b4d5a637b27c9f25d913cfa14b 100644
|
|
--- a/chrome/browser/ui/ash/web_view/ash_web_view_impl.h
|
|
+++ b/chrome/browser/ui/ash/web_view/ash_web_view_impl.h
|
|
@@ -60,8 +60,7 @@ class AshWebViewImpl : public ash::AshWebView,
|
|
content::SiteInstance* source_site_instance,
|
|
content::mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) override;
|
|
+ const content::mojom::CreateNewWindowParams& params) override;
|
|
content::WebContents* OpenURLFromTab(
|
|
content::WebContents* source,
|
|
const content::OpenURLParams& params,
|
|
diff --git a/chrome/browser/ui/browser.cc b/chrome/browser/ui/browser.cc
|
|
index 8d904b4690fc21d85683296667698a12a26e3ff2..1dd8f9932adb4683b6ab488baf66e76811da39af 100644
|
|
--- a/chrome/browser/ui/browser.cc
|
|
+++ b/chrome/browser/ui/browser.cc
|
|
@@ -2387,8 +2387,7 @@ bool Browser::IsWebContentsCreationOverridden(
|
|
content::SiteInstance* source_site_instance,
|
|
content::mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) {
|
|
+ const content::mojom::CreateNewWindowParams& params) {
|
|
if (IsActorCoordinatorActingOnTab(
|
|
profile(), content::WebContents::FromRenderFrameHost(opener))) {
|
|
// If an ActorCoordinator is acting on the opener, prevent it from creating
|
|
@@ -2400,7 +2399,7 @@ bool Browser::IsWebContentsCreationOverridden(
|
|
return (window_container_type ==
|
|
content::mojom::WindowContainerType::BACKGROUND &&
|
|
ShouldCreateBackgroundContents(source_site_instance, opener_url,
|
|
- frame_name));
|
|
+ params.frame));
|
|
}
|
|
|
|
WebContents* Browser::CreateCustomWebContents(
|
|
diff --git a/chrome/browser/ui/browser.h b/chrome/browser/ui/browser.h
|
|
index d6c08306e2413f8c40887ff5d01fa51332a71f9f..ae35953d1895a9481fc3eef69cd5905e1dcc8b79 100644
|
|
--- a/chrome/browser/ui/browser.h
|
|
+++ b/chrome/browser/ui/browser.h
|
|
@@ -1011,8 +1011,7 @@ class Browser : public TabStripModelObserver,
|
|
content::SiteInstance* source_site_instance,
|
|
content::mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) override;
|
|
+ const content::mojom::CreateNewWindowParams& params) override;
|
|
content::WebContents* CreateCustomWebContents(
|
|
content::RenderFrameHost* opener,
|
|
content::SiteInstance* source_site_instance,
|
|
diff --git a/chrome/browser/ui/media_router/presentation_receiver_window_controller.cc b/chrome/browser/ui/media_router/presentation_receiver_window_controller.cc
|
|
index a05510eadf5c9ff24bb7999aa76229946319280f..a80ecc46f8a6b84de83d608257d45ae61ccc2170 100644
|
|
--- a/chrome/browser/ui/media_router/presentation_receiver_window_controller.cc
|
|
+++ b/chrome/browser/ui/media_router/presentation_receiver_window_controller.cc
|
|
@@ -206,8 +206,7 @@ bool PresentationReceiverWindowController::IsWebContentsCreationOverridden(
|
|
content::SiteInstance* source_site_instance,
|
|
content::mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) {
|
|
+ const content::mojom::CreateNewWindowParams& params) {
|
|
// Disallow creating separate WebContentses. The WebContents implementation
|
|
// uses this to spawn new windows/tabs, which is also not allowed for
|
|
// local presentations.
|
|
diff --git a/chrome/browser/ui/media_router/presentation_receiver_window_controller.h b/chrome/browser/ui/media_router/presentation_receiver_window_controller.h
|
|
index 3fc06be01f20e8cd314d95d73a3f58c2f0742fe9..c07910ae59a185442f37ea6e7b96fdf3a33aba82 100644
|
|
--- a/chrome/browser/ui/media_router/presentation_receiver_window_controller.h
|
|
+++ b/chrome/browser/ui/media_router/presentation_receiver_window_controller.h
|
|
@@ -106,8 +106,7 @@ class PresentationReceiverWindowController final
|
|
content::SiteInstance* source_site_instance,
|
|
content::mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) override;
|
|
+ const content::mojom::CreateNewWindowParams& params) override;
|
|
|
|
// The profile used for the presentation.
|
|
raw_ptr<Profile, DanglingUntriaged> otr_profile_;
|
|
diff --git a/chrome/browser/ui/views/hats/hats_next_web_dialog.cc b/chrome/browser/ui/views/hats/hats_next_web_dialog.cc
|
|
index 2ca71613df0709a5cbee51f8be3eb37a66f9522c..6acba954a655321a161b9b66e1db5138d034489d 100644
|
|
--- a/chrome/browser/ui/views/hats/hats_next_web_dialog.cc
|
|
+++ b/chrome/browser/ui/views/hats/hats_next_web_dialog.cc
|
|
@@ -103,8 +103,7 @@ class HatsNextWebDialog::HatsWebView : public views::WebView {
|
|
content::SiteInstance* source_site_instance,
|
|
content::mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) override {
|
|
+ const content::mojom::CreateNewWindowParams& params) override {
|
|
return true;
|
|
}
|
|
content::WebContents* CreateCustomWebContents(
|
|
diff --git a/components/embedder_support/android/delegate/web_contents_delegate_android.cc b/components/embedder_support/android/delegate/web_contents_delegate_android.cc
|
|
index 807f43c164015e9372623b6ca9db1293640a530f..5e1875cde93f27e3d0324c84b94f076b33123495 100644
|
|
--- a/components/embedder_support/android/delegate/web_contents_delegate_android.cc
|
|
+++ b/components/embedder_support/android/delegate/web_contents_delegate_android.cc
|
|
@@ -199,14 +199,13 @@ bool WebContentsDelegateAndroid::IsWebContentsCreationOverridden(
|
|
content::SiteInstance* source_site_instance,
|
|
content::mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) {
|
|
+ const content::mojom::CreateNewWindowParams& params) {
|
|
JNIEnv* env = AttachCurrentThread();
|
|
ScopedJavaLocalRef<jobject> obj = GetJavaDelegate(env);
|
|
if (obj.is_null())
|
|
return false;
|
|
ScopedJavaLocalRef<jobject> java_gurl =
|
|
- url::GURLAndroid::FromNativeGURL(env, target_url);
|
|
+ url::GURLAndroid::FromNativeGURL(env, params.target_url.spec());
|
|
return !Java_WebContentsDelegateAndroid_shouldCreateWebContents(env, obj,
|
|
java_gurl);
|
|
}
|
|
diff --git a/components/embedder_support/android/delegate/web_contents_delegate_android.h b/components/embedder_support/android/delegate/web_contents_delegate_android.h
|
|
index 7a8cdc28f87399e494a58490cdc4ac0dd4b06520..0c2a83b44f6909b5b3a6303715e1611d039711bb 100644
|
|
--- a/components/embedder_support/android/delegate/web_contents_delegate_android.h
|
|
+++ b/components/embedder_support/android/delegate/web_contents_delegate_android.h
|
|
@@ -84,8 +84,7 @@ class WebContentsDelegateAndroid : public content::WebContentsDelegate {
|
|
content::SiteInstance* source_site_instance,
|
|
content::mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) override;
|
|
+ const content::mojom::CreateNewWindowParams& params) override;
|
|
void CloseContents(content::WebContents* source) override;
|
|
bool DidAddMessageToConsole(content::WebContents* source,
|
|
blink::mojom::ConsoleMessageLevel log_level,
|
|
diff --git a/components/offline_pages/content/background_loader/background_loader_contents.cc b/components/offline_pages/content/background_loader/background_loader_contents.cc
|
|
index 14f2758f2d71d4d4ba77e4fcb9be40bb878526e0..536db4f8fe9771b60f0359df5c680b298c89cad4 100644
|
|
--- a/components/offline_pages/content/background_loader/background_loader_contents.cc
|
|
+++ b/components/offline_pages/content/background_loader/background_loader_contents.cc
|
|
@@ -86,8 +86,7 @@ bool BackgroundLoaderContents::IsWebContentsCreationOverridden(
|
|
content::SiteInstance* source_site_instance,
|
|
content::mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) {
|
|
+ const content::mojom::CreateNewWindowParams& params) {
|
|
// Background pages should not create other webcontents/tabs.
|
|
return true;
|
|
}
|
|
diff --git a/components/offline_pages/content/background_loader/background_loader_contents.h b/components/offline_pages/content/background_loader/background_loader_contents.h
|
|
index b969f1d97b7e3396119b579cfbe61e19ff7d2dd4..b8d6169652da28266a514938b45b39c58df53573 100644
|
|
--- a/components/offline_pages/content/background_loader/background_loader_contents.h
|
|
+++ b/components/offline_pages/content/background_loader/background_loader_contents.h
|
|
@@ -66,8 +66,7 @@ class BackgroundLoaderContents : public content::WebContentsDelegate {
|
|
content::SiteInstance* source_site_instance,
|
|
content::mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) override;
|
|
+ const content::mojom::CreateNewWindowParams& params) override;
|
|
|
|
content::WebContents* AddNewContents(
|
|
content::WebContents* source,
|
|
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
|
|
index 04edc6c4b0eb218cecbaafac6916dee407a4797b..8f57a368af60d99421e22797abf6802678924ac4 100644
|
|
--- a/content/browser/web_contents/web_contents_impl.cc
|
|
+++ b/content/browser/web_contents/web_contents_impl.cc
|
|
@@ -5172,8 +5172,7 @@ FrameTree* WebContentsImpl::CreateNewWindow(
|
|
if (delegate_ &&
|
|
delegate_->IsWebContentsCreationOverridden(
|
|
opener, source_site_instance, params.window_container_type,
|
|
- opener->GetLastCommittedURL(), params.frame_name,
|
|
- params.target_url)) {
|
|
+ opener->GetLastCommittedURL(), params)) {
|
|
auto* web_contents_impl =
|
|
static_cast<WebContentsImpl*>(delegate_->CreateCustomWebContents(
|
|
opener, source_site_instance, is_new_browsing_instance,
|
|
diff --git a/content/public/browser/web_contents_delegate.cc b/content/public/browser/web_contents_delegate.cc
|
|
index f6ab6ab2b036c7621b429181c3ff89d9f1ff77f9..d151ba757ae81c6f023ee08328ab155405b0fb95 100644
|
|
--- a/content/public/browser/web_contents_delegate.cc
|
|
+++ b/content/public/browser/web_contents_delegate.cc
|
|
@@ -160,8 +160,7 @@ bool WebContentsDelegate::IsWebContentsCreationOverridden(
|
|
SiteInstance* source_site_instance,
|
|
mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) {
|
|
+ const mojom::CreateNewWindowParams& params) {
|
|
return false;
|
|
}
|
|
|
|
diff --git a/content/public/browser/web_contents_delegate.h b/content/public/browser/web_contents_delegate.h
|
|
index 83bdd195339eb7d61ac88e2994fd8dabe93f6ecc..682e5eecb7ce514094f76253447aa7ac4b6f29b1 100644
|
|
--- a/content/public/browser/web_contents_delegate.h
|
|
+++ b/content/public/browser/web_contents_delegate.h
|
|
@@ -359,8 +359,7 @@ class CONTENT_EXPORT WebContentsDelegate {
|
|
SiteInstance* source_site_instance,
|
|
mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url);
|
|
+ const mojom::CreateNewWindowParams& params);
|
|
|
|
// Allow delegate to creates a custom WebContents when
|
|
// WebContents::CreateNewWindow() is called. This function is only called
|
|
diff --git a/extensions/browser/guest_view/app_view/app_view_guest.cc b/extensions/browser/guest_view/app_view/app_view_guest.cc
|
|
index 0f2c21513e07e8ddb387c165754d7ec67942a719..c381abf67c261b92f1c65c485b69321f44080343 100644
|
|
--- a/extensions/browser/guest_view/app_view/app_view_guest.cc
|
|
+++ b/extensions/browser/guest_view/app_view/app_view_guest.cc
|
|
@@ -154,8 +154,7 @@ bool AppViewGuest::IsWebContentsCreationOverridden(
|
|
content::SiteInstance* source_site_instance,
|
|
content::mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) {
|
|
+ const content::mojom::CreateNewWindowParams& params) {
|
|
CHECK(!base::FeatureList::IsEnabled(features::kGuestViewMPArch));
|
|
|
|
return true;
|
|
diff --git a/extensions/browser/guest_view/app_view/app_view_guest.h b/extensions/browser/guest_view/app_view/app_view_guest.h
|
|
index 7695578f626f2a0c7fefae2bc1d5c35e5ac154f2..78958bff12ce41ae5ad77f43279a4b35b9408a12 100644
|
|
--- a/extensions/browser/guest_view/app_view/app_view_guest.h
|
|
+++ b/extensions/browser/guest_view/app_view/app_view_guest.h
|
|
@@ -10,6 +10,7 @@
|
|
#include "base/containers/id_map.h"
|
|
#include "base/values.h"
|
|
#include "components/guest_view/browser/guest_view.h"
|
|
+#include "content/common/frame.mojom-shared.h"
|
|
#include "extensions/browser/guest_view/app_view/app_view_guest_delegate.h"
|
|
#include "extensions/browser/lazy_context_task_queue.h"
|
|
|
|
@@ -80,8 +81,7 @@ class AppViewGuest : public guest_view::GuestView<AppViewGuest> {
|
|
content::SiteInstance* source_site_instance,
|
|
content::mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) final;
|
|
+ const content::mojom::CreateNewWindowParams& params) final;
|
|
content::WebContents* CreateCustomWebContents(
|
|
content::RenderFrameHost* opener,
|
|
content::SiteInstance* source_site_instance,
|
|
diff --git a/extensions/browser/guest_view/extension_options/extension_options_guest.cc b/extensions/browser/guest_view/extension_options/extension_options_guest.cc
|
|
index 5bd9d59a961a03f3cd3a806bc1af58c3eaee2b58..40d7ae8d6248163524a8c1350b625e107a8ae64a 100644
|
|
--- a/extensions/browser/guest_view/extension_options/extension_options_guest.cc
|
|
+++ b/extensions/browser/guest_view/extension_options/extension_options_guest.cc
|
|
@@ -263,8 +263,7 @@ bool ExtensionOptionsGuest::IsWebContentsCreationOverridden(
|
|
content::SiteInstance* source_site_instance,
|
|
content::mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) {
|
|
+ const content::mojom::CreateNewWindowParams& params) {
|
|
CHECK(!base::FeatureList::IsEnabled(features::kGuestViewMPArch));
|
|
|
|
// This method handles opening links from within the guest. Since this guest
|
|
diff --git a/extensions/browser/guest_view/extension_options/extension_options_guest.h b/extensions/browser/guest_view/extension_options/extension_options_guest.h
|
|
index 56d86e3d1179df2d5f34eb6216989aef2687f49f..236f3ccf8354b156737e03929ee538f99f1f4adf 100644
|
|
--- a/extensions/browser/guest_view/extension_options/extension_options_guest.h
|
|
+++ b/extensions/browser/guest_view/extension_options/extension_options_guest.h
|
|
@@ -74,8 +74,7 @@ class ExtensionOptionsGuest
|
|
content::SiteInstance* source_site_instance,
|
|
content::mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) final;
|
|
+ const content::mojom::CreateNewWindowParams& params) final;
|
|
content::WebContents* CreateCustomWebContents(
|
|
content::RenderFrameHost* opener,
|
|
content::SiteInstance* source_site_instance,
|
|
diff --git a/extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest.cc b/extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest.cc
|
|
index 0bba5f4b0abdaa55b7e406d39ccf3de33bf53194..ed4b8e0215a12adf95273109f7e4968d7b0cbf2a 100644
|
|
--- a/extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest.cc
|
|
+++ b/extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest.cc
|
|
@@ -453,8 +453,7 @@ bool MimeHandlerViewGuest::IsWebContentsCreationOverridden(
|
|
content::SiteInstance* source_site_instance,
|
|
content::mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) {
|
|
+ const content::mojom::CreateNewWindowParams& params) {
|
|
CHECK(!base::FeatureList::IsEnabled(features::kGuestViewMPArch));
|
|
|
|
return true;
|
|
diff --git a/extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest.h b/extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest.h
|
|
index 7eeffdfbda9611806c6f260f0c68f6d84689cb7e..5d8f6d132068d7fabaa52bc61354c71a8ac8cd20 100644
|
|
--- a/extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest.h
|
|
+++ b/extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest.h
|
|
@@ -187,8 +187,7 @@ class MimeHandlerViewGuest
|
|
content::SiteInstance* source_site_instance,
|
|
content::mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) override;
|
|
+ const content::mojom::CreateNewWindowParams& params) override;
|
|
content::WebContents* CreateCustomWebContents(
|
|
content::RenderFrameHost* opener,
|
|
content::SiteInstance* source_site_instance,
|
|
diff --git a/fuchsia_web/webengine/browser/frame_impl.cc b/fuchsia_web/webengine/browser/frame_impl.cc
|
|
index bd09d0f34a1610d64a1438b618ef5b3786315e91..4b2a979db1e00bc0d7f3b1b54570c305070acccc 100644
|
|
--- a/fuchsia_web/webengine/browser/frame_impl.cc
|
|
+++ b/fuchsia_web/webengine/browser/frame_impl.cc
|
|
@@ -581,8 +581,7 @@ bool FrameImpl::IsWebContentsCreationOverridden(
|
|
content::SiteInstance* source_site_instance,
|
|
content::mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) {
|
|
+ const content::mojom::CreateNewWindowParams& params) {
|
|
// Specify a generous upper bound for unacknowledged popup windows, so that we
|
|
// can catch bad client behavior while not interfering with normal operation.
|
|
constexpr size_t kMaxPendingWebContentsCount = 10;
|
|
diff --git a/fuchsia_web/webengine/browser/frame_impl.h b/fuchsia_web/webengine/browser/frame_impl.h
|
|
index 756d4192271d6a65cfe8e1511737c565b543cb1f..5688f6f745056565c3c01947f741c4d13e27b6ae 100644
|
|
--- a/fuchsia_web/webengine/browser/frame_impl.h
|
|
+++ b/fuchsia_web/webengine/browser/frame_impl.h
|
|
@@ -308,8 +308,7 @@ class WEB_ENGINE_EXPORT FrameImpl : public fuchsia::web::Frame,
|
|
content::SiteInstance* source_site_instance,
|
|
content::mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) override;
|
|
+ const content::mojom::CreateNewWindowParams& params) override;
|
|
void WebContentsCreated(content::WebContents* source_contents,
|
|
int opener_render_process_id,
|
|
int opener_render_frame_id,
|
|
diff --git a/headless/lib/browser/headless_web_contents_impl.cc b/headless/lib/browser/headless_web_contents_impl.cc
|
|
index b8f48c883d7adfd765b1561fd00e563ab54d20f5..0b3d8eef0ed0021d3546ff963e721eae277dcb1b 100644
|
|
--- a/headless/lib/browser/headless_web_contents_impl.cc
|
|
+++ b/headless/lib/browser/headless_web_contents_impl.cc
|
|
@@ -207,8 +207,7 @@ class HeadlessWebContentsImpl::Delegate : public content::WebContentsDelegate {
|
|
content::SiteInstance* source_site_instance,
|
|
content::mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) override {
|
|
+ const content::mojom::CreateNewWindowParams& params) override {
|
|
return headless_web_contents_->browser_context()
|
|
->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 42e0654da5659ba647529c4b0b97ec5df61d59a1..406e2ca73c182005014b56824e89ddfb25fd28f5 100644
|
|
--- a/ui/views/controls/webview/web_dialog_view.cc
|
|
+++ b/ui/views/controls/webview/web_dialog_view.cc
|
|
@@ -490,8 +490,7 @@ bool WebDialogView::IsWebContentsCreationOverridden(
|
|
content::SiteInstance* source_site_instance,
|
|
content::mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) {
|
|
+ const content::mojom::CreateNewWindowParams& params) {
|
|
if (delegate_) {
|
|
return delegate_->HandleShouldOverrideWebContentsCreation();
|
|
}
|
|
diff --git a/ui/views/controls/webview/web_dialog_view.h b/ui/views/controls/webview/web_dialog_view.h
|
|
index 0fa7e807d22f6f04b84f2d949fbdf892b94996bf..b0490ae36c9999a766bbf346e35807740f4f9af6 100644
|
|
--- a/ui/views/controls/webview/web_dialog_view.h
|
|
+++ b/ui/views/controls/webview/web_dialog_view.h
|
|
@@ -168,8 +168,7 @@ class WEBVIEW_EXPORT WebDialogView : public ClientView,
|
|
content::SiteInstance* source_site_instance,
|
|
content::mojom::WindowContainerType window_container_type,
|
|
const GURL& opener_url,
|
|
- const std::string& frame_name,
|
|
- const GURL& target_url) override;
|
|
+ const content::mojom::CreateNewWindowParams& params) override;
|
|
void RequestMediaAccessPermission(
|
|
content::WebContents* web_contents,
|
|
const content::MediaStreamRequest& request,
|