![trop[bot]](/assets/img/avatar_default.png)
* chore: bump chromium in DEPS to 140.0.7259.0 Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com> * chore: update patches Co-authored-by: deepak1556 <hop2deep@gmail.com> * Add fade in animation to Picture-in-Picture windows6538268
Co-authored-by: deepak1556 <hop2deep@gmail.com> * Use V8 Apis that don't return JSGlobalObject Refs https://issues.chromium.org/issues/333672197 Co-authored-by: deepak1556 <hop2deep@gmail.com> * chore: IWYU Co-authored-by: deepak1556 <hop2deep@gmail.com> * chore: bump chromium in DEPS to 140.0.7261.0 Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com> * chore: update patches Co-authored-by: deepak1556 <hop2deep@gmail.com> * revert: update to siso-chromium image Co-authored-by: deepak1556 <hop2deep@gmail.com> * Use v8::Object::WrapGlobal() Refs6650977
Co-authored-by: deepak1556 <hop2deep@gmail.com> * chore: IWYU Co-authored-by: deepak1556 <hop2deep@gmail.com> * chore: fix --trace-startup spec Co-authored-by: deepak1556 <hop2deep@gmail.com> --------- 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: deepak1556 <hop2deep@gmail.com>
29 lines
1.4 KiB
Diff
29 lines
1.4 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Samuel Attard <sattard@slack-corp.com>
|
|
Date: Mon, 8 Mar 2021 16:27:39 -0800
|
|
Subject: extend ApplyWebPreferences with Electron-specific logic
|
|
|
|
On macOS, popup menus are rendered by the main process by default.
|
|
This causes problems in OSR, since when the popup is rendered separately,
|
|
it won't be captured in the rendered image.
|
|
Offscreen can be updated at runtime, as such we need to apply the
|
|
turn on/off ExternalPopupMenu in the ApplyPreferences method.
|
|
There is no current way to attach an observer to these prefs so patching
|
|
is our only option.
|
|
|
|
Ideally we could add an embedder observer pattern here but that can be
|
|
done in future work.
|
|
|
|
diff --git a/third_party/blink/renderer/core/exported/web_view_impl.cc b/third_party/blink/renderer/core/exported/web_view_impl.cc
|
|
index 353c093d9fc15913dec6301cfc654c1a3a3fbc10..7163be14508786f67c3ea01cff9bc70c3692acac 100644
|
|
--- a/third_party/blink/renderer/core/exported/web_view_impl.cc
|
|
+++ b/third_party/blink/renderer/core/exported/web_view_impl.cc
|
|
@@ -1880,6 +1880,8 @@ void WebView::ApplyWebPreferences(const web_pref::WebPreferences& prefs,
|
|
#if BUILDFLAG(IS_MAC)
|
|
web_view_impl->SetMaximumLegibleScale(
|
|
prefs.default_maximum_page_scale_factor);
|
|
+ web_view_impl->GetChromeClient().SetUseExternalPopupMenusForTesting(
|
|
+ !prefs.offscreen);
|
|
#endif
|
|
|
|
#if BUILDFLAG(IS_WIN)
|