chore: bump chromium to 122.0.6261.6 (main) (#40949)

* chore: bump chromium in DEPS to 122.0.6239.2

* chore: update patches

* refactor: extensions replaced StringPiece with string_view

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/5171926

* chore: bump chromium in DEPS to 122.0.6240.0

* chore: update patches

* chore: bump chromium in DEPS to 122.0.6241.5

* chore: bump chromium in DEPS to 122.0.6245.0

* chore: bump chromium in DEPS to 122.0.6247.0

* chore: bump chromium in DEPS to 122.0.6249.0

* chore: bump chromium in DEPS to 122.0.6251.0

* 5192010: Rename {absl => std}::optional in //chrome/

https://chromium-review.googlesource.com/c/chromium/src/+/5192010

* 5109767: CodeHealth: Fix leaked raw_ptr in Linux ProcessSingleton

https://chromium-review.googlesource.com/c/chromium/src/+/5109767

* 5105227: [media_preview] Show requested device in permission bubble

https://chromium-review.googlesource.com/c/chromium/src/+/5105227

* chore: bump chromium in DEPS to 122.0.6253.0

* chore: update patches

* 5180720: Polish tiled browser window UI on Linux | https://chromium-review.googlesource.com/c/chromium/src/+/5180720

* chore: update patches

* chore: bump chromium in DEPS to 122.0.6255.0

* chore: update patches

* 5186276: [autopip] Make "allow once" per navigation | https://chromium-review.googlesource.com/c/chromium/src/+/5186276

* chore: bump chromium in DEPS to 122.0.6257.0

* chore: bump chromium in DEPS to 122.0.6259.0

* chore: update patches

* 5190661: Automated T* -> raw_ptr<T> rewrite "refresh" | https://chromium-review.googlesource.com/c/chromium/src/+/5190661

* 5206106: Make sure RenderFrameHosts are active when printing | https://chromium-review.googlesource.com/c/chromium/src/+/5206106

* 5202674: Reland "Automated T* -> raw_ptr<T> rewrite 'refresh'"

https://chromium-review.googlesource.com/c/chromium/src/+/5202674

* fixup CodeHealth: Fix leaked raw_ptr in Linux ProcessSingleton

https://chromium-review.googlesource.com/c/chromium/src/+/5109767

* fixup 5206106: Make sure RenderFrameHosts are active when printing

* Make legacy ToV8() helpers private to ScriptPromiseResolver, their only user

https://chromium-review.googlesource.com/c/chromium/src/+/5207474

* fixup CodeHealth: Fix leaked raw_ptr in Linux ProcessSingleton

* fixup 5186276: [autopip] Make "allow once" per navigation

https://chromium-review.googlesource.com/c/chromium/src/+/5186276

* chore: update patches after rebase

* chore: bump chromium in DEPS to 122.0.6260.0

* 5191363: Mark LOG(FATAL) [[noreturn]]

https://chromium-review.googlesource.com/c/chromium/src/+/5191363

* fixup 5186276: [autopip] Make "allow once" per navigation

https://chromium-review.googlesource.com/c/chromium/src/+/5186276

* fixup Make legacy ToV8() helpers private to ScriptPromiseResolver

 https://chromium-review.googlesource.com/c/chromium/src/+/5207474

* chore: update patches

* chore: bump chromium in DEPS to 122.0.6261.0

* chore: update patches

* chore: restore patch that was mistakenly removed

* 5181931: Improve LoginHandler (Part 9 / N)

https://chromium-review.googlesource.com/c/chromium/src/+/5181931

* Dispatch SiteInstanceGotProcess() only when both process and site are set.

https://chromium-review.googlesource.com/c/chromium/src/+/5142354

* 5171446: [AsyncSB] Pass navigation_id into CreateURLLoaderThrottles

https://chromium-review.googlesource.com/c/chromium/src/+/5171446

* 5213708: Move DownloadTargetInfo into components/download

https://chromium-review.googlesource.com/c/chromium/src/+/5213708

* extensions: Add a loader for Controlled Frame embedder scripts

https://chromium-review.googlesource.com/c/chromium/src/+/5202765

* [CSC][Zoom] Add initial_zoom_level to DisplayMediaInformation

https://chromium-review.googlesource.com/c/chromium/src/+/5168626

* chore: bump chromium in DEPS to 123.0.6262.0

* chore: bump chromium in DEPS to 122.0.6261.6

* fix: suppress clang -Wimplicit-const-int-float-conversion

* fixup 5191363: Mark LOG(FATAL) [[noreturn]] for Windows

 https://chromium-review.googlesource.com/c/chromium/src/+/5191363

* 5167921: Remove Widget::IsTranslucentWindowOpacitySupported

https://chromium-review.googlesource.com/c/chromium/src/+/5167921

Also
5148392: PinnedState: Support pinned state in PlatformWindowState | https://chromium-review.googlesource.com/c/chromium/src/+/5148392

* fixup: 5180720: Polish tiled browser window UI on Linux

https://chromium-review.googlesource.com/c/chromium/src/+/5180720

* 5170669: clipboard: Migrate DOMException constructors to RejectWith-

https://chromium-review.googlesource.com/c/chromium/src/+/5170669

* 5178824: [Fullscreen] Record UKM data

https://chromium-review.googlesource.com/c/chromium/src/+/5178824

* chore: update patches after rebase

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Samuel Attard <samuel.r.attard@gmail.com>
Co-authored-by: PatchUp <73610968+patchup[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
Co-authored-by: VerteDinde <vertedinde@electronjs.org>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
This commit is contained in:
electron-roller[bot] 2024-01-25 12:46:30 -05:00 коммит произвёл GitHub
Родитель 921da723b8
Коммит 1a0991a9b9
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: B5690EEEBB952194
99 изменённых файлов: 744 добавлений и 991 удалений

2
DEPS
Просмотреть файл

@ -2,7 +2,7 @@ gclient_gn_args_from = 'src'
vars = {
'chromium_version':
'122.0.6236.2',
'122.0.6261.6',
'node_version':
'v20.11.0',
'nan_version':

Просмотреть файл

@ -126,6 +126,5 @@ feat_allow_passing_of_objecttemplate_to_objecttemplatebuilder.patch
chore_remove_check_is_test_on_script_injection_tracker.patch
fix_restore_original_resize_performance_on_macos.patch
feat_allow_code_cache_in_custom_schemes.patch
enable_partition_alloc_ref_count_size.patch
build_run_reclient_cfg_generator_after_chrome.patch
fix_drag_regions_not_working_after_navigation_in_wco_app.patch
fix_suppress_clang_-wimplicit-const-int-float-conversion_in.patch

Просмотреть файл

@ -10,7 +10,7 @@ DidCreateScriptContext is called, not all JS APIs are available in the
context, which can cause some preload scripts to trip.
diff --git a/content/public/renderer/render_frame_observer.h b/content/public/renderer/render_frame_observer.h
index 79162faef6654f52651ffdff5705f7b27d2ae4f2..8148896d3f12772a1b4ba04601c57d9e5c386ce7 100644
index 2f05e37b8513bc28d199f81130e55063643a7c49..a03a0f4294843962c7c670c96c1df0027eab641f 100644
--- a/content/public/renderer/render_frame_observer.h
+++ b/content/public/renderer/render_frame_observer.h
@@ -146,6 +146,8 @@ class CONTENT_EXPORT RenderFrameObserver
@ -23,10 +23,10 @@ index 79162faef6654f52651ffdff5705f7b27d2ae4f2..8148896d3f12772a1b4ba04601c57d9e
int32_t world_id) {}
virtual void DidClearWindowObject() {}
diff --git a/content/renderer/render_frame_impl.cc b/content/renderer/render_frame_impl.cc
index 7697bf80f0c5ce35fae8eb015f8295cbbb384784..e3588346b73ef9ae253175ced52efc1e38009333 100644
index f5a6fde5af92e6a8258ac80e242f7ea21e946d1a..b53c0ad1e752428ab8df1356606e7b1add8c4ba0 100644
--- a/content/renderer/render_frame_impl.cc
+++ b/content/renderer/render_frame_impl.cc
@@ -4569,6 +4569,12 @@ void RenderFrameImpl::DidCreateScriptContext(v8::Local<v8::Context> context,
@@ -4582,6 +4582,12 @@ void RenderFrameImpl::DidCreateScriptContext(v8::Local<v8::Context> context,
observer.DidCreateScriptContext(context, world_id);
}
@ -40,10 +40,10 @@ index 7697bf80f0c5ce35fae8eb015f8295cbbb384784..e3588346b73ef9ae253175ced52efc1e
int world_id) {
for (auto& observer : observers_)
diff --git a/content/renderer/render_frame_impl.h b/content/renderer/render_frame_impl.h
index 28918e8a779d409b13ffb6ff2865eb6766ba3bcd..ffb3f014d85448c22212575540d59700f35a90e3 100644
index b229bc3ebfee7d8cb3c874b44a4bcc588f37c3ad..75e05f339a5877215e33c095e5714089d96a035a 100644
--- a/content/renderer/render_frame_impl.h
+++ b/content/renderer/render_frame_impl.h
@@ -635,6 +635,8 @@ class CONTENT_EXPORT RenderFrameImpl
@@ -638,6 +638,8 @@ class CONTENT_EXPORT RenderFrameImpl
void DidObserveLayoutShift(double score, bool after_input_or_scroll) override;
void DidCreateScriptContext(v8::Local<v8::Context> context,
int world_id) override;
@ -67,10 +67,10 @@ index 3bc8608e6954aa607c224665e7720d6580f35e22..b9e4ef7ae602b00131c3cafebb92fb98
virtual void WillReleaseScriptContext(v8::Local<v8::Context>,
int32_t world_id) {}
diff --git a/third_party/blink/renderer/bindings/core/v8/local_window_proxy.cc b/third_party/blink/renderer/bindings/core/v8/local_window_proxy.cc
index fd81b966a99b407d7704f204a09979d27c2bdfc1..92309e81b2e752cf779da88b272b0b7112d1c8d7 100644
index 28b22dd1ae04b404a6081f67306cec7c18ceff80..c15355bf971294b99e9bb484faad84ff760398eb 100644
--- a/third_party/blink/renderer/bindings/core/v8/local_window_proxy.cc
+++ b/third_party/blink/renderer/bindings/core/v8/local_window_proxy.cc
@@ -202,6 +202,7 @@ void LocalWindowProxy::Initialize() {
@@ -204,6 +204,7 @@ void LocalWindowProxy::Initialize() {
}
InstallConditionalFeatures();
@ -92,10 +92,10 @@ index 2709519d0bbf33548704c14a99324b504d27ccbf..aa3c2d3c1ea73da128616fe676ac09e2
int32_t world_id) = 0;
virtual bool AllowScriptExtensions() = 0;
diff --git a/third_party/blink/renderer/core/frame/local_frame_client_impl.cc b/third_party/blink/renderer/core/frame/local_frame_client_impl.cc
index 87b8cbdc3f799822e3138b29c8ad7cd553a51cc0..123d4039721ba8d96ca27d30b8204a191e1a945c 100644
index 6139aed9ebbb459d4d7027312c0f15b669fedfb6..db566ba272b1eff5e67547c5d82bf7420def7285 100644
--- a/third_party/blink/renderer/core/frame/local_frame_client_impl.cc
+++ b/third_party/blink/renderer/core/frame/local_frame_client_impl.cc
@@ -283,6 +283,13 @@ void LocalFrameClientImpl::DidCreateScriptContext(
@@ -289,6 +289,13 @@ void LocalFrameClientImpl::DidCreateScriptContext(
web_frame_->Client()->DidCreateScriptContext(context, world_id);
}
@ -123,10 +123,10 @@ index 8a16e37c32d29d21b0358f2a9dbe61b962d615a7..a1a73ebbeb0288f7e14280fa277451e0
int32_t world_id) override;
diff --git a/third_party/blink/renderer/core/loader/empty_clients.h b/third_party/blink/renderer/core/loader/empty_clients.h
index 33d568ea38f0de2c02a40c217ceaf8a711cddc47..47dab797a32b8832e9380c89cad92546233d9351 100644
index 3791d7d3dee7e84e096763f8b4fb3f8aacca96aa..e24d74982ffd7e338fe3870281b0d3d7b85a7cdf 100644
--- a/third_party/blink/renderer/core/loader/empty_clients.h
+++ b/third_party/blink/renderer/core/loader/empty_clients.h
@@ -409,6 +409,8 @@ class CORE_EXPORT EmptyLocalFrameClient : public LocalFrameClient {
@@ -410,6 +410,8 @@ class CORE_EXPORT EmptyLocalFrameClient : public LocalFrameClient {
void DidCreateScriptContext(v8::Local<v8::Context>,
int32_t world_id) override {}

Просмотреть файл

@ -8,62 +8,63 @@ decorations in maximized mode where needed, preventing empty space caused
by decoration shadows and rounded titlebars around the window while maximized.
diff --git a/ui/gtk/gtk_ui.cc b/ui/gtk/gtk_ui.cc
index a26cc74fc660c4d4873dd67e7c1c2b1223923ec8..6dfd2532bdd749adaeea820db0b88431f599a64a 100644
index 6fe20b867372362b6cdb847b9f3e84d9cabe8c9e..69176dd5d3356b5222caf0f34a3402e3235d657b 100644
--- a/ui/gtk/gtk_ui.cc
+++ b/ui/gtk/gtk_ui.cc
@@ -520,12 +520,13 @@ std::unique_ptr<ui::NavButtonProvider> GtkUi::CreateNavButtonProvider() {
return std::make_unique<gtk::NavButtonProviderGtk>();
@@ -521,11 +521,12 @@ std::unique_ptr<ui::NavButtonProvider> GtkUi::CreateNavButtonProvider() {
}
-ui::WindowFrameProvider* GtkUi::GetWindowFrameProvider(bool solid_frame) {
+ui::WindowFrameProvider* GtkUi::GetWindowFrameProvider(bool solid_frame, bool maximized) {
auto& provider =
- solid_frame ? solid_frame_provider_ : transparent_frame_provider_;
- if (!provider) {
- provider = std::make_unique<gtk::WindowFrameProviderGtk>(solid_frame);
- }
+ maximized
+ ? (solid_frame ? solid_maximized_frame_provider_ : transparent_maximized_frame_provider_)
+ : (solid_frame ? solid_frame_provider_ : transparent_frame_provider_);
+ if (!provider)
+ provider = std::make_unique<gtk::WindowFrameProviderGtk>(solid_frame, maximized);
ui::WindowFrameProvider* GtkUi::GetWindowFrameProvider(bool solid_frame,
- bool tiled) {
- auto& provider = frame_providers_[solid_frame][tiled];
+ bool tiled,
+ bool maximized) {
+ auto& provider = frame_providers_[solid_frame][tiled][maximized];
if (!provider) {
provider =
- std::make_unique<gtk::WindowFrameProviderGtk>(solid_frame, tiled);
+ std::make_unique<gtk::WindowFrameProviderGtk>(solid_frame, tiled, maximized);
}
return provider.get();
}
diff --git a/ui/gtk/gtk_ui.h b/ui/gtk/gtk_ui.h
index 38c1297588f30cc81d48cfd2321845815bb93ea5..0f4141d2146c38f054b060ddfa06a9f68ee2179c 100644
index 14e24ffcb183531eb9b3d426673b87f6af9b9241..7f3e058431c6dd2e32cd00fa7491d614ec4c48eb 100644
--- a/ui/gtk/gtk_ui.h
+++ b/ui/gtk/gtk_ui.h
@@ -110,7 +110,7 @@ class GtkUi : public ui::LinuxUiAndTheme {
bool PreferDarkTheme() const override;
@@ -111,7 +111,8 @@ class GtkUi : public ui::LinuxUiAndTheme {
void SetDarkTheme(bool dark) override;
std::unique_ptr<ui::NavButtonProvider> CreateNavButtonProvider() override;
- ui::WindowFrameProvider* GetWindowFrameProvider(bool solid_frame) override;
+ ui::WindowFrameProvider* GetWindowFrameProvider(bool solid_frame, bool maximized) override;
ui::WindowFrameProvider* GetWindowFrameProvider(bool solid_frame,
- bool tiled) override;
+ bool tiled,
+ bool maximized) override;
private:
using TintMap = std::map<int, color_utils::HSL>;
@@ -203,6 +203,8 @@ class GtkUi : public ui::LinuxUiAndTheme {
// while Chrome is running.
std::unique_ptr<ui::WindowFrameProvider> solid_frame_provider_;
std::unique_ptr<ui::WindowFrameProvider> transparent_frame_provider_;
+ std::unique_ptr<ui::WindowFrameProvider> solid_maximized_frame_provider_;
+ std::unique_ptr<ui::WindowFrameProvider> transparent_maximized_frame_provider_;
@@ -204,7 +205,7 @@ class GtkUi : public ui::LinuxUiAndTheme {
// while Chrome is running. This 2D array is indexed first by whether the
// frame is translucent (0) or solid(1), then by whether the frame is normal
// (0) or tiled (1).
- std::unique_ptr<ui::WindowFrameProvider> frame_providers_[2][2];
+ std::unique_ptr<ui::WindowFrameProvider> frame_providers_[2][2][2];
// Objects to notify when the window frame button order changes.
base::ObserverList<ui::WindowButtonOrderObserver>::Unchecked
diff --git a/ui/gtk/window_frame_provider_gtk.cc b/ui/gtk/window_frame_provider_gtk.cc
index a739dbab82f4b5b221f27364ccaa5daf2161a059..e2c47d50b64c2e994b3e63a3fc671504ce928964 100644
index 794efdb773422ddc12ccbe013a13aadeb980b487..a60bbd76141f06202343c68e78688a95179b0083 100644
--- a/ui/gtk/window_frame_provider_gtk.cc
+++ b/ui/gtk/window_frame_provider_gtk.cc
@@ -41,17 +41,20 @@ std::string GetThemeName() {
return theme_string;
}
@@ -30,20 +30,23 @@ constexpr int kMaxFrameSizeDip = 64;
// will get an incorrect hint as to which pixels are fully opaque.
constexpr int kMaxCornerRadiusDip = 32;
-GtkCssContext WindowContext(bool solid_frame, bool focused) {
+GtkCssContext WindowContext(bool solid_frame, bool maximized, bool focused) {
-GtkCssContext WindowContext(bool solid_frame, bool tiled, bool focused) {
+GtkCssContext WindowContext(bool solid_frame, bool tiled, bool maximized, bool focused) {
std::string selector = "window.background.";
selector += solid_frame ? "solid-csd" : "csd";
if (tiled) {
selector += ".tiled";
}
+ if (maximized) {
+ selector += ".maximized";
+ }
@ -73,141 +74,143 @@ index a739dbab82f4b5b221f27364ccaa5daf2161a059..e2c47d50b64c2e994b3e63a3fc671504
return AppendCssNodeToStyleContext({}, selector);
}
-GtkCssContext DecorationContext(bool solid_frame, bool focused) {
- auto context = WindowContext(solid_frame, focused);
+GtkCssContext DecorationContext(bool solid_frame, bool maximized, bool focused) {
+ auto context = WindowContext(solid_frame, maximized, focused);
-GtkCssContext DecorationContext(bool solid_frame, bool tiled, bool focused) {
- auto context = WindowContext(solid_frame, tiled, focused);
+GtkCssContext DecorationContext(bool solid_frame, bool tiled, bool maximized, bool focused) {
+ auto context = WindowContext(solid_frame, tiled, maximized, focused);
// GTK4 renders the decoration directly on the window.
if (!GtkCheckVersion(4)) {
context = AppendCssNodeToStyleContext(context, "decoration");
@@ -70,8 +73,8 @@ GtkCssContext DecorationContext(bool solid_frame, bool focused) {
@@ -62,8 +65,8 @@ GtkCssContext DecorationContext(bool solid_frame, bool tiled, bool focused) {
return context;
}
-GtkCssContext HeaderContext(bool solid_frame, bool focused) {
- auto context = WindowContext(solid_frame, focused);
+GtkCssContext HeaderContext(bool solid_frame, bool maximized, bool focused) {
+ auto context = WindowContext(solid_frame, maximized, focused);
-GtkCssContext HeaderContext(bool solid_frame, bool tiled, bool focused) {
- auto context = WindowContext(solid_frame, tiled, focused);
+GtkCssContext HeaderContext(bool solid_frame, bool tiled, bool maximized, bool focused) {
+ auto context = WindowContext(solid_frame, tiled, maximized, focused);
context =
AppendCssNodeToStyleContext(context, "headerbar.header-bar.titlebar");
if (!focused) {
@@ -128,8 +131,8 @@ int ComputeTopCornerRadius() {
@@ -120,8 +123,8 @@ int ComputeTopCornerRadius() {
// need to experimentally determine the corner radius by rendering a sample.
// Additionally, in GTK4, the headerbar corners get clipped by the window
// rather than the headerbar having its own rounded corners.
- auto context = GtkCheckVersion(4) ? DecorationContext(false, false)
- : HeaderContext(false, false);
+ auto context = GtkCheckVersion(4) ? DecorationContext(false, false, false)
+ : HeaderContext(false, false, false);
- auto context = GtkCheckVersion(4) ? DecorationContext(false, false, false)
- : HeaderContext(false, false, false);
+ auto context = GtkCheckVersion(4) ? DecorationContext(false, false, false, false)
+ : HeaderContext(false, false, false, false);
ApplyCssToContext(context, R"(window, headerbar {
background-image: none;
background-color: black;
@@ -163,7 +166,7 @@ int ComputeTopCornerRadius() {
@@ -155,7 +158,7 @@ int ComputeTopCornerRadius() {
bool HeaderIsTranslucent() {
// The arbitrary square size to render a sample header.
constexpr int kHeaderSize = 32;
- auto context = HeaderContext(false, false);
+ auto context = HeaderContext(false, false, false);
- auto context = HeaderContext(false, false, false);
+ auto context = HeaderContext(false, false, false, false);
double opacity = GetOpacityFromContext(context);
if (opacity < 1.0) {
return true;
@@ -220,8 +223,8 @@ void WindowFrameProviderGtk::Asset::CloneFrom(
@@ -206,8 +209,8 @@ void WindowFrameProviderGtk::Asset::CloneFrom(
unfocused_bitmap = src.unfocused_bitmap;
}
-WindowFrameProviderGtk::WindowFrameProviderGtk(bool solid_frame)
- : solid_frame_(solid_frame) {}
+WindowFrameProviderGtk::WindowFrameProviderGtk(bool solid_frame, bool maximized)
+ : solid_frame_(solid_frame), maximized_(maximized) {}
-WindowFrameProviderGtk::WindowFrameProviderGtk(bool solid_frame, bool tiled)
- : solid_frame_(solid_frame), tiled_(tiled) {
+WindowFrameProviderGtk::WindowFrameProviderGtk(bool solid_frame, bool tiled, bool maximized)
+ : solid_frame_(solid_frame), tiled_(tiled), maximized_(maximized) {
GtkSettings* settings = gtk_settings_get_default();
// Unretained() is safe since WindowFrameProviderGtk will own the signals.
auto callback = base::BindRepeating(&WindowFrameProviderGtk::OnThemeChanged,
@@ -325,7 +328,7 @@ void WindowFrameProviderGtk::PaintWindowFrame(gfx::Canvas* canvas,
WindowFrameProviderGtk::~WindowFrameProviderGtk() = default;
@@ -330,7 +333,7 @@ void WindowFrameProviderGtk::PaintWindowFrame(
const int top_area_height_px = top_area_bottom_px - client_bounds_px.y();
auto header = PaintHeaderbar({client_bounds_px.width(), top_area_height_px},
- HeaderContext(solid_frame_, focused), scale);
+ HeaderContext(solid_frame_, maximized_, focused), scale);
auto header =
PaintHeaderbar({client_bounds_px.width(), top_area_height_px},
- HeaderContext(solid_frame_, tiled_, focused), scale);
+ HeaderContext(solid_frame_, tiled_, maximized_, focused), scale);
image = gfx::ImageSkia::CreateFrom1xBitmap(header);
// In GTK4, the headerbar gets clipped by the window.
if (GtkCheckVersion(4)) {
@@ -363,7 +366,7 @@ void WindowFrameProviderGtk::MaybeUpdateBitmaps(float scale) {
@@ -352,7 +355,7 @@ void WindowFrameProviderGtk::MaybeUpdateBitmaps(float scale) {
gfx::Rect frame_bounds_dip(kMaxFrameSizeDip, kMaxFrameSizeDip,
2 * kMaxFrameSizeDip, 2 * kMaxFrameSizeDip);
- auto focused_context = DecorationContext(solid_frame_, true);
+ auto focused_context = DecorationContext(solid_frame_, maximized_, true);
- auto focused_context = DecorationContext(solid_frame_, tiled_, true);
+ auto focused_context = DecorationContext(solid_frame_, tiled_, maximized_, true);
frame_bounds_dip.Inset(-GtkStyleContextGetPadding(focused_context));
frame_bounds_dip.Inset(-GtkStyleContextGetBorder(focused_context));
gfx::Size bitmap_size(BitmapSizePx(asset), BitmapSizePx(asset));
@@ -371,7 +374,7 @@ void WindowFrameProviderGtk::MaybeUpdateBitmaps(float scale) {
@@ -360,7 +363,7 @@ void WindowFrameProviderGtk::MaybeUpdateBitmaps(float scale) {
focused_context, scale);
asset.unfocused_bitmap =
PaintBitmap(bitmap_size, gfx::RectF(frame_bounds_dip),
- DecorationContext(solid_frame_, false), scale);
+ DecorationContext(solid_frame_, maximized_, false), scale);
- DecorationContext(solid_frame_, tiled_, false), scale);
+ DecorationContext(solid_frame_, tiled_, maximized_, false), scale);
// In GTK4, there's no way to obtain the frame thickness from CSS values
// directly, so we must determine it experimentally based on the drawn
diff --git a/ui/gtk/window_frame_provider_gtk.h b/ui/gtk/window_frame_provider_gtk.h
index 32c3d63ae4598339965c58443a8c2d12b99fb89a..91496d957b8291cd37948e237a1cc4bf605848b0 100644
index 91236ec07c01ca14248b997577ae887c0c396cd2..d70639d2ba40e325bbbbf6117741c13354984ed5 100644
--- a/ui/gtk/window_frame_provider_gtk.h
+++ b/ui/gtk/window_frame_provider_gtk.h
@@ -14,7 +14,7 @@ namespace gtk {
@@ -18,7 +18,7 @@ namespace gtk {
class WindowFrameProviderGtk : public ui::WindowFrameProvider {
public:
- explicit WindowFrameProviderGtk(bool solid_frame);
+ explicit WindowFrameProviderGtk(bool solid_frame, bool maximized);
- WindowFrameProviderGtk(bool solid_frame, bool tiled);
+ WindowFrameProviderGtk(bool solid_frame, bool tiled, bool maximized);
WindowFrameProviderGtk(const WindowFrameProviderGtk&) = delete;
WindowFrameProviderGtk& operator=(const WindowFrameProviderGtk&) = delete;
@@ -72,6 +72,9 @@ class WindowFrameProviderGtk : public ui::WindowFrameProvider {
// Cached bitmaps and metrics. The scale is rounded to percent.
base::flat_map<int, Asset> assets_;
+
@@ -70,6 +70,8 @@ class WindowFrameProviderGtk : public ui::WindowFrameProvider {
// Input parameters used for drawing.
const bool solid_frame_;
const bool tiled_;
+ // Whether to draw the window decorations as maximized.
+ bool maximized_;
};
+ const bool maximized_;
} // namespace gtk
// Scale-independent metric calculated based on the bitmaps.
gfx::Insets frame_thickness_dip_;
diff --git a/ui/linux/fallback_linux_ui.cc b/ui/linux/fallback_linux_ui.cc
index 2b67f6ebcae4f0495b73c750e73250921fa0ac04..796b44df8c8b9a63ba97e28f14e457d724c8ae50 100644
index 3e8f30a90b8623dd00b882fb4dd1467d1a91689e..711b646621ba0bdabd15aef8929bdf48e0e52f88 100644
--- a/ui/linux/fallback_linux_ui.cc
+++ b/ui/linux/fallback_linux_ui.cc
@@ -135,7 +135,7 @@ FallbackLinuxUi::CreateNavButtonProvider() {
}
@@ -136,7 +136,8 @@ FallbackLinuxUi::CreateNavButtonProvider() {
ui::WindowFrameProvider* FallbackLinuxUi::GetWindowFrameProvider(
- bool solid_frame) {
+ bool solid_frame, bool maximized) {
bool solid_frame,
- bool tiled) {
+ bool tiled,
+ bool maximized) {
return nullptr;
}
diff --git a/ui/linux/fallback_linux_ui.h b/ui/linux/fallback_linux_ui.h
index 9a6a5a7f21c318d3009df1766a7789f9c7597339..9454e8f8e622a5b92f980fdf6c1f68d6c4795cf7 100644
index 1de7b4a16637b2d719f0162f43af48dfc9af5d6a..61a75cd3e3226e115bbcd5b7837d3e2d9c1e8d65 100644
--- a/ui/linux/fallback_linux_ui.h
+++ b/ui/linux/fallback_linux_ui.h
@@ -68,7 +68,7 @@ class FallbackLinuxUi : public LinuxUiAndTheme {
bool PreferDarkTheme() const override;
@@ -69,7 +69,8 @@ class FallbackLinuxUi : public LinuxUiAndTheme {
void SetDarkTheme(bool dark) override;
std::unique_ptr<ui::NavButtonProvider> CreateNavButtonProvider() override;
- ui::WindowFrameProvider* GetWindowFrameProvider(bool solid_frame) override;
+ ui::WindowFrameProvider* GetWindowFrameProvider(bool solid_frame, bool maximized) override;
ui::WindowFrameProvider* GetWindowFrameProvider(bool solid_frame,
- bool tiled) override;
+ bool tiled,
+ bool maximized) override;
private:
std::string default_font_family_;
diff --git a/ui/linux/linux_ui.h b/ui/linux/linux_ui.h
index 9cc65cf5713464e5964e9aa2109c281055e5b70f..014d1145e44e5e9420846476d4349070c78852d0 100644
index 69f678a91012f92351a9d487700316d432248e53..b43f2c977091ed2de695ea0fc1707d5ba4afe092 100644
--- a/ui/linux/linux_ui.h
+++ b/ui/linux/linux_ui.h
@@ -316,7 +316,7 @@ class COMPONENT_EXPORT(LINUX_UI) LinuxUiTheme {
// if transparency is unsupported and the frame should be rendered opaque.
@@ -317,7 +317,8 @@ class COMPONENT_EXPORT(LINUX_UI) LinuxUiTheme {
// The returned object is not owned by the caller and will remain alive until
// the process ends.
- virtual WindowFrameProvider* GetWindowFrameProvider(bool solid_frame) = 0;
+ virtual WindowFrameProvider* GetWindowFrameProvider(bool solid_frame, bool maximized) = 0;
virtual WindowFrameProvider* GetWindowFrameProvider(bool solid_frame,
- bool tiled) = 0;
+ bool tiled,
+ bool maximized) = 0;
protected:
LinuxUiTheme();

Просмотреть файл

@ -30,7 +30,7 @@ index 23b17b4a46a31cb005e36bb1bbadba6cc3ea6b3c..b86862dcf5232fc6971293fe2c9f17c9
} // namespace blink
diff --git a/third_party/blink/renderer/core/exported/web_message_port_converter.cc b/third_party/blink/renderer/core/exported/web_message_port_converter.cc
index 6a6cb3d4ef0e454d18cf47cd971240d0dabea9fb..10ea1b43e5caa7c6c0f6c9ff5182a712ca422f9b 100644
index 6a6cb3d4ef0e454d18cf47cd971240d0dabea9fb..bd90d018d5c3e33a41b17b1d015ac25d340f8666 100644
--- a/third_party/blink/renderer/core/exported/web_message_port_converter.cc
+++ b/third_party/blink/renderer/core/exported/web_message_port_converter.cc
@@ -6,6 +6,7 @@
@ -53,7 +53,7 @@ index 6a6cb3d4ef0e454d18cf47cd971240d0dabea9fb..10ea1b43e5caa7c6c0f6c9ff5182a712
+ CHECK(execution_context);
+ auto* port = MakeGarbageCollected<MessagePort>(*execution_context);
+ port->Entangle(std::move(port_channel));
+ return ToV8(port, context->Global(), context->GetIsolate());
+ return port->ToV8(context->GetIsolate(), context->Global());
+}
+
} // namespace blink

Просмотреть файл

@ -6,7 +6,7 @@ Subject: allow disabling blink scheduler throttling per RenderView
This allows us to disable throttling for hidden windows.
diff --git a/content/browser/renderer_host/navigation_controller_impl_unittest.cc b/content/browser/renderer_host/navigation_controller_impl_unittest.cc
index ed1cd91f4ec979f5a194a110ce9fc6ae3459cd09..812534c3834094f762b81daea204c85eea89e235 100644
index c32059af794851fdea8aae15157f05acdcc60e0a..92340d0aa8d893fc781ed59cc4aa51b5543de6d9 100644
--- a/content/browser/renderer_host/navigation_controller_impl_unittest.cc
+++ b/content/browser/renderer_host/navigation_controller_impl_unittest.cc
@@ -163,6 +163,12 @@ class MockPageBroadcast : public blink::mojom::PageBroadcast {
@ -23,10 +23,10 @@ index ed1cd91f4ec979f5a194a110ce9fc6ae3459cd09..812534c3834094f762b81daea204c85e
return receiver_.BindNewEndpointAndPassDedicatedRemote();
}
diff --git a/content/browser/renderer_host/render_view_host_impl.cc b/content/browser/renderer_host/render_view_host_impl.cc
index dc10b3766c512a60a454194b5a11906eeb73e47e..de4506f124bce0e7094a1c10945a9c6508c32b2a 100644
index caa732b8f72d30b5dd87c40d02039d79dbf4b413..a760db11ecb79534345fe78ae83bc6bda977db9e 100644
--- a/content/browser/renderer_host/render_view_host_impl.cc
+++ b/content/browser/renderer_host/render_view_host_impl.cc
@@ -713,6 +713,11 @@ void RenderViewHostImpl::SetBackgroundOpaque(bool opaque) {
@@ -712,6 +712,11 @@ void RenderViewHostImpl::SetBackgroundOpaque(bool opaque) {
GetWidget()->GetAssociatedFrameWidget()->SetBackgroundOpaque(opaque);
}
@ -39,7 +39,7 @@ index dc10b3766c512a60a454194b5a11906eeb73e47e..de4506f124bce0e7094a1c10945a9c65
return is_active();
}
diff --git a/content/browser/renderer_host/render_view_host_impl.h b/content/browser/renderer_host/render_view_host_impl.h
index afd5368ffd7c7ef5db6e30b7468554d8ec07c77a..1b0c498edd71987f004bc20e9d7957cca6526edd 100644
index a94977d7a76ae9952bbba0efe59a7cb5021a1c84..11c4f890eaeae1329ca5a6634a698aef7a288fb4 100644
--- a/content/browser/renderer_host/render_view_host_impl.h
+++ b/content/browser/renderer_host/render_view_host_impl.h
@@ -139,6 +139,7 @@ class CONTENT_EXPORT RenderViewHostImpl
@ -51,10 +51,10 @@ index afd5368ffd7c7ef5db6e30b7468554d8ec07c77a..1b0c498edd71987f004bc20e9d7957cc
void SendRendererPreferencesToRenderer(
const blink::RendererPreferences& preferences);
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 a967365095f3ca4c1b57b0dcbfa8b148a5e1e683..54ae10307c6ceea27046b9bd7b1a1322b331d954 100644
index d78f00cbb877b64892b9871252d79796fd4cabb8..4d2de00328f0b6437789612b14a53aae79eb15ab 100644
--- a/content/browser/renderer_host/render_widget_host_view_aura.cc
+++ b/content/browser/renderer_host/render_widget_host_view_aura.cc
@@ -563,8 +563,8 @@ void RenderWidgetHostViewAura::ShowImpl(PageVisibilityState page_visibility) {
@@ -559,8 +559,8 @@ void RenderWidgetHostViewAura::ShowImpl(PageVisibilityState page_visibility) {
// OnShowWithPageVisibility will not call NotifyHostAndDelegateOnWasShown,
// which updates `visibility_`, unless the host is hidden. Make sure no update
// is needed.
@ -80,7 +80,7 @@ index 9979c25ecd57e68331b628a518368635db5c2027..f65bfbbb663a5bb0511ffa389d3163e0
// This interface should only be implemented inside content.
friend class RenderViewHostImpl;
diff --git a/content/test/test_page_broadcast.h b/content/test/test_page_broadcast.h
index cb660e85d7ed08496483bc7b857b5f273efb94d3..2f9b3937106c1927b38bc43a641fa982044874d3 100644
index 603798ae0d45836f1bf3e6608761ce1467303310..2d8caa06e418f123d7565b96d40c66fb51617a6d 100644
--- a/content/test/test_page_broadcast.h
+++ b/content/test/test_page_broadcast.h
@@ -50,6 +50,7 @@ class TestPageBroadcast : public blink::mojom::PageBroadcast {
@ -116,7 +116,7 @@ index 2ba868f0efb2ee082d452bb011409f1b4c5c5e1e..6caab2df3cfc367c63839b7ac635d8d0
// Visibility -----------------------------------------------------------
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 56856aea2bdfa54d6589da27937a96e9b89d24f1..a6714774b3fd35c0f34f37ab27163bfc920a8212 100644
index aafdfd4fffd0bf18a1444202e9f92f63bd458997..1b1628b5ba7b6920e149f881e8d5086ac9be0132 100644
--- a/third_party/blink/renderer/core/exported/web_view_impl.cc
+++ b/third_party/blink/renderer/core/exported/web_view_impl.cc
@@ -2421,6 +2421,10 @@ void WebViewImpl::SetPageLifecycleStateInternal(
@ -155,7 +155,7 @@ index 56856aea2bdfa54d6589da27937a96e9b89d24f1..a6714774b3fd35c0f34f37ab27163bfc
// Do not throttle if the page should be painting.
bool is_visible =
diff --git a/third_party/blink/renderer/core/exported/web_view_impl.h b/third_party/blink/renderer/core/exported/web_view_impl.h
index ae8bc75679ad4064ea0bb19f36e3b8224db9d738..c227b904fef4acc76a4af50263ab9d4fa35472e2 100644
index 25566d1e5a3671c698e7352bc7600005a8bfcf3c..8dfb3b5b9026df92e28271258870c9eb588a6526 100644
--- a/third_party/blink/renderer/core/exported/web_view_impl.h
+++ b/third_party/blink/renderer/core/exported/web_view_impl.h
@@ -453,6 +453,7 @@ class CORE_EXPORT WebViewImpl final : public WebView,
@ -166,7 +166,7 @@ index ae8bc75679ad4064ea0bb19f36e3b8224db9d738..c227b904fef4acc76a4af50263ab9d4f
void SetVisibilityState(mojom::blink::PageVisibilityState visibility_state,
bool is_initial_state) override;
mojom::blink::PageVisibilityState GetVisibilityState() override;
@@ -924,6 +925,8 @@ class CORE_EXPORT WebViewImpl final : public WebView,
@@ -927,6 +928,8 @@ class CORE_EXPORT WebViewImpl final : public WebView,
// If true, we send IPC messages when |preferred_size_| changes.
bool send_preferred_size_changes_ = false;

Просмотреть файл

@ -6,7 +6,7 @@ Subject: allow new privileges in unsandboxed child processes
This allows unsandboxed child process to launch setuid processes on Linux.
diff --git a/content/browser/child_process_launcher_helper_linux.cc b/content/browser/child_process_launcher_helper_linux.cc
index 321faab043958d4be412f7b1f50931d0d9d42886..94d18b775d432cfeeb4d2db6091adda179dc6e6b 100644
index e21cd3f9c447d67299c034e2b9f212f251c5deca..795ad47165f2f02e816f424ce74391a435c61a32 100644
--- a/content/browser/child_process_launcher_helper_linux.cc
+++ b/content/browser/child_process_launcher_helper_linux.cc
@@ -63,6 +63,15 @@ bool ChildProcessLauncherHelper::BeforeLaunchOnLauncherThread(

Просмотреть файл

@ -49,10 +49,10 @@ index a1732d9bf9267e52a74350483fa946b5a0a0662b..25d36b301309ac9f8c1a4d75545fa741
// 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 12941f34625d8578c2fed5f1d19529b09a3c544b..3964559a7caf7657a134d8a69d1587084e0ecfbb 100644
index 7585e65fabd7374309bdf165830038305ea5a538..c7547b2e7bae19db54635834a52116ec654629d6 100644
--- a/third_party/blink/renderer/core/frame/local_frame.cc
+++ b/third_party/blink/renderer/core/frame/local_frame.cc
@@ -674,10 +674,6 @@ bool LocalFrame::DetachImpl(FrameDetachType type) {
@@ -672,10 +672,6 @@ bool LocalFrame::DetachImpl(FrameDetachType type) {
}
DCHECK(!view_ || !view_->IsAttached());
@ -63,7 +63,7 @@ index 12941f34625d8578c2fed5f1d19529b09a3c544b..3964559a7caf7657a134d8a69d158708
if (!Client())
return false;
@@ -725,6 +721,11 @@ bool LocalFrame::DetachImpl(FrameDetachType type) {
@@ -723,6 +719,11 @@ bool LocalFrame::DetachImpl(FrameDetachType type) {
DCHECK(!view_->IsAttached());
Client()->WillBeDetached();

Просмотреть файл

@ -6,7 +6,7 @@ Subject: boringssl BUILD.gn
Build BoringSSL with some extra functions that nodejs needs.
diff --git a/third_party/boringssl/BUILD.gn b/third_party/boringssl/BUILD.gn
index bd3979751ce110a3086625efb743362293bb0006..f888810423c8a42a9811efdff295f90b130bfee1 100644
index e342a39e8d4a8d178baf90bfe0b355d08b51f776..a820b342e553d58b1967c0deefdf1b6ae333babd 100644
--- a/third_party/boringssl/BUILD.gn
+++ b/third_party/boringssl/BUILD.gn
@@ -56,6 +56,21 @@ config("no_asm_config") {

Просмотреть файл

@ -11,10 +11,10 @@ if we ever align our .pak file generation with Chrome we can remove this
patch.
diff --git a/chrome/BUILD.gn b/chrome/BUILD.gn
index 3611378c052813bd9c9ab9ce7d1840d6535576bf..b148e0acaf28197ee1da634b5e4c449ffcc30ddc 100644
index d09e7aeb788550e7ecefb4b9c177dd26ecc5ad4c..c894dc421f55a94e541d00e05e2f05bfec907ab1 100644
--- a/chrome/BUILD.gn
+++ b/chrome/BUILD.gn
@@ -200,11 +200,16 @@ if (!is_android && !is_mac && !is_fuchsia) {
@@ -195,11 +195,16 @@ if (!is_android && !is_mac && !is_fuchsia) {
"common/crash_keys.h",
]
@ -33,10 +33,10 @@ index 3611378c052813bd9c9ab9ce7d1840d6535576bf..b148e0acaf28197ee1da634b5e4c449f
"//base",
"//build:branding_buildflags",
diff --git a/chrome/browser/BUILD.gn b/chrome/browser/BUILD.gn
index 9e7f057a1c35d3e6ba3f144cfaf7dfe0ff1148a8..b2b2c49e745530b35b6ee7df080426afa4c64989 100644
index 81dceec0b449c6fa90984f0bede8d3b94a93910a..32e5194b60f7db1d076e2ba3a884cce4e3133b02 100644
--- a/chrome/browser/BUILD.gn
+++ b/chrome/browser/BUILD.gn
@@ -4746,7 +4746,7 @@ static_library("browser") {
@@ -4755,7 +4755,7 @@ static_library("browser") {
# On Windows, the hashes are embedded in //chrome:chrome_initial rather
# than here in :chrome_dll.
@ -46,10 +46,10 @@ index 9e7f057a1c35d3e6ba3f144cfaf7dfe0ff1148a8..b2b2c49e745530b35b6ee7df080426af
sources += [ "certificate_viewer_stub.cc" ]
}
diff --git a/chrome/test/BUILD.gn b/chrome/test/BUILD.gn
index f56b2c37e6176e3d796db6a0d75b9388691a1b1c..4f5b716570e8e235699c90b44ce14b367469e994 100644
index 005e321b191e69422c892c2001ffc98f9e198d14..e02717f068247e0c971e19374b8c2d2d0809fc5b 100644
--- a/chrome/test/BUILD.gn
+++ b/chrome/test/BUILD.gn
@@ -7190,7 +7190,6 @@ if (!is_fuchsia) {
@@ -7220,7 +7220,6 @@ if (!is_fuchsia) {
deps += [
"//chrome:other_version",
@ -57,7 +57,7 @@ index f56b2c37e6176e3d796db6a0d75b9388691a1b1c..4f5b716570e8e235699c90b44ce14b36
"//chrome//services/util_win:unit_tests",
"//chrome/app:chrome_dll_resources",
"//chrome/app:win_unit_tests",
@@ -7211,6 +7210,10 @@ if (!is_fuchsia) {
@@ -7241,6 +7240,10 @@ if (!is_fuchsia) {
"//ui/resources",
]
@ -68,7 +68,7 @@ index f56b2c37e6176e3d796db6a0d75b9388691a1b1c..4f5b716570e8e235699c90b44ce14b36
ldflags = [
"/DELAYLOAD:api-ms-win-core-winrt-error-l1-1-0.dll",
"/DELAYLOAD:api-ms-win-core-winrt-l1-1-0.dll",
@@ -8231,7 +8234,6 @@ if (!is_fuchsia) {
@@ -8259,7 +8262,6 @@ if (!is_fuchsia) {
}
deps += [
@ -76,7 +76,7 @@ index f56b2c37e6176e3d796db6a0d75b9388691a1b1c..4f5b716570e8e235699c90b44ce14b36
"//chrome/browser/apps:icon_standardizer",
"//chrome/browser/apps/app_service",
"//chrome/browser/apps/app_service:app_registry_cache_waiter",
@@ -8324,6 +8326,10 @@ if (!is_fuchsia) {
@@ -8352,6 +8354,10 @@ if (!is_fuchsia) {
"//ui/webui/resources/js/browser_command:mojo_bindings",
]

Просмотреть файл

@ -7,7 +7,7 @@ Build libc++ as static library to compile and pass
nan tests
diff --git a/buildtools/third_party/libc++/BUILD.gn b/buildtools/third_party/libc++/BUILD.gn
index 4670c3b237aedcf930e718584cba6ce2ca505e62..57690c86fe78a4c2e692f0865919dd50e458b02d 100644
index 70d0876e5a5351b81005a3cf5ffd7f7d3143db2e..a7a39d74d311797263fe25a8df295dc6178fdc7a 100644
--- a/buildtools/third_party/libc++/BUILD.gn
+++ b/buildtools/third_party/libc++/BUILD.gn
@@ -45,7 +45,11 @@ config("winver") {

Просмотреть файл

@ -6,7 +6,7 @@ Subject: build: make libcxx_abi_unstable false for electron
https://nornagon.medium.com/a-libc-odyssey-973e51649063
diff --git a/buildtools/third_party/libc++/__config_site b/buildtools/third_party/libc++/__config_site
index 6c1f0aecbc0425ebbf0f718abc58bc763c25b1a9..4af673d3041fe6fb74eb65fda588edf791c98eca 100644
index 1ae42c3a02cf5929b358a6fff3dd523fc24f444e..cc81747b1ad34e3d0b29f45d275be829dd3503ff 100644
--- a/buildtools/third_party/libc++/__config_site
+++ b/buildtools/third_party/libc++/__config_site
@@ -12,7 +12,6 @@

Просмотреть файл

@ -9,10 +9,10 @@ This patch can be removed when we decide how we want to handle
enterprise content analysis.
diff --git a/components/enterprise/buildflags/buildflags.gni b/components/enterprise/buildflags/buildflags.gni
index 90658d1d090b5edd15339a7ca0f9ba4c0a341891..7d38d08c8ff51854deca9614176ec40dc50ad076 100644
index cbfe3299d44d0f34ebd1459f61707172753874f3..1ff8921df54e32396225f52d001bbf85c703a5cd 100644
--- a/components/enterprise/buildflags/buildflags.gni
+++ b/components/enterprise/buildflags/buildflags.gni
@@ -34,4 +34,4 @@ declare_args() {
@@ -41,4 +41,4 @@ declare_args() {
# These two flags are equivalent, but `enable_print_content_analysis` still
# needs to exist separately as it lives under //printing which cannot depend
# on //components.

Просмотреть файл

@ -10,10 +10,10 @@ This can't be upstreamed though may be replaceable later with some upstream refa
around reclient config generation.
diff --git a/buildtools/reclient_cfgs/configure_reclient_cfgs.py b/buildtools/reclient_cfgs/configure_reclient_cfgs.py
index 35aaf829ae998b52ca2ae21450a66f2c53fd457c..ecd46ccb33c5a8fe1cae526081a3bd1aa997cf81 100755
index 1aa4693d79fff57c96636d0513dcbd17c52f16f2..e62889f2e41b3dba2ce2d9113887123ccbb5ee73 100755
--- a/buildtools/reclient_cfgs/configure_reclient_cfgs.py
+++ b/buildtools/reclient_cfgs/configure_reclient_cfgs.py
@@ -317,4 +317,13 @@ def main():
@@ -328,4 +328,13 @@ def main():
if __name__ == "__main__":

Просмотреть файл

@ -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 980582453b8b269b75fde409cdf0101809097a74..6f5076ea646d356946c4789143fdbec538150051 100644
index 9b37b8a18c5c09aaf76590f53060cab3190d676f..0a095cfd413f8cb7f30f8b143b29e5e829898ad0 100644
--- a/content/browser/renderer_host/render_frame_host_impl.cc
+++ b/content/browser/renderer_host/render_frame_host_impl.cc
@@ -8225,6 +8225,7 @@ void RenderFrameHostImpl::CreateNewWindow(
@@ -8272,6 +8272,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,10 +21,10 @@ index 980582453b8b269b75fde409cdf0101809097a74..6f5076ea646d356946c4789143fdbec5
&no_javascript_access);
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
index c9222aedf46fce9cd5ba332825dd832da730caa9..38b5a462873a48d37ea11b1a3d41da46ef63284a 100644
index 21815a78d24295c9bcaef5b133dd9ded47d1070a..e9ce07551ccd183cb205aedba787b3a9700e2a2b 100644
--- a/content/browser/web_contents/web_contents_impl.cc
+++ b/content/browser/web_contents/web_contents_impl.cc
@@ -4497,6 +4497,12 @@ FrameTree* WebContentsImpl::CreateNewWindow(
@@ -4516,6 +4516,12 @@ FrameTree* WebContentsImpl::CreateNewWindow(
auto* new_contents_impl = new_contents.get();
@ -37,7 +37,7 @@ index c9222aedf46fce9cd5ba332825dd832da730caa9..38b5a462873a48d37ea11b1a3d41da46
// If the new frame has a name, make sure any SiteInstances that can find
// this named frame have proxies for it. Must be called after
// SetSessionStorageNamespace, since this calls CreateRenderView, which uses
@@ -4538,12 +4544,6 @@ FrameTree* WebContentsImpl::CreateNewWindow(
@@ -4557,12 +4563,6 @@ FrameTree* WebContentsImpl::CreateNewWindow(
AddWebContentsDestructionObserver(new_contents_impl);
}
@ -51,10 +51,10 @@ index c9222aedf46fce9cd5ba332825dd832da730caa9..38b5a462873a48d37ea11b1a3d41da46
new_contents_impl, opener, params.target_url,
params.referrer.To<Referrer>(), params.disposition,
diff --git a/content/common/frame.mojom b/content/common/frame.mojom
index ecdc75ae7888096922fb1ae1c86e9b80595d6570..feb8f08b44568f2c09359c8f3ec343fdec2615de 100644
index 3051e35ee43835113aafd8645daca12d31e873e1..53cbd6008101e8ae6851f8da9d4e6537400ca608 100644
--- a/content/common/frame.mojom
+++ b/content/common/frame.mojom
@@ -609,6 +609,10 @@ struct CreateNewWindowParams {
@@ -603,6 +603,10 @@ struct CreateNewWindowParams {
// The navigation initiator's user activation and ad status.
blink.mojom.NavigationInitiatorActivationAndAdStatus
initiator_activation_and_ad_status;
@ -66,10 +66,10 @@ index ecdc75ae7888096922fb1ae1c86e9b80595d6570..feb8f08b44568f2c09359c8f3ec343fd
// Operation result when the renderer asks the browser to create a new window.
diff --git a/content/public/browser/content_browser_client.cc b/content/public/browser/content_browser_client.cc
index e7127ba48f8508a42cdfd9aabf88c353739419ea..39114bd91b4589a66544dd6aee579bc9dde79c7f 100644
index d004abc6fe3da01d605be1d7138d1809e4616662..7cef4b0c29e1b537cd172e19609744aaf4d90a11 100644
--- a/content/public/browser/content_browser_client.cc
+++ b/content/public/browser/content_browser_client.cc
@@ -709,6 +709,8 @@ bool ContentBrowserClient::CanCreateWindow(
@@ -710,6 +710,8 @@ bool ContentBrowserClient::CanCreateWindow(
const std::string& frame_name,
WindowOpenDisposition disposition,
const blink::mojom::WindowFeatures& features,
@ -79,7 +79,7 @@ index e7127ba48f8508a42cdfd9aabf88c353739419ea..39114bd91b4589a66544dd6aee579bc9
bool opener_suppressed,
bool* no_javascript_access) {
diff --git a/content/public/browser/content_browser_client.h b/content/public/browser/content_browser_client.h
index 8d975e6cd75caedcbd5a276618c29867467a50c8..51cf95131a2637e5fd4ff2b22a258231db9e1528 100644
index d0a5dbc45467019aba2d185187ebb16879775dc4..dbeebb4ed9aa1fcba31cc2ce7e2031a483f7f1fe 100644
--- a/content/public/browser/content_browser_client.h
+++ b/content/public/browser/content_browser_client.h
@@ -182,6 +182,7 @@ class NetworkService;
@ -90,7 +90,7 @@ index 8d975e6cd75caedcbd5a276618c29867467a50c8..51cf95131a2637e5fd4ff2b22a258231
} // namespace network
namespace sandbox {
@@ -1160,6 +1161,8 @@ class CONTENT_EXPORT ContentBrowserClient {
@@ -1166,6 +1167,8 @@ class CONTENT_EXPORT ContentBrowserClient {
const std::string& frame_name,
WindowOpenDisposition disposition,
const blink::mojom::WindowFeatures& features,
@ -100,7 +100,7 @@ index 8d975e6cd75caedcbd5a276618c29867467a50c8..51cf95131a2637e5fd4ff2b22a258231
bool opener_suppressed,
bool* no_javascript_access);
diff --git a/content/public/browser/web_contents_delegate.cc b/content/public/browser/web_contents_delegate.cc
index 8c0e628124ad6068d95935ac4960f2d744adb3fd..aa401c609d1062cfd4149bbd7677f66a2554c3b4 100644
index 55afe83e3052afb40176cb8ab6e974013e207ff5..4f9e32610e7e2c97c486be8693bd357b0d3e29f8 100644
--- a/content/public/browser/web_contents_delegate.cc
+++ b/content/public/browser/web_contents_delegate.cc
@@ -30,6 +30,17 @@ namespace content {
@ -122,7 +122,7 @@ index 8c0e628124ad6068d95935ac4960f2d744adb3fd..aa401c609d1062cfd4149bbd7677f66a
const OpenURLParams& params) {
return nullptr;
diff --git a/content/public/browser/web_contents_delegate.h b/content/public/browser/web_contents_delegate.h
index 4b32bf8ccc4ed370e2d1a218ae1fd69a98e23636..b9168a2488f5c4977eba5856882b561e07195c7f 100644
index 0a80169aa10cf956e53df5866719fd27437dd050..c34e8d3822fa5aafb351a6b2119c7d49b283a4b0 100644
--- a/content/public/browser/web_contents_delegate.h
+++ b/content/public/browser/web_contents_delegate.h
@@ -16,6 +16,7 @@
@ -148,10 +148,10 @@ index 4b32bf8ccc4ed370e2d1a218ae1fd69a98e23636..b9168a2488f5c4977eba5856882b561e
// typically happens when popups are created.
virtual void WebContentsCreated(WebContents* source_contents,
diff --git a/content/renderer/render_frame_impl.cc b/content/renderer/render_frame_impl.cc
index f9d31235bebe8855b8f7698f9c0d3a1d92f77303..7697bf80f0c5ce35fae8eb015f8295cbbb384784 100644
index 07bb68687683ac1458080659471212473d9e966a..f5a6fde5af92e6a8258ac80e242f7ea21e946d1a 100644
--- a/content/renderer/render_frame_impl.cc
+++ b/content/renderer/render_frame_impl.cc
@@ -6556,6 +6556,10 @@ WebView* RenderFrameImpl::CreateNewWindow(
@@ -6573,6 +6573,10 @@ WebView* RenderFrameImpl::CreateNewWindow(
request.HasUserGesture(), GetWebFrame()->IsAdFrame(),
GetWebFrame()->IsAdScriptInStack());
@ -163,7 +163,7 @@ index f9d31235bebe8855b8f7698f9c0d3a1d92f77303..7697bf80f0c5ce35fae8eb015f8295cb
// moved on send.
bool is_background_tab =
diff --git a/content/web_test/browser/web_test_content_browser_client.cc b/content/web_test/browser/web_test_content_browser_client.cc
index bb2a4c21374db039eeb7ed10722933b155cdf486..00a117d18b69180ece2b1b65f92aad02ef045a86 100644
index 3b2947c0e67e5478af6ff6bf9c8826398998713e..0220384453018b5509d02d78eb2a33d02719d3c7 100644
--- a/content/web_test/browser/web_test_content_browser_client.cc
+++ b/content/web_test/browser/web_test_content_browser_client.cc
@@ -512,6 +512,8 @@ bool WebTestContentBrowserClient::CanCreateWindow(
@ -176,7 +176,7 @@ index bb2a4c21374db039eeb7ed10722933b155cdf486..00a117d18b69180ece2b1b65f92aad02
bool opener_suppressed,
bool* no_javascript_access) {
diff --git a/content/web_test/browser/web_test_content_browser_client.h b/content/web_test/browser/web_test_content_browser_client.h
index cc7eb097097e44a0538853c46bb19810eb5a076c..74ecd32f27cd5e1ead4ab507d2b68a1088ba827f 100644
index 1b60d72c3728956e3879248d17cce0d93fc15c8f..f7c9ee76f3cc6545f97982493cf60c4e63217b95 100644
--- a/content/web_test/browser/web_test_content_browser_client.h
+++ b/content/web_test/browser/web_test_content_browser_client.h
@@ -88,6 +88,8 @@ class WebTestContentBrowserClient : public ShellContentBrowserClient {
@ -210,10 +210,10 @@ index bef5a989bac50c177f15f52fe87ac3790d553e85..65dcd2e3b51929400c8bfb6a98a4fb59
} // namespace blink
diff --git a/third_party/blink/renderer/core/frame/local_dom_window.cc b/third_party/blink/renderer/core/frame/local_dom_window.cc
index 533b96d14e0e4599b0a404eb2f74bce6fb12f983..378640bfa4bc6adabd34f2ee759e60a8ea376e72 100644
index 9f0640197516a86ff24bc07bf3fdb87416f2c1e3..09ed4fddc03094760f9e38b421504958a02e261b 100644
--- a/third_party/blink/renderer/core/frame/local_dom_window.cc
+++ b/third_party/blink/renderer/core/frame/local_dom_window.cc
@@ -2203,6 +2203,8 @@ DOMWindow* LocalDOMWindow::open(v8::Isolate* isolate,
@@ -2208,6 +2208,8 @@ DOMWindow* LocalDOMWindow::open(v8::Isolate* isolate,
WebWindowFeatures window_features =
GetWindowFeaturesFromString(features, entered_window);

Просмотреть файл

@ -9,7 +9,7 @@ This is an experimental commit; but if it's successful,
This patch should be upstreamed and then removed from electron's code.
diff --git a/chrome/browser/ui/views/frame/browser_view.h b/chrome/browser/ui/views/frame/browser_view.h
index d028fb25d8f095243a2ff07a799091159d081679..708c47987973c9267ff4cab7781a1d923e91d268 100644
index f3f5944785e5e19c1c51e6a123ff459ec768d8b8..8314178cd18cc07ecd54d90216c1eaac7aab97e8 100644
--- a/chrome/browser/ui/views/frame/browser_view.h
+++ b/chrome/browser/ui/views/frame/browser_view.h
@@ -43,7 +43,6 @@

Просмотреть файл

@ -18,7 +18,7 @@ index 2f9164594b1bbf9f6d7af875ab65ee0cb24b1227..4c969db1812ef64647e9d8f139961911
/googleurl
/gpu/gles2_conform_test
diff --git a/third_party/.gitignore b/third_party/.gitignore
index b3a55406876238186561a16a1d0c1170703b0fc8..f34f5340ae4dc682f5ada66e0217372e26c35e82 100644
index 563c82b850ab9559c65719f3619a42feaed1fd69..9b6d8256ae1a8b92d4790da59fee4f8fa8df8411 100644
--- a/third_party/.gitignore
+++ b/third_party/.gitignore
@@ -51,6 +51,7 @@
@ -37,7 +37,7 @@ index b3a55406876238186561a16a1d0c1170703b0fc8..f34f5340ae4dc682f5ada66e0217372e
/ninja/ninja*
/node/*.tar.gz
/node/linux/
@@ -147,6 +149,7 @@
@@ -148,6 +150,7 @@
/soda-win64
/speex
/sqlite4java/lib/

Просмотреть файл

@ -7,10 +7,10 @@ With WCO, allow chromium to handle synthetic mouse events generated for touch
actions in the non-client caption area.
diff --git a/ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc b/ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc
index a51018a455c114d9c3b15dd2628e6ab6bfc3da38..1fec1bfa23c5ae67317b6f4c2bc8f341f3eb1d85 100644
index e8a6da6bdb14eea3217a6824163364958552ba44..9949d73b85b5110711689c5ee3f8ba1a493cc976 100644
--- a/ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc
+++ b/ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc
@@ -1226,6 +1226,10 @@ void DesktopWindowTreeHostWin::HandleHeadlessWindowBoundsChanged(
@@ -1222,6 +1222,10 @@ void DesktopWindowTreeHostWin::HandleHeadlessWindowBoundsChanged(
window()->SetProperty(aura::client::kHeadlessBoundsKey, bounds);
}
@ -22,10 +22,10 @@ index a51018a455c114d9c3b15dd2628e6ab6bfc3da38..1fec1bfa23c5ae67317b6f4c2bc8f341
DesktopWindowTreeHostWin::GetSingletonDesktopNativeCursorManager() {
return new DesktopNativeCursorManagerWin();
diff --git a/ui/views/widget/desktop_aura/desktop_window_tree_host_win.h b/ui/views/widget/desktop_aura/desktop_window_tree_host_win.h
index 013f571b521682e3f3381fd9fabc6e949d624fa3..5b1cacf1e9ce082712762785cc9bfe2fe8269f2e 100644
index e963c861f7099f1b3873ece621e12917a7b181e5..dc02d69861292282fe88ea68a62fafaaffb0ef74 100644
--- a/ui/views/widget/desktop_aura/desktop_window_tree_host_win.h
+++ b/ui/views/widget/desktop_aura/desktop_window_tree_host_win.h
@@ -262,6 +262,7 @@ class VIEWS_EXPORT DesktopWindowTreeHostWin
@@ -261,6 +261,7 @@ class VIEWS_EXPORT DesktopWindowTreeHostWin
void HandleWindowSizeUnchanged() override;
void HandleWindowScaleFactorChanged(float window_scale_factor) override;
void HandleHeadlessWindowBoundsChanged(const gfx::Rect& bounds) override;

Просмотреть файл

@ -7,7 +7,7 @@ This patch comes after Chromium removed the ScopedAllowIO API in favor
of explicitly adding ScopedAllowBlocking calls as friends.
diff --git a/base/threading/thread_restrictions.h b/base/threading/thread_restrictions.h
index 53775a0aa1350ee433e3b23530fb0e246e575d2f..4e056adb25e0a32bc85fb16debe7844966d51f10 100644
index 310851d978cada04c7d9d8938b28ed3062ded7d5..1e71b6235f9ac6fc9294d8ca8d9602fdfc048770 100644
--- a/base/threading/thread_restrictions.h
+++ b/base/threading/thread_restrictions.h
@@ -135,6 +135,7 @@ class KeyStorageLinux;
@ -28,7 +28,7 @@ index 53775a0aa1350ee433e3b23530fb0e246e575d2f..4e056adb25e0a32bc85fb16debe78449
namespace enterprise_connectors {
class LinuxKeyRotationCommand;
} // namespace enterprise_connectors
@@ -564,6 +568,7 @@ class BASE_EXPORT [[maybe_unused, nodiscard]] ScopedAllowBlocking {
@@ -572,6 +576,7 @@ class BASE_EXPORT [[maybe_unused, nodiscard]] ScopedAllowBlocking {
friend class ::DesktopNotificationBalloon;
friend class ::FirefoxProfileLock;
friend class ::GaiaConfig;
@ -36,7 +36,7 @@ index 53775a0aa1350ee433e3b23530fb0e246e575d2f..4e056adb25e0a32bc85fb16debe78449
friend class ::ProfileImpl;
friend class ::ScopedAllowBlockingForProfile;
friend class ::StartupTabProviderImpl;
@@ -602,6 +607,7 @@ class BASE_EXPORT [[maybe_unused, nodiscard]] ScopedAllowBlocking {
@@ -611,6 +616,7 @@ class BASE_EXPORT [[maybe_unused, nodiscard]] ScopedAllowBlocking {
friend class crosapi::LacrosThreadTypeDelegate;
friend class crypto::ScopedAllowBlockingForNSS; // http://crbug.com/59847
friend class drive::FakeDriveService;

Просмотреть файл

@ -14,7 +14,7 @@ This change patches it out to prevent the DCHECK.
It can be removed once/if we see a better solution to the problem.
diff --git a/content/browser/site_instance_impl.cc b/content/browser/site_instance_impl.cc
index 357b8e4d89b769e02ab18f0749832c897fa69c68..c3f903f40c816cd89a21519a13c9f798611f8ec6 100644
index c7cb7a275e885b049e8dd171fe15e1ce356ac6a4..91a19974c6ec14317c1b030f41091733dc7ebae9 100644
--- a/content/browser/site_instance_impl.cc
+++ b/content/browser/site_instance_impl.cc
@@ -211,7 +211,7 @@ scoped_refptr<SiteInstanceImpl> SiteInstanceImpl::CreateForGuest(

Просмотреть файл

@ -9,7 +9,7 @@ Electron does not support Profiles, so this Profile::FromBrowserContext()
call is not needed and will not link. This change patches it out.
diff --git a/chrome/browser/pdf/chrome_pdf_stream_delegate.cc b/chrome/browser/pdf/chrome_pdf_stream_delegate.cc
index 8d697fcca4fbbc37218c81bb2120e3ce64831cc4..efe0a26077abb4d13686f2bec0567be947184ea9 100644
index 928d4739c2cdec3aa4fcb207f0eb74b3de7d951b..e07df5fe3ae1caa541853074db3ef6e41bbb11da 100644
--- a/chrome/browser/pdf/chrome_pdf_stream_delegate.cc
+++ b/chrome/browser/pdf/chrome_pdf_stream_delegate.cc
@@ -44,6 +44,7 @@ namespace {

Просмотреть файл

@ -35,10 +35,10 @@ index 9433ce4602414df4999f6ced8b371d4e847819ce..f38afaafcd6710f9cfcef816bf152cd2
content::RenderFrameHost* requesting_frame,
const blink::mojom::FullscreenOptions& options) final;
diff --git a/chrome/browser/ui/ash/ash_web_view_impl.cc b/chrome/browser/ui/ash/ash_web_view_impl.cc
index 8309281d321256e118e7086b29692f63be6aa9e6..96c433b8a3a42bf477c6467595b58a50c46499b4 100644
index f88f664eb7226425e6f1b45fe6811d49dd44f3ce..851d31a0e8bbdc57d4ca617f4d4c814343736ddd 100644
--- a/chrome/browser/ui/ash/ash_web_view_impl.cc
+++ b/chrome/browser/ui/ash/ash_web_view_impl.cc
@@ -111,10 +111,9 @@ bool AshWebViewImpl::IsWebContentsCreationOverridden(
@@ -112,10 +112,9 @@ bool AshWebViewImpl::IsWebContentsCreationOverridden(
content::SiteInstance* source_site_instance,
content::mojom::WindowContainerType window_container_type,
const GURL& opener_url,
@ -52,10 +52,10 @@ index 8309281d321256e118e7086b29692f63be6aa9e6..96c433b8a3a42bf477c6467595b58a50
/*from_user_gesture=*/true);
return true;
diff --git a/chrome/browser/ui/ash/ash_web_view_impl.h b/chrome/browser/ui/ash/ash_web_view_impl.h
index f47e14bc5dda6b84d1ae63148d7ee3bfb4797eb7..74838fd3621fd1d271ce8e3b037b1c785dd05651 100644
index 65840fa273b367efa9d681a4d267a3930d496eea..a28bdc08ee5535c3650169d5246aaa9a14d4778d 100644
--- a/chrome/browser/ui/ash/ash_web_view_impl.h
+++ b/chrome/browser/ui/ash/ash_web_view_impl.h
@@ -51,8 +51,7 @@ class AshWebViewImpl : public ash::AshWebView,
@@ -56,8 +56,7 @@ class AshWebViewImpl : public ash::AshWebView,
content::SiteInstance* source_site_instance,
content::mojom::WindowContainerType window_container_type,
const GURL& opener_url,
@ -80,10 +80,10 @@ index aaaa61d5c3a1d5ade2fd355e38a3985ef5cc4e7d..b45746ba0f38a381a2ee5ca17f3a1685
}
diff --git a/chrome/browser/ui/browser.cc b/chrome/browser/ui/browser.cc
index 018602d17271ca421188098326ad6090a219ac2a..af6dd489b2d85fbb7d5a53a1059ec80992de7849 100644
index a001626c9f47079d84a2a2d89101d2a87112b872..60365beee3e4e4637c0045646da0412fbf0d0099 100644
--- a/chrome/browser/ui/browser.cc
+++ b/chrome/browser/ui/browser.cc
@@ -1890,12 +1890,11 @@ bool Browser::IsWebContentsCreationOverridden(
@@ -1900,12 +1900,11 @@ bool Browser::IsWebContentsCreationOverridden(
content::SiteInstance* source_site_instance,
content::mojom::WindowContainerType window_container_type,
const GURL& opener_url,
@ -99,10 +99,10 @@ index 018602d17271ca421188098326ad6090a219ac2a..af6dd489b2d85fbb7d5a53a1059ec809
WebContents* Browser::CreateCustomWebContents(
diff --git a/chrome/browser/ui/browser.h b/chrome/browser/ui/browser.h
index 12a7f47ed24e8ceaa40ee3684b3fb8334481908b..e712e7471b04d1e7f2f70332fbe540134b2e94a9 100644
index f1f279121056f38c5baff7db9788fb9a8de9844c..580f4c6157fb9dcb28ca20fe42b0b0e7350dc2c7 100644
--- a/chrome/browser/ui/browser.h
+++ b/chrome/browser/ui/browser.h
@@ -908,8 +908,7 @@ class Browser : public TabStripModelObserver,
@@ -921,8 +921,7 @@ class Browser : public TabStripModelObserver,
content::SiteInstance* source_site_instance,
content::mojom::WindowContainerType window_container_type,
const GURL& opener_url,
@ -141,10 +141,10 @@ index ca72b324bf7c3b81ac94b53f0ff454d2df177950..d60ef3075d126e2bbd50c8469f2bf67c
// 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 8b1ebe377d69d335e648ce32eb0c2de5077c3ede..82e984382b3a484919702ac1e0d7d9c21dee223b 100644
index e6f3267a7f57c2768af02f049c1c1b9ec0f7a16b..2d717040473c8dad1e643bb6b1db67e90398cf4c 100644
--- a/chrome/browser/ui/views/hats/hats_next_web_dialog.cc
+++ b/chrome/browser/ui/views/hats/hats_next_web_dialog.cc
@@ -77,8 +77,7 @@ class HatsNextWebDialog::HatsWebView : public views::WebView {
@@ -78,8 +78,7 @@ class HatsNextWebDialog::HatsWebView : public views::WebView {
content::SiteInstance* source_site_instance,
content::mojom::WindowContainerType window_container_type,
const GURL& opener_url,
@ -218,10 +218,10 @@ index c5b0d3b23b8da318ae55fcac2515a1187f261469..16ed1f46c9afde0ff25750128b4fcff6
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 038cef59809065f0a775e1a0282bfeb9f31a4551..8baab27c7bc1bd7e0bbc6342388327a33304f713 100644
index 245e7c6e3228001d17e62b8ace3647023cac9a73..af25cd45d6f087bc6fd06916bd5c7ba4ef69ddef 100644
--- a/content/browser/web_contents/web_contents_impl.cc
+++ b/content/browser/web_contents/web_contents_impl.cc
@@ -4403,8 +4403,7 @@ FrameTree* WebContentsImpl::CreateNewWindow(
@@ -4422,8 +4422,7 @@ FrameTree* WebContentsImpl::CreateNewWindow(
if (delegate_ && delegate_->IsWebContentsCreationOverridden(
source_site_instance, params.window_container_type,
@ -232,7 +232,7 @@ index 038cef59809065f0a775e1a0282bfeb9f31a4551..8baab27c7bc1bd7e0bbc6342388327a3
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 aa401c609d1062cfd4149bbd7677f66a2554c3b4..40ff83b2dc575463aeac3b20ae74abe8036a548c 100644
index 4f9e32610e7e2c97c486be8693bd357b0d3e29f8..20c5b249bdf65694b1dbe7a703141da7aa0029f7 100644
--- a/content/public/browser/web_contents_delegate.cc
+++ b/content/public/browser/web_contents_delegate.cc
@@ -138,8 +138,7 @@ bool WebContentsDelegate::IsWebContentsCreationOverridden(
@ -246,7 +246,7 @@ index aa401c609d1062cfd4149bbd7677f66a2554c3b4..40ff83b2dc575463aeac3b20ae74abe8
}
diff --git a/content/public/browser/web_contents_delegate.h b/content/public/browser/web_contents_delegate.h
index b9168a2488f5c4977eba5856882b561e07195c7f..db05eabb345e3759e24f85dd95c81e9af2f7f401 100644
index c34e8d3822fa5aafb351a6b2119c7d49b283a4b0..08425c4787f2181be57ebd37ca7388a994c168f7 100644
--- a/content/public/browser/web_contents_delegate.h
+++ b/content/public/browser/web_contents_delegate.h
@@ -324,8 +324,7 @@ class CONTENT_EXPORT WebContentsDelegate {
@ -358,10 +358,10 @@ index 60acb83c8d76f71db689f9d188bb6e8f64a74ffb..aa6cee708d1e451b443bc26528b56cc8
->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 719b23a9b3c03324a1be5cb80f4bc77b88cd8f9d..99039fcc3918c5bdbc00a808870d0dfd1e8d6d2d 100644
index cbe26a6ee46b24334a68beb8e14af07153da1646..53b0404811766209a045a69dfa579b5b42e46369 100644
--- a/ui/views/controls/webview/web_dialog_view.cc
+++ b/ui/views/controls/webview/web_dialog_view.cc
@@ -426,8 +426,7 @@ bool WebDialogView::IsWebContentsCreationOverridden(
@@ -434,8 +434,7 @@ bool WebDialogView::IsWebContentsCreationOverridden(
content::SiteInstance* source_site_instance,
content::mojom::WindowContainerType window_container_type,
const GURL& opener_url,
@ -372,10 +372,10 @@ index 719b23a9b3c03324a1be5cb80f4bc77b88cd8f9d..99039fcc3918c5bdbc00a808870d0dfd
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 6f7713dee8fa997be326384548c995b2e4887ccb..f8b81dcbd00c5f4eb6279f763663a224d19973a5 100644
index 283a61a467498a0b397c9486b3ae43b9539ba352..ed90983c5304317a548d85748d93e2de3e2ffa2f 100644
--- a/ui/views/controls/webview/web_dialog_view.h
+++ b/ui/views/controls/webview/web_dialog_view.h
@@ -158,8 +158,7 @@ class WEBVIEW_EXPORT WebDialogView : public ClientView,
@@ -163,8 +163,7 @@ class WEBVIEW_EXPORT WebDialogView : public ClientView,
content::SiteInstance* source_site_instance,
content::mojom::WindowContainerType window_container_type,
const GURL& opener_url,

Просмотреть файл

@ -7,7 +7,7 @@ By default, chromium sets up one v8 snapshot to be used in all v8 contexts. This
to have a dedicated browser process v8 snapshot defined by the file `browser_v8_context_snapshot.bin`.
diff --git a/content/app/content_main_runner_impl.cc b/content/app/content_main_runner_impl.cc
index 496cf165cd37711fcb27fe74e4d3b00709941d19..003a7fd18179ed1df339eeb178b9a2e10a31520f 100644
index 5fa68db39e6ded11d4d0f6bee46c7938b2f011c0..48f1cdd0a7763242b81c7a54cad72700c8a42af1 100644
--- a/content/app/content_main_runner_impl.cc
+++ b/content/app/content_main_runner_impl.cc
@@ -39,6 +39,7 @@
@ -58,7 +58,7 @@ index 496cf165cd37711fcb27fe74e4d3b00709941d19..003a7fd18179ed1df339eeb178b9a2e1
blink::TrialTokenValidator::SetOriginTrialPolicyGetter(
base::BindRepeating([]() -> blink::OriginTrialPolicy* {
diff --git a/content/public/app/content_main_delegate.cc b/content/public/app/content_main_delegate.cc
index a687861c04b323102a8d2bfe22b24a964793cd9b..4a7a469111eaec3e1e76ee852bd5afbbc0da2956 100644
index 610938d92786cc033c19615364e5e45d54bf8ec6..11797f0429845bd3b654aff2bfa468460e4fd772 100644
--- a/content/public/app/content_main_delegate.cc
+++ b/content/public/app/content_main_delegate.cc
@@ -5,6 +5,7 @@
@ -69,8 +69,8 @@ index a687861c04b323102a8d2bfe22b24a964793cd9b..4a7a469111eaec3e1e76ee852bd5afbb
#include "build/build_config.h"
#include "content/public/browser/content_browser_client.h"
#include "content/public/common/content_client.h"
@@ -87,6 +88,10 @@ absl::optional<int> ContentMainDelegate::PostEarlyInitialization(
return absl::nullopt;
@@ -87,6 +88,10 @@ std::optional<int> ContentMainDelegate::PostEarlyInitialization(
return std::nullopt;
}
+base::StringPiece ContentMainDelegate::GetBrowserV8SnapshotFilename() {
@ -81,10 +81,10 @@ index a687861c04b323102a8d2bfe22b24a964793cd9b..4a7a469111eaec3e1e76ee852bd5afbb
return new ContentClient();
}
diff --git a/content/public/app/content_main_delegate.h b/content/public/app/content_main_delegate.h
index c891c5649a6ae76c9f0f988359649ece0e8ac1d9..54e30c4dd82042c283e36cae767dcdd716f94292 100644
index 2b0919b9a56bd37a398109777dfd199d777a9f74..823f44ab0303ccd6c7502ec65560ddb555b551e7 100644
--- a/content/public/app/content_main_delegate.h
+++ b/content/public/app/content_main_delegate.h
@@ -9,6 +9,7 @@
@@ -10,6 +10,7 @@
#include <string>
#include <vector>
@ -102,10 +102,10 @@ index c891c5649a6ae76c9f0f988359649ece0e8ac1d9..54e30c4dd82042c283e36cae767dcdd7
friend class ContentClientCreator;
friend class ContentClientInitializer;
diff --git a/gin/v8_initializer.cc b/gin/v8_initializer.cc
index 7dca3d0f45b63a270e6705180ffac4a05430f5ec..4bb4848178554033afd8cf6591d14775c33b2fde 100644
index f823cf647d1ae3d57fba3aa7a2325debcdf6050a..b7330ef0685c2afbef7937bf1b9502d5c2af7584 100644
--- a/gin/v8_initializer.cc
+++ b/gin/v8_initializer.cc
@@ -555,8 +555,7 @@ void V8Initializer::GetV8ExternalSnapshotData(const char** snapshot_data_out,
@@ -563,8 +563,7 @@ void V8Initializer::GetV8ExternalSnapshotData(const char** snapshot_data_out,
#if defined(V8_USE_EXTERNAL_STARTUP_DATA)
@ -115,7 +115,7 @@ index 7dca3d0f45b63a270e6705180ffac4a05430f5ec..4bb4848178554033afd8cf6591d14775
if (g_mapped_snapshot) {
// TODO(crbug.com/802962): Confirm not loading different type of snapshot
// files in a process.
@@ -565,10 +564,17 @@ void V8Initializer::LoadV8Snapshot(V8SnapshotFileType snapshot_file_type) {
@@ -573,10 +572,17 @@ void V8Initializer::LoadV8Snapshot(V8SnapshotFileType snapshot_file_type) {
base::MemoryMappedFile::Region file_region;
base::File file =

Просмотреть файл

@ -8,10 +8,10 @@ Allow registering custom protocols to handle service worker main script fetching
Refs https://bugs.chromium.org/p/chromium/issues/detail?id=996511
diff --git a/content/browser/service_worker/service_worker_context_wrapper.cc b/content/browser/service_worker/service_worker_context_wrapper.cc
index 0d4098dda205475c75bf57706282f1118e6a0deb..075c91b22901ed5f6c9cc341ac22bf6fb9567319 100644
index c0ece46d3a4b380c6fc2764bf49344153653bcf2..3bffada8ba3f378d4c5a5b75d7f1bb9da5437a1f 100644
--- a/content/browser/service_worker/service_worker_context_wrapper.cc
+++ b/content/browser/service_worker/service_worker_context_wrapper.cc
@@ -1916,6 +1916,26 @@ ServiceWorkerContextWrapper::GetLoaderFactoryForBrowserInitiatedRequest(
@@ -1922,6 +1922,26 @@ ServiceWorkerContextWrapper::GetLoaderFactoryForBrowserInitiatedRequest(
loader_factory_bundle_info =
context()->loader_factory_bundle_for_update_check()->Clone();
@ -38,7 +38,7 @@ index 0d4098dda205475c75bf57706282f1118e6a0deb..075c91b22901ed5f6c9cc341ac22bf6f
if (auto* config = content::WebUIConfigMap::GetInstance().GetConfig(
browser_context(), scope)) {
// If this is a Service Worker for a WebUI, the WebUI's URLDataSource
@@ -1935,9 +1955,7 @@ ServiceWorkerContextWrapper::GetLoaderFactoryForBrowserInitiatedRequest(
@@ -1941,9 +1961,7 @@ ServiceWorkerContextWrapper::GetLoaderFactoryForBrowserInitiatedRequest(
features::kEnableServiceWorkersForChromeScheme) &&
scope.scheme_piece() == kChromeUIScheme) {
config->RegisterURLDataSource(browser_context());
@ -49,7 +49,7 @@ index 0d4098dda205475c75bf57706282f1118e6a0deb..075c91b22901ed5f6c9cc341ac22bf6f
.emplace(kChromeUIScheme, CreateWebUIServiceWorkerLoaderFactory(
browser_context(), kChromeUIScheme,
base::flat_set<std::string>()));
@@ -1945,9 +1963,7 @@ ServiceWorkerContextWrapper::GetLoaderFactoryForBrowserInitiatedRequest(
@@ -1951,9 +1969,7 @@ ServiceWorkerContextWrapper::GetLoaderFactoryForBrowserInitiatedRequest(
features::kEnableServiceWorkersForChromeUntrusted) &&
scope.scheme_piece() == kChromeUIUntrustedScheme) {
config->RegisterURLDataSource(browser_context());

Просмотреть файл

@ -8,7 +8,7 @@ Subject: desktop_media_list.patch
* Ensure "OnRefreshComplete()" even if there are no items in the list
diff --git a/chrome/browser/media/webrtc/desktop_media_list.h b/chrome/browser/media/webrtc/desktop_media_list.h
index 42da00a0f473928263df89f11d80830b6986292b..6a556939d0acfbd910ebb0923e198e2fe67fd43d 100644
index 02aff44a81ffdf70ee85686867778f2ef0e9eda2..0c6fccf16a11bbaff10115308e4b489490e5d3e6 100644
--- a/chrome/browser/media/webrtc/desktop_media_list.h
+++ b/chrome/browser/media/webrtc/desktop_media_list.h
@@ -107,7 +107,8 @@ class DesktopMediaList {
@ -41,7 +41,7 @@ index 0389599ac786b6abd61ca921347fe12ddd5d0ee7..780927301744ea7312f230cec76a24a3
int DesktopMediaListBase::GetSourceCount() const {
diff --git a/chrome/browser/media/webrtc/desktop_media_list_base.h b/chrome/browser/media/webrtc/desktop_media_list_base.h
index b65012985ff1797203160d9e26af17fefee5c244..9ee211fb487007bd37b57cfa7b4ffbe5307af637 100644
index cb9be1e80b11c4b5839a0c281d49a0b8d4918a57..7aa54e5cb77b53c247c577dec1637da1ac290c2c 100644
--- a/chrome/browser/media/webrtc/desktop_media_list_base.h
+++ b/chrome/browser/media/webrtc/desktop_media_list_base.h
@@ -39,7 +39,7 @@ class DesktopMediaListBase : public DesktopMediaList {
@ -54,7 +54,7 @@ index b65012985ff1797203160d9e26af17fefee5c244..9ee211fb487007bd37b57cfa7b4ffbe5
const Source& GetSource(int index) const override;
DesktopMediaList::Type GetMediaListType() const override;
diff --git a/chrome/browser/media/webrtc/fake_desktop_media_list.cc b/chrome/browser/media/webrtc/fake_desktop_media_list.cc
index 832e0da5271d6ac92466c84dba6917041f825f96..068e7f57be13a89889047abeddd07dfc03b1fce0 100644
index 16c21bb299683e7b45245701618527dd4c6769a0..43bbc94f68c455d33ab3fa1995d5e33d9eb87c9b 100644
--- a/chrome/browser/media/webrtc/fake_desktop_media_list.cc
+++ b/chrome/browser/media/webrtc/fake_desktop_media_list.cc
@@ -79,7 +79,8 @@ void FakeDesktopMediaList::StartUpdating(DesktopMediaListObserver* observer) {
@ -68,7 +68,7 @@ index 832e0da5271d6ac92466c84dba6917041f825f96..068e7f57be13a89889047abeddd07dfc
}
diff --git a/chrome/browser/media/webrtc/fake_desktop_media_list.h b/chrome/browser/media/webrtc/fake_desktop_media_list.h
index 33ca7a53dfb6d2c9e3a33f0065a3acd806e82e01..9fdf2e8ff0056ff407015b914c6b03eb6e25e0e4 100644
index afc2cf89299315cca68b50196c2377a7d474883d..52bfd487d501ef895915800b9ee83a5b6c945473 100644
--- a/chrome/browser/media/webrtc/fake_desktop_media_list.h
+++ b/chrome/browser/media/webrtc/fake_desktop_media_list.h
@@ -40,7 +40,8 @@ class FakeDesktopMediaList : public DesktopMediaList {
@ -82,7 +82,7 @@ index 33ca7a53dfb6d2c9e3a33f0065a3acd806e82e01..9fdf2e8ff0056ff407015b914c6b03eb
const Source& GetSource(int index) const override;
DesktopMediaList::Type GetMediaListType() const override;
diff --git a/chrome/browser/media/webrtc/native_desktop_media_list.cc b/chrome/browser/media/webrtc/native_desktop_media_list.cc
index c76a6fffe76ad4932d9ea3557cc58c39a64fa485..cb16c002227b4e8a9603269498f3a90dbc840ba3 100644
index 7ad8178ada6bc852845837205162d7d7a1e431f3..78ad522d9772cb65128abba35a0d312fbff3c1e9 100644
--- a/chrome/browser/media/webrtc/native_desktop_media_list.cc
+++ b/chrome/browser/media/webrtc/native_desktop_media_list.cc
@@ -160,7 +160,7 @@ BOOL CALLBACK AllHwndCollector(HWND hwnd, LPARAM param) {

Просмотреть файл

@ -6,7 +6,7 @@ Subject: fix: disabling compositor recycling
Compositor recycling is useful for Chrome because there can be many tabs and spinning up a compositor for each one would be costly. In practice, Chrome uses the parent compositor code path of browser_compositor_view_mac.mm; the NSView of each tab is detached when it's hidden and attached when it's shown. For Electron, there is no parent compositor, so we're forced into the "own compositor" code path, which seems to be non-optimal and pretty ruthless in terms of the release of resources. Electron has no real concept of multiple tabs per window, so it should be okay to disable this ruthless recycling altogether in Electron.
diff --git a/content/browser/renderer_host/render_widget_host_view_mac.mm b/content/browser/renderer_host/render_widget_host_view_mac.mm
index 1c89ef6bfe1ad78e0f7d25135619f481746c75b6..c47deb8e53151c63ee26456eefbd910b1b64d70d 100644
index 8e89fb47039493ae0040b0789a3e9ed2f742464e..6837c7a1046f37eb8ffa6825af4f9c6b333d38c5 100644
--- a/content/browser/renderer_host/render_widget_host_view_mac.mm
+++ b/content/browser/renderer_host/render_widget_host_view_mac.mm
@@ -557,7 +557,11 @@

Просмотреть файл

@ -6,7 +6,7 @@ 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 d0a020a094132003e443b7a544d737615d4864e0..f15ba3475d6733bf33f1d3d243773928c29dd776 100644
index b62442d2213a7f55c66d19d3747f7f00c5b2aaa4..033634314d706196b5a68fc44114971d31bda3cb 100644
--- a/content/browser/renderer_host/render_widget_host_impl.cc
+++ b/content/browser/renderer_host/render_widget_host_impl.cc
@@ -832,6 +832,9 @@ void RenderWidgetHostImpl::WasHidden() {
@ -20,7 +20,7 @@ index d0a020a094132003e443b7a544d737615d4864e0..f15ba3475d6733bf33f1d3d243773928
blink::mojom::PointerLockResult::kWrongDocument);
diff --git a/content/browser/renderer_host/render_widget_host_impl.h b/content/browser/renderer_host/render_widget_host_impl.h
index c341d381d44d92040f876d7964eaa7b35135a750..ab7b311760b331144fb525e10ced812e9942b3da 100644
index 709246523b417943b4c64ef364312980d717e1bc..079b93338c3af4605c470b88934a32d1868eabe6 100644
--- a/content/browser/renderer_host/render_widget_host_impl.h
+++ b/content/browser/renderer_host/render_widget_host_impl.h
@@ -914,6 +914,8 @@ class CONTENT_EXPORT RenderWidgetHostImpl
@ -33,10 +33,10 @@ index c341d381d44d92040f876d7964eaa7b35135a750..ab7b311760b331144fb525e10ced812e
void StartDragging(blink::mojom::DragDataPtr drag_data,
const url::Origin& source_origin,
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 4f2a3b287076dc236058a2e6778ab067c3a4eb89..a967365095f3ca4c1b57b0dcbfa8b148a5e1e683 100644
index 7942ee12c003c722b02f2b76cc6cca9837551f68..d78f00cbb877b64892b9871252d79796fd4cabb8 100644
--- a/content/browser/renderer_host/render_widget_host_view_aura.cc
+++ b/content/browser/renderer_host/render_widget_host_view_aura.cc
@@ -624,7 +624,7 @@ void RenderWidgetHostViewAura::HideImpl() {
@@ -620,7 +620,7 @@ void RenderWidgetHostViewAura::HideImpl() {
DCHECK(visibility_ == Visibility::HIDDEN ||
visibility_ == Visibility::OCCLUDED);

Просмотреть файл

@ -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 5bf90893c11b6ba9bceecefa2774a48e1b75c84a..bb41e1ca654c85d0e534227f8f51a55825c661ac 100644
index bef15a4f17358386478d853a84a1c1e32dfd6f0e..5c785109c7223268a096a2c5a5cf6c61298e8227 100644
--- a/content/browser/renderer_host/navigator.cc
+++ b/content/browser/renderer_host/navigator.cc
@@ -1282,6 +1282,7 @@ void Navigator::RecordNavigationMetrics(
@@ -1288,6 +1288,7 @@ void Navigator::RecordNavigationMetrics(
.InMilliseconds());
}
@ -35,7 +35,7 @@ index 5bf90893c11b6ba9bceecefa2774a48e1b75c84a..bb41e1ca654c85d0e534227f8f51a558
// 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 &&
@@ -1331,6 +1332,7 @@ void Navigator::RecordNavigationMetrics(
@@ -1337,6 +1338,7 @@ void Navigator::RecordNavigationMetrics(
first_before_unload_start_time)
.InMilliseconds());
}

Просмотреть файл

@ -1,34 +0,0 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: VerteDinde <vertedinde@electronjs.org>
Date: Wed, 13 Dec 2023 12:53:11 -0800
Subject: fix: enable partition alloc ref count size for MacOS 13+
Modifies an existing check to check for all versions of MacOS 13
or higher, including MacOS 14 and potential beta versions.
This patch is currently being added upstream, and can be removed
when we integrate the upstream changes into Electron.
diff --git a/base/allocator/partition_allocator/src/partition_alloc/partition_ref_count.h b/base/allocator/partition_allocator/src/partition_alloc/partition_ref_count.h
index cfc0e1092fc560408c75c54d033cf76c5ef9348a..8ca7df7d43c11229149385156d3390a717428a27 100644
--- a/base/allocator/partition_allocator/src/partition_alloc/partition_ref_count.h
+++ b/base/allocator/partition_allocator/src/partition_alloc/partition_ref_count.h
@@ -32,7 +32,7 @@ namespace partition_alloc::internal {
// Aligns up (on 8B boundary) and returns `ref_count_size` if needed.
// * Known to be needed on MacOS 13: https://crbug.com/1378822.
-// * Thought to be needed on MacOS 14: https://crbug.com/1457756.
+// * Thought to be needed on MacOS 14 and higher: https://crbug.com/1457756.
// * No-op everywhere else.
//
// Placed outside `BUILDFLAG(ENABLE_BACKUP_REF_PTR_SUPPORT)`
@@ -40,8 +40,7 @@ namespace partition_alloc::internal {
// this gating.
PA_ALWAYS_INLINE size_t AlignUpRefCountSizeForMac(size_t ref_count_size) {
#if BUILDFLAG(IS_MAC)
- if (internal::base::mac::MacOSMajorVersion() == 13 ||
- internal::base::mac::MacOSMajorVersion() == 14) {
+ if (internal::base::mac::MacOSMajorVersion() >= 13) {
return internal::base::bits::AlignUp<size_t>(ref_count_size, 8);
}
#endif // BUILDFLAG(IS_MAC)

Просмотреть файл

@ -6,7 +6,7 @@ Subject: feat: enable setting aspect ratio to 0
Make SetAspectRatio accept 0 as valid input, which would reset to null.
diff --git a/ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc b/ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc
index 5e613d18403997123fb665792c0275643e91a6e9..a51018a455c114d9c3b15dd2628e6ab6bfc3da38 100644
index d877d237b2c1622057ff5e2304f232760016b948..e8a6da6bdb14eea3217a6824163364958552ba44 100644
--- a/ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc
+++ b/ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc
@@ -579,7 +579,7 @@ void DesktopWindowTreeHostWin::SetOpacity(float opacity) {

Просмотреть файл

@ -21,7 +21,7 @@ index cec5e3b283343586ba846a4ce58fee34e8542164..09ec66b75113d6a934d51ee5aad68428
ThreadIsolatedAllocator* GetThreadIsolatedAllocator() override;
#endif
diff --git a/gin/v8_platform.cc b/gin/v8_platform.cc
index a31b05d93b3728a17ebf6b78f0c01a20e0c6f250..9e88ea2190aec8f8ba962dd19a00e7c0cd9402d5 100644
index 3e21c6487268141f08cf308da90a3dd79fd4d6f0..d8e87ffdf7891b20a22d317655f4eaa45a371b5e 100644
--- a/gin/v8_platform.cc
+++ b/gin/v8_platform.cc
@@ -338,6 +338,10 @@ ThreadIsolatedAllocator* V8Platform::GetThreadIsolatedAllocator() {

Просмотреть файл

@ -33,10 +33,10 @@ index 0ab8187b0db8ae6db46d81738f653a2bc4c566f6..de3d55e85c22317f7f9375eb94d0d5d4
} // namespace net
diff --git a/services/network/network_context.cc b/services/network/network_context.cc
index c3d269712d75d0982302cedd2fc3a23973498fa9..cdb50603a942e4285eebae3cac84da22752bea70 100644
index 8dd57dc6d943054bda0e3ab9d992732f36ec6d3e..8c9c956c6b8642f96e964f562d5a31821ec68005 100644
--- a/services/network/network_context.cc
+++ b/services/network/network_context.cc
@@ -1525,6 +1525,13 @@ void NetworkContext::SetNetworkConditions(
@@ -1612,6 +1612,13 @@ void NetworkContext::SetNetworkConditions(
std::move(network_conditions));
}
@ -51,10 +51,10 @@ index c3d269712d75d0982302cedd2fc3a23973498fa9..cdb50603a942e4285eebae3cac84da22
// This may only be called on NetworkContexts created with the constructor
// that calls MakeURLRequestContext().
diff --git a/services/network/network_context.h b/services/network/network_context.h
index bd06da51ad2106b6a95abb9d773d66ca7d4f8c15..68afc1e30d65fd19923d7e5699e7e07c5acb8ce8 100644
index 453ab6cf11c5fd5aea9f8e30f1d2582cd20f36c4..faf4cc435f0857e186d1c3b32d66477439839d04 100644
--- a/services/network/network_context.h
+++ b/services/network/network_context.h
@@ -316,6 +316,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
@@ -315,6 +315,7 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
void CloseIdleConnections(CloseIdleConnectionsCallback callback) override;
void SetNetworkConditions(const base::UnguessableToken& throttling_profile_id,
mojom::NetworkConditionsPtr conditions) override;
@ -63,10 +63,10 @@ index bd06da51ad2106b6a95abb9d773d66ca7d4f8c15..68afc1e30d65fd19923d7e5699e7e07c
void SetEnableReferrers(bool enable_referrers) override;
#if BUILDFLAG(IS_CT_SUPPORTED)
diff --git a/services/network/public/mojom/network_context.mojom b/services/network/public/mojom/network_context.mojom
index fc3b31beea192b21f24f35debf6df12dfab40c65..9a4cfeeb29faa7523c751cec69c53586254e7382 100644
index fee16e02e0160825e44c668672176546abe7d99d..e6c2bb7599d1606725c982db98255a04ed456419 100644
--- a/services/network/public/mojom/network_context.mojom
+++ b/services/network/public/mojom/network_context.mojom
@@ -1248,6 +1248,9 @@ interface NetworkContext {
@@ -1266,6 +1266,9 @@ interface NetworkContext {
SetNetworkConditions(mojo_base.mojom.UnguessableToken throttling_profile_id,
NetworkConditions? conditions);
@ -77,7 +77,7 @@ index fc3b31beea192b21f24f35debf6df12dfab40c65..9a4cfeeb29faa7523c751cec69c53586
SetAcceptLanguage(string new_accept_language);
diff --git a/services/network/test/test_network_context.h b/services/network/test/test_network_context.h
index be94ed854cb5cf9e165e7e83a2e8cd3d3ab498cd..fca5afdc4a260559d5c7198de4686615ba4c09b3 100644
index 381c00fbe1af5711860b3237be1165e1c58540c0..cf16ab98f288b4a74dcb2bc9ab74ae6aa9d78805 100644
--- a/services/network/test/test_network_context.h
+++ b/services/network/test/test_network_context.h
@@ -147,6 +147,7 @@ class TestNetworkContext : public mojom::NetworkContext {

Просмотреть файл

@ -18,7 +18,7 @@ index 384a59138db11ea38028f844dd67e328ebffbe7b..f153997c2afccef1fa1b64ee5f162c28
bool IsNull() const { return private_.IsNull(); }
diff --git a/third_party/blink/renderer/core/exported/web_blob.cc b/third_party/blink/renderer/core/exported/web_blob.cc
index 4d0d10c1fb87429f874bc89063b1f719873154e7..b5cc01801aece4623706cc5de9ccae809f270a3f 100644
index d92af6b6f3134e5c3c660bcefd1e3da643767629..a4db82d49604e0a770f2985a6b4e607c70dc57f7 100644
--- a/third_party/blink/renderer/core/exported/web_blob.cc
+++ b/third_party/blink/renderer/core/exported/web_blob.cc
@@ -41,6 +41,7 @@

Просмотреть файл

@ -12,7 +12,7 @@ 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 a6714774b3fd35c0f34f37ab27163bfc920a8212..0550bf54088ba18311ea13cea1555d22e2976a20 100644
index 1b1628b5ba7b6920e149f881e8d5086ac9be0132..9c1359730ae381037102d2fe9950f1a19a679e54 100644
--- a/third_party/blink/renderer/core/exported/web_view_impl.cc
+++ b/third_party/blink/renderer/core/exported/web_view_impl.cc
@@ -167,6 +167,7 @@

Просмотреть файл

@ -65,18 +65,18 @@ index 02d9eabfef9521722340739bf86df3dfc30018d7..af8639ebcc61d8081a12334f652a551d
#if BUILDFLAG(IS_WIN)
bool EscapeVirtualization(const base::FilePath& user_data_dir);
diff --git a/chrome/browser/process_singleton_posix.cc b/chrome/browser/process_singleton_posix.cc
index 09108f231a54b117a143e71efa3f3663d64a63e6..b520e59cd5c0e3014497780d2ff8503f30557a4f 100644
index 298c9c81fa110ad7900d0bd6822136bb57f0382e..da7aaed23e4e0cdc037490bbe8beaea705b48df5 100644
--- a/chrome/browser/process_singleton_posix.cc
+++ b/chrome/browser/process_singleton_posix.cc
@@ -613,6 +613,7 @@ class ProcessSingleton::LinuxWatcher
@@ -610,6 +610,7 @@ class ProcessSingleton::LinuxWatcher
// |reader| is for sending back ACK message.
void HandleMessage(const std::string& current_dir,
const std::vector<std::string>& argv,
+ const std::vector<const uint8_t> additional_data,
SocketReader* reader);
private:
@@ -667,13 +668,16 @@ void ProcessSingleton::LinuxWatcher::StartListening(int socket) {
// Called when the ProcessSingleton that owns this class is about to be
@@ -669,13 +670,17 @@ void ProcessSingleton::LinuxWatcher::StartListening(int socket) {
}
void ProcessSingleton::LinuxWatcher::HandleMessage(
@ -88,14 +88,15 @@ index 09108f231a54b117a143e71efa3f3663d64a63e6..b520e59cd5c0e3014497780d2ff8503f
DCHECK(ui_task_runner_->BelongsToCurrentThread());
DCHECK(reader);
if (parent_->notification_callback_.Run(base::CommandLine(argv),
- base::FilePath(current_dir))) {
+ base::FilePath(current_dir),
+ std::move(additional_data))) {
if (parent_ && parent_->notification_callback_.Run(
- base::CommandLine(argv), base::FilePath(current_dir))) {
+ base::CommandLine(argv),
+ base::FilePath(current_dir),
+ std::move(additional_data))) {
// Send back "ACK" message to prevent the client process from starting up.
reader->FinishWithACK(kACKToken, std::size(kACKToken) - 1);
} else {
@@ -721,7 +725,8 @@ void ProcessSingleton::LinuxWatcher::SocketReader::
@@ -723,7 +728,8 @@ void ProcessSingleton::LinuxWatcher::SocketReader::
}
}
@ -105,7 +106,7 @@ index 09108f231a54b117a143e71efa3f3663d64a63e6..b520e59cd5c0e3014497780d2ff8503f
const size_t kMinMessageLength = std::size(kStartToken) + 4;
if (bytes_read_ < kMinMessageLength) {
buf_[bytes_read_] = 0;
@@ -751,10 +756,28 @@ void ProcessSingleton::LinuxWatcher::SocketReader::
@@ -753,10 +759,28 @@ void ProcessSingleton::LinuxWatcher::SocketReader::
tokens.erase(tokens.begin());
tokens.erase(tokens.begin());
@ -135,7 +136,7 @@ index 09108f231a54b117a143e71efa3f3663d64a63e6..b520e59cd5c0e3014497780d2ff8503f
fd_watch_controller_.reset();
// LinuxWatcher::HandleMessage() is in charge of destroying this SocketReader
@@ -783,8 +806,10 @@ void ProcessSingleton::LinuxWatcher::SocketReader::FinishWithACK(
@@ -785,8 +809,10 @@ void ProcessSingleton::LinuxWatcher::SocketReader::FinishWithACK(
//
ProcessSingleton::ProcessSingleton(
const base::FilePath& user_data_dir,
@ -146,7 +147,7 @@ index 09108f231a54b117a143e71efa3f3663d64a63e6..b520e59cd5c0e3014497780d2ff8503f
current_pid_(base::GetCurrentProcId()) {
socket_path_ = user_data_dir.Append(chrome::kSingletonSocketFilename);
lock_path_ = user_data_dir.Append(chrome::kSingletonLockFilename);
@@ -902,7 +927,8 @@ ProcessSingleton::NotifyResult ProcessSingleton::NotifyOtherProcessWithTimeout(
@@ -907,7 +933,8 @@ ProcessSingleton::NotifyResult ProcessSingleton::NotifyOtherProcessWithTimeout(
sizeof(socket_timeout));
// Found another process, prepare our command line
@ -156,7 +157,7 @@ index 09108f231a54b117a143e71efa3f3663d64a63e6..b520e59cd5c0e3014497780d2ff8503f
std::string to_send(kStartToken);
to_send.push_back(kTokenDelimiter);
@@ -912,11 +938,21 @@ ProcessSingleton::NotifyResult ProcessSingleton::NotifyOtherProcessWithTimeout(
@@ -917,11 +944,21 @@ ProcessSingleton::NotifyResult ProcessSingleton::NotifyOtherProcessWithTimeout(
to_send.append(current_dir.value());
const std::vector<std::string>& argv = cmd_line.argv();

Просмотреть файл

@ -260,7 +260,7 @@ index 2b84d4ef58986bb2eb8da1e62edd31769004bd98..7b213ad2757ece877d93e9f2cfdcaf66
+
} // namespace content
diff --git a/content/browser/renderer_host/code_cache_host_impl.cc b/content/browser/renderer_host/code_cache_host_impl.cc
index 222b62b17f85c8eafc6920f22d5bac516118f1ac..72519f7a35c5cafd50f7dbb454c44eb469f4905f 100644
index 9604422742eb8eb3a6b460f2791e3fb0056e0fcf..cfeae69888f7101328ef1425d474a33ef861d86d 100644
--- a/content/browser/renderer_host/code_cache_host_impl.cc
+++ b/content/browser/renderer_host/code_cache_host_impl.cc
@@ -6,6 +6,7 @@
@ -415,10 +415,10 @@ index 5d1484651fb8c3e03337665d3d5342ba51df3154..d4432a660d6c5a5e937dedabb7e4b71b
std::vector<std::string> extension_schemes;
// Registers a URL scheme with a predefined default custom handler.
diff --git a/url/url_util.cc b/url/url_util.cc
index 6f83f33c01c6ba61a180dd663f619a7a6a3cdd8b..95aad6e0c247b60874cd8907a4bb2cf63be48478 100644
index c57c19ba2773a5ff7318e46b60d58ac9316fa340..bad83f441920d948ad03198f928c99060a7b767b 100644
--- a/url/url_util.cc
+++ b/url/url_util.cc
@@ -114,6 +114,9 @@ struct SchemeRegistry {
@@ -115,6 +115,9 @@ struct SchemeRegistry {
kAboutScheme,
};
@ -428,7 +428,7 @@ index 6f83f33c01c6ba61a180dd663f619a7a6a3cdd8b..95aad6e0c247b60874cd8907a4bb2cf6
// Schemes with a predefined default custom handler.
std::vector<SchemeWithHandler> predefined_handler_schemes;
@@ -658,6 +661,15 @@ const std::vector<std::string>& GetEmptyDocumentSchemes() {
@@ -670,6 +673,15 @@ const std::vector<std::string>& GetEmptyDocumentSchemes() {
return GetSchemeRegistry().empty_document_schemes;
}

Просмотреть файл

@ -58,7 +58,7 @@ index e515503a0f636d935fdcd779a5ac01bd8f351e74..0669361cb063c9dd15a19486fce1a609
// Launches a process asynchronously and notifies the client of the process
diff --git a/content/browser/child_process_launcher_helper_linux.cc b/content/browser/child_process_launcher_helper_linux.cc
index 94d18b775d432cfeeb4d2db6091adda179dc6e6b..7560f17040c40291f9f603e5811db4c94dece517 100644
index 795ad47165f2f02e816f424ce74391a435c61a32..ace57135682f4372814acfbd202d1b077ecb1c0c 100644
--- a/content/browser/child_process_launcher_helper_linux.cc
+++ b/content/browser/child_process_launcher_helper_linux.cc
@@ -63,6 +63,11 @@ bool ChildProcessLauncherHelper::BeforeLaunchOnLauncherThread(
@ -84,7 +84,7 @@ index 94d18b775d432cfeeb4d2db6091adda179dc6e6b..7560f17040c40291f9f603e5811db4c9
DCHECK(GetZygoteForLaunch());
// Environment variables could be supported in the future, but are not
diff --git a/content/browser/child_process_launcher_helper_mac.cc b/content/browser/child_process_launcher_helper_mac.cc
index 9e5365dc37489dcd9f94d23cf03713492ab20e5f..03206ccc3181eae7776b4f2c076285b8729379b8 100644
index 8736af0021dccba915e3d2303191ae3ec80f6e75..56f8384c3ff4959272363cb71e4c380ee9125273 100644
--- a/content/browser/child_process_launcher_helper_mac.cc
+++ b/content/browser/child_process_launcher_helper_mac.cc
@@ -123,7 +123,8 @@ bool ChildProcessLauncherHelper::BeforeLaunchOnLauncherThread(
@ -110,7 +110,7 @@ index 9e5365dc37489dcd9f94d23cf03713492ab20e5f..03206ccc3181eae7776b4f2c076285b8
}
diff --git a/content/browser/child_process_launcher_helper_win.cc b/content/browser/child_process_launcher_helper_win.cc
index e5c96c7e5fada31994754679115f5e7b703b3ad4..e1bbce4ed643827c2ce2e841fae4d09cdff4dff3 100644
index 4b7c732a6ee2771156120f7a6d43020013cdf209..493c53aeda0841af95de81eac262558494c8a675 100644
--- a/content/browser/child_process_launcher_helper_win.cc
+++ b/content/browser/child_process_launcher_helper_win.cc
@@ -21,6 +21,8 @@
@ -163,7 +163,7 @@ index e5c96c7e5fada31994754679115f5e7b703b3ad4..e1bbce4ed643827c2ce2e841fae4d09c
}
diff --git a/content/browser/service_process_host_impl.cc b/content/browser/service_process_host_impl.cc
index 01e62d7e8df65efb900e9cd0d34bcd8e0ed3e7da..9af6784707f125046d9a734165fc2b08cf3c97bf 100644
index 97cda5eb354a16b53a2224de009898d85b348a69..75d7bc00759226859af635d66cdfbc3dd565b4a2 100644
--- a/content/browser/service_process_host_impl.cc
+++ b/content/browser/service_process_host_impl.cc
@@ -208,6 +208,15 @@ void LaunchServiceProcess(mojo::GenericPendingReceiver receiver,
@ -183,10 +183,10 @@ index 01e62d7e8df65efb900e9cd0d34bcd8e0ed3e7da..9af6784707f125046d9a734165fc2b08
host->GetChildProcess()->BindServiceInterface(std::move(receiver));
}
diff --git a/content/browser/utility_process_host.cc b/content/browser/utility_process_host.cc
index db744a552e0147ebcf3b162f9017de3a5c8f6c66..2f56433f44a425f645120271c4e39e8e4447e3bb 100644
index f3d7fb47d0950a3489271bf8e44fe48e10277b5d..e7f30e95727137fc54f8493dfa8eb36b74fbdcb4 100644
--- a/content/browser/utility_process_host.cc
+++ b/content/browser/utility_process_host.cc
@@ -180,11 +180,13 @@ const ChildProcessData& UtilityProcessHost::GetData() {
@@ -177,11 +177,13 @@ const ChildProcessData& UtilityProcessHost::GetData() {
return process_->GetData();
}
@ -202,7 +202,7 @@ index db744a552e0147ebcf3b162f9017de3a5c8f6c66..2f56433f44a425f645120271c4e39e8e
bool UtilityProcessHost::Start() {
return StartProcess();
@@ -250,6 +252,24 @@ void UtilityProcessHost::SetZygoteForTesting(ZygoteCommunication* handle) {
@@ -247,6 +249,24 @@ void UtilityProcessHost::SetZygoteForTesting(ZygoteCommunication* handle) {
}
#endif // BUILDFLAG(USE_ZYGOTE)
@ -227,7 +227,7 @@ index db744a552e0147ebcf3b162f9017de3a5c8f6c66..2f56433f44a425f645120271c4e39e8e
mojom::ChildProcess* UtilityProcessHost::GetChildProcess() {
return static_cast<ChildProcessHostImpl*>(process_->GetHost())
->child_process();
@@ -468,9 +488,22 @@ bool UtilityProcessHost::StartProcess() {
@@ -461,9 +481,22 @@ bool UtilityProcessHost::StartProcess() {
}
#endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_ASH)
@ -252,7 +252,7 @@ index db744a552e0147ebcf3b162f9017de3a5c8f6c66..2f56433f44a425f645120271c4e39e8e
#if BUILDFLAG(IS_WIN)
if (!preload_libraries_.empty()) {
diff --git a/content/browser/utility_process_host.h b/content/browser/utility_process_host.h
index 33d7e3613801085630735b49a5789d2a9bf2aed3..b0b6efc9c9acdd2aac6a9c90640f4fbc638b1761 100644
index 01a921c772f769c64ac97bfc5e74862a801e3e61..9bfc30138a01520d59760a49d15dd4819feb0556 100644
--- a/content/browser/utility_process_host.h
+++ b/content/browser/utility_process_host.h
@@ -35,6 +35,10 @@
@ -300,7 +300,7 @@ index 33d7e3613801085630735b49a5789d2a9bf2aed3..b0b6efc9c9acdd2aac6a9c90640f4fbc
mojom::ChildProcess* GetChildProcess();
@@ -209,6 +227,22 @@ class CONTENT_EXPORT UtilityProcessHost
absl::optional<raw_ptr<ZygoteCommunication>> zygote_for_testing_;
std::optional<raw_ptr<ZygoteCommunication>> zygote_for_testing_;
#endif // BUILDFLAG(USE_ZYGOTE)
+#if BUILDFLAG(IS_WIN)
@ -486,10 +486,10 @@ index e6bd27288a8d29dcf263a0677d2629d0aa7cf7c4..24d5acf41ea3fb825d813a040644aef1
ServiceProcessHost::Options&
ServiceProcessHost::Options::WithPreloadedLibraries(
diff --git a/content/public/browser/service_process_host.h b/content/public/browser/service_process_host.h
index 32fad70cbdf15d587eb32fa74b2995d30b27f694..2df65c405acdf896c5a66dcd3d0aaf44031bc2f7 100644
index 69c6f20a95c1da6a3f2ae02e81073bef0733af4e..8efbbd030729276114c40b33ee72822b02444a84 100644
--- a/content/public/browser/service_process_host.h
+++ b/content/public/browser/service_process_host.h
@@ -13,6 +13,7 @@
@@ -14,6 +14,7 @@
#include "base/command_line.h"
#include "base/functional/callback.h"
#include "base/observer_list_types.h"
@ -540,8 +540,8 @@ index 32fad70cbdf15d587eb32fa74b2995d30b27f694..2df65c405acdf896c5a66dcd3d0aaf44
// Specifies libraries to preload before the sandbox is locked down. Paths
// should be absolute paths. Libraries will be preloaded before sandbox
@@ -131,11 +155,20 @@ class CONTENT_EXPORT ServiceProcessHost {
absl::optional<GURL> site;
absl::optional<int> child_flags;
std::optional<GURL> site;
std::optional<int> child_flags;
std::vector<std::string> extra_switches;
+#if BUILDFLAG(IS_WIN)
+ base::win::ScopedHandle stdout_handle;

Просмотреть файл

@ -90,10 +90,10 @@ index 8af69cac78b7488d28f1f05ccb174793fe5148cd..9f74e511c263d147b5fbe81fe100d217
private:
const HWND hwnd_;
diff --git a/components/viz/service/BUILD.gn b/components/viz/service/BUILD.gn
index 27b8d9c767ca3f4dede7f79d6295ec8cc06eaffe..ebcd7d4fb8e876e3d5fd1fa1e0b6629049e664af 100644
index 53428bbfddb82c38995b0ab727c995d325713189..d495e71462c818a67f4d4410da0df00c6c04fad6 100644
--- a/components/viz/service/BUILD.gn
+++ b/components/viz/service/BUILD.gn
@@ -143,6 +143,8 @@ viz_component("service") {
@@ -165,6 +165,8 @@ viz_component("service") {
"display_embedder/skia_output_surface_impl_on_gpu_debug_capture.h",
"display_embedder/skia_render_copy_results.cc",
"display_embedder/skia_render_copy_results.h",
@ -562,7 +562,7 @@ index febb2718cb34ea4d9f411f068d8c01a89c7db888..be8bd51cb61c20ef3df8552972a0ac2f
gpu::SyncPointManager* GetSyncPointManager() override;
};
diff --git a/content/browser/compositor/viz_process_transport_factory.cc b/content/browser/compositor/viz_process_transport_factory.cc
index d149ead2520ed05c975119b81cc7b86701e1404f..4532417a34c6b24df2cd4bb96a0e0a463959dccf 100644
index 516c7f65097f139496184dcca8f054553b84d752..4fd23fbf7ab2b7aa4eee9c2fc4b98a04dd48efce 100644
--- a/content/browser/compositor/viz_process_transport_factory.cc
+++ b/content/browser/compositor/viz_process_transport_factory.cc
@@ -408,8 +408,14 @@ void VizProcessTransportFactory::OnEstablishedGpuChannel(
@ -618,7 +618,7 @@ index 2f462f0deb5fc8a637457243fb5d5849fc214d14..695869b83cefaa24af93a2e11b39de05
+ Draw(gfx.mojom.Rect damage_rect) => ();
};
diff --git a/ui/compositor/compositor.h b/ui/compositor/compositor.h
index 30f2e29532c5e781d7a329f8265193023a00b1d8..ae38020ebd9525795f53d4751b225cc30ac02d19 100644
index 86d021ca68674344c71cfaf12898d0dc486effc6..87c4b363a80713888d9e24a31afbe82a65ed2b1c 100644
--- a/ui/compositor/compositor.h
+++ b/ui/compositor/compositor.h
@@ -90,6 +90,7 @@ class DisplayPrivate;

Просмотреть файл

@ -12,7 +12,7 @@ We attempt to migrate the safe storage key from the old account, if that migrati
Existing apps that aren't built for the app store should be unimpacted, there is one edge case where a user uses BOTH an AppStore and a darwin build of the same app only one will keep it's access to the safestorage key as during the migration we delete the old account. This is an acceptable edge case as no one should be actively using two versions of the same app.
diff --git a/components/os_crypt/sync/keychain_password_mac.mm b/components/os_crypt/sync/keychain_password_mac.mm
index 901caf0217fe574e63bb1800f1f0b100dc8c30a4..4968792c3504783250076d83fa31df9bd6dab4f5 100644
index e7a65e97b51d93bff864889813317fb7c6ffc846..2b93da301b664f90720d2d2b5407be0985d7f334 100644
--- a/components/os_crypt/sync/keychain_password_mac.mm
+++ b/components/os_crypt/sync/keychain_password_mac.mm
@@ -22,6 +22,12 @@
@ -38,7 +38,7 @@ index 901caf0217fe574e63bb1800f1f0b100dc8c30a4..4968792c3504783250076d83fa31df9b
+ const std::string suffixed_account_name = account_name + account_name_suffix;
+
+ // We should check if the suffixed account exists first
OSStatus error = keychain_.FindGenericPassword(
OSStatus error = keychain_->FindGenericPassword(
- GetServiceName().size(), GetServiceName().c_str(),
- GetAccountName().size(), GetAccountName().c_str(), &password_length,
+ service_name.size(), service_name.c_str(),
@ -49,7 +49,7 @@ index 901caf0217fe574e63bb1800f1f0b100dc8c30a4..4968792c3504783250076d83fa31df9b
if (error == noErr) {
std::string password =
std::string(static_cast<char*>(password_data), password_length);
@@ -93,9 +106,52 @@
@@ -93,6 +106,49 @@
return password;
}
@ -63,7 +63,7 @@ index 901caf0217fe574e63bb1800f1f0b100dc8c30a4..4968792c3504783250076d83fa31df9b
+ // If the suffixed account didn't exist, we should check if the legacy non-suffixed account
+ // exists. If it does we can use that key and migrate it to the new account
+ base::apple::ScopedCFTypeRef<SecKeychainItemRef> item_ref;
+ error = keychain_.FindGenericPassword(
+ error = keychain_->FindGenericPassword(
+ service_name.size(), service_name.c_str(),
+ account_name.size(), account_name.c_str(), &password_length,
+ &password_data, item_ref.InitializeInto());
@ -74,7 +74,7 @@ index 901caf0217fe574e63bb1800f1f0b100dc8c30a4..4968792c3504783250076d83fa31df9b
+
+ // If we found the legacy account name we should copy it over to
+ // the new suffixed account
+ error = keychain_.AddGenericPassword(
+ error = keychain_->AddGenericPassword(
+ service_name.size(), service_name.data(), suffixed_account_name.size(),
+ suffixed_account_name.data(), password.size(), password_data, NULL);
+
@ -82,7 +82,7 @@ index 901caf0217fe574e63bb1800f1f0b100dc8c30a4..4968792c3504783250076d83fa31df9b
+ // If we successfully made the suffixed account we can delete the old
+ // account to ensure new apps don't try to use it and run into IAM
+ // issues
+ error = keychain_.ItemDelete(item_ref.get());
+ error = keychain_->ItemDelete(item_ref.get());
+ if (error != noErr) {
+ OSSTATUS_DLOG(ERROR, error) << "Keychain delete for legacy key failed";
+ }
@ -90,7 +90,7 @@ index 901caf0217fe574e63bb1800f1f0b100dc8c30a4..4968792c3504783250076d83fa31df9b
+ OSSTATUS_DLOG(ERROR, error) << "Keychain add for suffixed key failed";
+ }
+
+ keychain_.ItemFreeContent(password_data);
+ keychain_->ItemFreeContent(password_data);
+ return password;
+ }
+
@ -98,8 +98,4 @@ index 901caf0217fe574e63bb1800f1f0b100dc8c30a4..4968792c3504783250076d83fa31df9b
+ // with the suffixed name
if (error == errSecItemNotFound) {
std::string password = AddRandomPasswordToKeychain(
- keychain_, GetServiceName(), GetAccountName());
+ keychain_, service_name, suffixed_account_name);
return password;
}
*keychain_, GetServiceName(), GetAccountName());

Просмотреть файл

@ -153,10 +153,10 @@ index 8f5b717efcad8718328b018cc9afb229ee21821e..87c4c342355df9c5c7a5a01c095fc0d8
// Parse and remove the Trust Tokens response headers, if any are expected,
diff --git a/services/network/url_loader.h b/services/network/url_loader.h
index 2403422bbd7e13fefb96cdd80d25fe928a8e439c..67e33d9ba9509353a5f00d5477d52ab781f95a1e 100644
index a15681985b702fd55111fdc03bbface8ae89bfc4..f06a802a31f3fa66d687d532532b29dc27651d14 100644
--- a/services/network/url_loader.h
+++ b/services/network/url_loader.h
@@ -635,6 +635,8 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) URLLoader
@@ -634,6 +634,8 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) URLLoader
std::unique_ptr<ResourceScheduler::ScheduledResourceRequest>
resource_scheduler_request_handle_;

Просмотреть файл

@ -7,10 +7,10 @@ Subject: feat: filter out non-shareable windows in the current application in
This patch ensures that windows protected via win.setContentProtection(true) do not appear in full display captures via desktopCapturer. This patch could be upstreamed but as the check is limited to in-process windows it doesn't make a lot of sense for Chromium itself. This patch currently has a limitation that it only function for windows created / protected BEFORE the stream is started. There is theoretical future work we can do via polling / observers to automatically update the SCContentFilter when new windows are made but for now this will solve 99+% of the problem and folks can re-order their logic a bit to get it working for their use cases.
diff --git a/content/browser/media/capture/screen_capture_kit_device_mac.mm b/content/browser/media/capture/screen_capture_kit_device_mac.mm
index 0409dd9d72efd6a3b9da2842f3998e14ea1658ae..83c739080a48ced2d03d0a3d4d942910cc4ff4cf 100644
index 9ae935f2e729d0d7ad29aa00f62e6919ce71602c..4fb3e8eb5f34a7ee9e8b0f22a7c842129cdc31eb 100644
--- a/content/browser/media/capture/screen_capture_kit_device_mac.mm
+++ b/content/browser/media/capture/screen_capture_kit_device_mac.mm
@@ -170,7 +170,15 @@ void OnShareableContentCreated(SCShareableContent* content) {
@@ -171,7 +171,15 @@ void OnShareableContentCreated(SCShareableContent* content) {
case DesktopMediaID::TYPE_SCREEN:
for (SCDisplay* display in content.displays) {
if (source_.id == display.displayID) {

Просмотреть файл

@ -16,7 +16,7 @@ Linux or Windows to un-fullscreen in some circumstances without this
change.
diff --git a/chrome/browser/ui/exclusive_access/fullscreen_controller.cc b/chrome/browser/ui/exclusive_access/fullscreen_controller.cc
index e108057665773bcbbbc48de995b8001a700b4368..0b751ec1c1455890f12e517beb3967544bbacb9d 100644
index 5e0cd62415854a3aa9e89130eacb33ddfceb68d4..216121c84840ee97e666bd8934092f7fc9583395 100644
--- a/chrome/browser/ui/exclusive_access/fullscreen_controller.cc
+++ b/chrome/browser/ui/exclusive_access/fullscreen_controller.cc
@@ -16,12 +16,16 @@
@ -36,7 +36,7 @@ index e108057665773bcbbbc48de995b8001a700b4368..0b751ec1c1455890f12e517beb396754
#include "chrome/common/chrome_switches.h"
#include "content/public/browser/fullscreen_types.h"
#include "content/public/browser/navigation_details.h"
@@ -177,10 +181,12 @@ void FullscreenController::EnterFullscreenModeForTab(
@@ -180,10 +184,12 @@ void FullscreenController::EnterFullscreenModeForTab(
return;
}
@ -49,7 +49,7 @@ index e108057665773bcbbbc48de995b8001a700b4368..0b751ec1c1455890f12e517beb396754
// Keep the current state. |SetTabWithExclusiveAccess| may change the return
// value of |IsWindowFullscreenForTabOrPending|.
@@ -237,11 +243,13 @@ void FullscreenController::EnterFullscreenModeForTab(
@@ -240,11 +246,13 @@ void FullscreenController::EnterFullscreenModeForTab(
}
void FullscreenController::ExitFullscreenModeForTab(WebContents* web_contents) {
@ -63,7 +63,7 @@ index e108057665773bcbbbc48de995b8001a700b4368..0b751ec1c1455890f12e517beb396754
if (MaybeToggleFullscreenWithinTab(web_contents, false)) {
// During tab capture of fullscreen-within-tab views, the browser window
@@ -299,12 +307,14 @@ void FullscreenController::ExitFullscreenModeForTab(WebContents* web_contents) {
@@ -302,12 +310,14 @@ void FullscreenController::ExitFullscreenModeForTab(WebContents* web_contents) {
void FullscreenController::FullscreenTabOpeningPopup(
content::WebContents* opener,
content::WebContents* popup) {
@ -78,7 +78,7 @@ index e108057665773bcbbbc48de995b8001a700b4368..0b751ec1c1455890f12e517beb396754
}
void FullscreenController::OnTabDeactivated(
@@ -480,18 +490,17 @@ void FullscreenController::EnterFullscreenModeInternal(
@@ -486,18 +496,17 @@ void FullscreenController::EnterFullscreenModeInternal(
// Do not enter fullscreen mode if disallowed by pref. This prevents the user
// from manually entering fullscreen mode and also disables kiosk mode on
// desktop platforms.
@ -102,15 +102,27 @@ index e108057665773bcbbbc48de995b8001a700b4368..0b751ec1c1455890f12e517beb396754
if (option == TAB) {
url = GetRequestingOrigin();
tab_fullscreen_ = true;
@@ -524,6 +533,7 @@ void FullscreenController::EnterFullscreenModeInternal(
@@ -530,6 +539,7 @@ void FullscreenController::EnterFullscreenModeInternal(
if (!extension_caused_fullscreen_.is_empty())
url = extension_caused_fullscreen_;
}
+#endif
fullscreen_start_time_ = base::TimeTicks::Now();
if (option == BROWSER)
base::RecordAction(base::UserMetricsAction("ToggleFullscreen"));
@@ -544,12 +554,12 @@ void FullscreenController::ExitFullscreenModeInternal() {
@@ -549,6 +559,7 @@ void FullscreenController::ExitFullscreenModeInternal() {
if (chrome::IsRunningInAppMode())
return;
+#if 0
CHECK(fullscreen_start_time_);
if (exclusive_access_tab()) {
ukm::SourceId source_id =
@@ -560,15 +571,16 @@ void FullscreenController::ExitFullscreenModeInternal() {
.Record(ukm::UkmRecorder::Get());
fullscreen_start_time_.reset();
}
+#endif
toggled_into_fullscreen_ = false;
started_fullscreen_transition_ = true;
@ -127,17 +139,17 @@ index e108057665773bcbbbc48de995b8001a700b4368..0b751ec1c1455890f12e517beb396754
extension_caused_fullscreen_ = GURL();
diff --git a/chrome/browser/ui/exclusive_access/fullscreen_controller.h b/chrome/browser/ui/exclusive_access/fullscreen_controller.h
index 2d94e0bf404d7f2503098184af3439fae39c44fb..a0eb673521a118dfb7037b20a7d98f2ceeb1d273 100644
index 4b70d96a71e79ea8a02d1ef4eef3fdbd9eb8bb57..c0668fe843ebd094c6f56076e53dd239fade60a1 100644
--- a/chrome/browser/ui/exclusive_access/fullscreen_controller.h
+++ b/chrome/browser/ui/exclusive_access/fullscreen_controller.h
@@ -243,10 +243,12 @@ class FullscreenController : public ExclusiveAccessControllerBase {
@@ -244,10 +244,12 @@ class FullscreenController : public ExclusiveAccessControllerBase {
// Used in testing to set the state to tab fullscreen.
bool is_tab_fullscreen_for_testing_ = false;
+#if 0
// Tracks related popups that lost activation or were shown without activation
// during content fullscreen sessions. This also activates the popups when
// fullscreen exits, to prevent sites from creating persisent popunders.
// fullscreen exits, to prevent sites from creating persistent popunders.
std::unique_ptr<PopunderPreventer> popunder_preventer_;
+#endif

Просмотреть файл

@ -23,10 +23,10 @@ Upstream bug https://bugs.chromium.org/p/chromium/issues/detail?id=1081397.
Upstreamed at https://chromium-review.googlesource.com/c/chromium/src/+/3856266.
diff --git a/content/browser/renderer_host/navigation_request.cc b/content/browser/renderer_host/navigation_request.cc
index 2e5436d271df7df7e8f5fc8efbc85cc77bff9a36..a9365d7cf288fa16651ab6a2165803ec7f1078b4 100644
index dead84566f239eff4e7f190ab707fbc209391007..28a5ef2a8751e85cfa8c29138fe45bdec06ed332 100644
--- a/content/browser/renderer_host/navigation_request.cc
+++ b/content/browser/renderer_host/navigation_request.cc
@@ -10040,6 +10040,12 @@ NavigationRequest::GetOriginForURLLoaderFactoryUncheckedWithDebugInfo() {
@@ -10214,6 +10214,12 @@ NavigationRequest::GetOriginForURLLoaderFactoryUncheckedWithDebugInfo() {
return std::make_pair(parent->GetLastCommittedOrigin(), "about_srcdoc");
}
@ -40,10 +40,10 @@ index 2e5436d271df7df7e8f5fc8efbc85cc77bff9a36..a9365d7cf288fa16651ab6a2165803ec
// origin of |common_params.url| and/or |common_params.initiator_origin|.
url::Origin resolved_origin = url::Origin::Resolve(
diff --git a/third_party/blink/renderer/core/loader/document_loader.cc b/third_party/blink/renderer/core/loader/document_loader.cc
index 99df2c18b6b41e32e7aa25f326b826ff262fda35..7d1cc22d5aebaf259324a1076e2515b59680c064 100644
index 059d39e07ccdeb4cd61778d4cc0c764aa35ede8f..e486e85545f2d36579e8e7b08b037bc700a7ce9f 100644
--- a/third_party/blink/renderer/core/loader/document_loader.cc
+++ b/third_party/blink/renderer/core/loader/document_loader.cc
@@ -2126,6 +2126,10 @@ Frame* DocumentLoader::CalculateOwnerFrame() {
@@ -2127,6 +2127,10 @@ Frame* DocumentLoader::CalculateOwnerFrame() {
scoped_refptr<SecurityOrigin> DocumentLoader::CalculateOrigin(
Document* owner_document) {
scoped_refptr<SecurityOrigin> origin;
@ -54,7 +54,7 @@ index 99df2c18b6b41e32e7aa25f326b826ff262fda35..7d1cc22d5aebaf259324a1076e2515b5
StringBuilder debug_info_builder;
if (origin_to_commit_) {
// Origin to commit is specified by the browser process, it must be taken
@@ -2173,6 +2177,10 @@ scoped_refptr<SecurityOrigin> DocumentLoader::CalculateOrigin(
@@ -2174,6 +2178,10 @@ scoped_refptr<SecurityOrigin> DocumentLoader::CalculateOrigin(
debug_info_builder.Append(", url=");
debug_info_builder.Append(owner_document->Url().BaseAsString());
debug_info_builder.Append(")");

Просмотреть файл

@ -13,10 +13,10 @@ This patch can be removed should we choose to support chrome.fileSystem
or support it enough to fix the crash.
diff --git a/chrome/browser/resources/pdf/pdf_viewer.ts b/chrome/browser/resources/pdf/pdf_viewer.ts
index 6d44fbd54e3d5809b6136cf61c2cdc99b7df3a50..cc354c67bae5ea3c43ee4794a430da218afcd64e 100644
index 67b9df11aeb6359cc1040d0a012fcebd87d29bdd..17787a54888ea38ff1f7bdff4bdf9d43b2351601 100644
--- a/chrome/browser/resources/pdf/pdf_viewer.ts
+++ b/chrome/browser/resources/pdf/pdf_viewer.ts
@@ -907,7 +907,15 @@ export class PdfViewerElement extends PdfViewerBaseElement {
@@ -912,7 +912,15 @@ export class PdfViewerElement extends PdfViewerBaseElement {
dataArray = [result.dataToSave];
}
@ -32,7 +32,7 @@ index 6d44fbd54e3d5809b6136cf61c2cdc99b7df3a50..cc354c67bae5ea3c43ee4794a430da21
const fileName = this.attachments_[index].name;
chrome.fileSystem.chooseEntry(
{type: 'saveFile', suggestedName: fileName},
@@ -931,6 +939,7 @@ export class PdfViewerElement extends PdfViewerBaseElement {
@@ -936,6 +944,7 @@ export class PdfViewerElement extends PdfViewerBaseElement {
}
});
});
@ -40,7 +40,7 @@ index 6d44fbd54e3d5809b6136cf61c2cdc99b7df3a50..cc354c67bae5ea3c43ee4794a430da21
}
/**
@@ -1038,8 +1047,15 @@ export class PdfViewerElement extends PdfViewerBaseElement {
@@ -1043,8 +1052,15 @@ export class PdfViewerElement extends PdfViewerBaseElement {
fileName = fileName + '.pdf';
}
@ -57,7 +57,7 @@ index 6d44fbd54e3d5809b6136cf61c2cdc99b7df3a50..cc354c67bae5ea3c43ee4794a430da21
chrome.fileSystem.chooseEntry(
{
type: 'saveFile',
@@ -1066,6 +1082,7 @@ export class PdfViewerElement extends PdfViewerBaseElement {
@@ -1071,6 +1087,7 @@ export class PdfViewerElement extends PdfViewerBaseElement {
}
});
});

Просмотреть файл

@ -54,7 +54,7 @@ index 632b95912ff5c48431bfef4807b6481646a5cfd5..4a2e03f7d314c22497db700e88ae8367
+
} // namespace ui
diff --git a/ui/compositor/compositor.h b/ui/compositor/compositor.h
index ae38020ebd9525795f53d4751b225cc30ac02d19..2f8fe962b9219b70e5a9f35f4b59f163aa07564d 100644
index 87c4b363a80713888d9e24a31afbe82a65ed2b1c..6e4e509d7df1550876e40dc8c8adb48032050cab 100644
--- a/ui/compositor/compositor.h
+++ b/ui/compositor/compositor.h
@@ -514,6 +514,10 @@ class COMPOSITOR_EXPORT Compositor : public base::PowerSuspendObserver,

Просмотреть файл

@ -1,205 +0,0 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Amanda Baker <ambake@microsoft.com>
Date: Wed, 17 Jan 2024 21:07:24 +0000
Subject: fix: drag regions not working after navigation in WCO app
crrev.com/c/4814003 caused a regression where draggable regions (set
using the app-region CSS property) did not work after a Window
Controls Overlay or Borderless app navigated to another url.
This change fixes this issue by setting SupportsAppRegion to true on
each navigation within the app window.
Bug: 1516830, 1447586
Change-Id: I98019070f13ccd93a0f6db57a187eed00b460e81
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5179536
Commit-Queue: Amanda Baker <ambake@microsoft.com>
Reviewed-by: Phillis Tang <phillis@chromium.org>
Reviewed-by: Dmitry Gozman <dgozman@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1248354}
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 0550bf54088ba18311ea13cea1555d22e2976a20..9c1359730ae381037102d2fe9950f1a19a679e54 100644
--- a/third_party/blink/renderer/core/exported/web_view_impl.cc
+++ b/third_party/blink/renderer/core/exported/web_view_impl.cc
@@ -4016,7 +4016,24 @@ bool WebViewImpl::IsFencedFrameRoot() const {
}
void WebViewImpl::SetSupportsAppRegion(bool supports_app_region) {
- MainFrameImpl()->GetFrame()->SetSupportsAppRegion(supports_app_region);
+ supports_app_region_ = supports_app_region;
+ if (!MainFrameImpl() || !MainFrameImpl()->GetFrame()) {
+ return;
+ }
+
+ LocalFrame* local_frame = MainFrameImpl()->GetFrame();
+
+ if (supports_app_region_) {
+ local_frame->View()->UpdateDocumentAnnotatedRegions();
+ } else {
+ local_frame->GetDocument()->SetAnnotatedRegions(
+ Vector<AnnotatedRegionValue>());
+ local_frame->Client()->AnnotatedRegionsChanged();
+ }
+}
+
+bool WebViewImpl::SupportsAppRegion() {
+ return supports_app_region_;
}
void WebViewImpl::MojoDisconnected() {
diff --git a/third_party/blink/renderer/core/exported/web_view_impl.h b/third_party/blink/renderer/core/exported/web_view_impl.h
index c227b904fef4acc76a4af50263ab9d4fa35472e2..8dfb3b5b9026df92e28271258870c9eb588a6526 100644
--- a/third_party/blink/renderer/core/exported/web_view_impl.h
+++ b/third_party/blink/renderer/core/exported/web_view_impl.h
@@ -636,6 +636,9 @@ class CORE_EXPORT WebViewImpl final : public WebView,
scheduler::WebAgentGroupScheduler& GetWebAgentGroupScheduler();
+ // Returns true if the page supports app-region: drag/no-drag.
+ bool SupportsAppRegion();
+
private:
FRIEND_TEST_ALL_PREFIXES(WebFrameTest, DivScrollIntoEditableTest);
FRIEND_TEST_ALL_PREFIXES(WebFrameTest,
@@ -998,6 +1001,10 @@ class CORE_EXPORT WebViewImpl final : public WebView,
absl::optional<base::debug::StackTrace> close_called_stack_trace_;
absl::optional<base::debug::StackTrace> close_window_called_stack_trace_;
+ // Indicates whether the page supports draggable regions via the app-region
+ // CSS property.
+ bool supports_app_region_ = false;
+
// All the registered observers.
base::ObserverList<WebViewObserver> observers_;
diff --git a/third_party/blink/renderer/core/frame/local_frame.cc b/third_party/blink/renderer/core/frame/local_frame.cc
index 8cd79df2968ca7e98761b5aa604fb0228cbeaa8d..3a948217adf7ddb5a846c06cd4c0c5a8d64ab87b 100644
--- a/third_party/blink/renderer/core/frame/local_frame.cc
+++ b/third_party/blink/renderer/core/frame/local_frame.cc
@@ -3829,19 +3829,4 @@ const mojom::RendererContentSettingsPtr& LocalFrame::GetContentSettings() {
return loader_.GetDocumentLoader()->GetContentSettings();
}
-bool LocalFrame::SupportsAppRegion() {
- return supports_app_region_;
-}
-
-void LocalFrame::SetSupportsAppRegion(bool supports_app_region) {
- supports_app_region_ = supports_app_region;
- if (supports_app_region) {
- view_->UpdateDocumentAnnotatedRegions();
- } else {
- CHECK(GetDocument());
- GetDocument()->SetAnnotatedRegions(Vector<AnnotatedRegionValue>());
- Client()->AnnotatedRegionsChanged();
- }
-}
-
} // namespace blink
diff --git a/third_party/blink/renderer/core/frame/local_frame.h b/third_party/blink/renderer/core/frame/local_frame.h
index eb5ec8620c583e8850ea40deca9d19b08a144323..4acd8d0df124e1c2d5a546294e7fae261baf3440 100644
--- a/third_party/blink/renderer/core/frame/local_frame.h
+++ b/third_party/blink/renderer/core/frame/local_frame.h
@@ -926,10 +926,6 @@ class CORE_EXPORT LocalFrame final
// Can only be called while the frame is not detached.
const mojom::RendererContentSettingsPtr& GetContentSettings();
- // Returns true if the frame supports app-region: drag/no-drag.
- bool SupportsAppRegion();
- void SetSupportsAppRegion(bool supports_app_region);
-
private:
friend class FrameNavigationDisabler;
// LocalFrameMojoHandler is a part of LocalFrame.
@@ -1191,8 +1187,6 @@ class CORE_EXPORT LocalFrame final
Member<v8_compile_hints::V8LocalCompileHintsProducer>
v8_local_compile_hints_producer_;
-
- bool supports_app_region_ = false;
};
inline FrameLoader& LocalFrame::Loader() const {
diff --git a/third_party/blink/renderer/core/frame/local_frame_view.cc b/third_party/blink/renderer/core/frame/local_frame_view.cc
index 8cb1426970f17a84f1012ab7520373648f40ea35..b5c034a451c860c2fd4ca6488a98b6c863691c2f 100644
--- a/third_party/blink/renderer/core/frame/local_frame_view.cc
+++ b/third_party/blink/renderer/core/frame/local_frame_view.cc
@@ -1730,7 +1730,8 @@ void LocalFrameView::NotifyPageThatContentAreaWillPaint() const {
void LocalFrameView::UpdateDocumentAnnotatedRegions() const {
Document* document = frame_->GetDocument();
- if (!document->HasAnnotatedRegions() || !frame_->SupportsAppRegion()) {
+ if (!document->HasAnnotatedRegions() ||
+ !frame_->GetPage()->GetChromeClient().SupportsAppRegion()) {
return;
}
diff --git a/third_party/blink/renderer/core/loader/empty_clients.h b/third_party/blink/renderer/core/loader/empty_clients.h
index 47dab797a32b8832e9380c89cad92546233d9351..82bf787bc884a60ad49aeabecf8b62d2f72cd619 100644
--- a/third_party/blink/renderer/core/loader/empty_clients.h
+++ b/third_party/blink/renderer/core/loader/empty_clients.h
@@ -106,6 +106,7 @@ class CORE_EXPORT EmptyChromeClient : public ChromeClient {
void DidFocusPage() override {}
bool CanTakeFocus(mojom::blink::FocusType) override { return false; }
void TakeFocus(mojom::blink::FocusType) override {}
+ bool SupportsAppRegion() override { return false; }
void Show(LocalFrame& frame,
LocalFrame& opener_frame,
NavigationPolicy navigation_policy,
diff --git a/third_party/blink/renderer/core/page/chrome_client.h b/third_party/blink/renderer/core/page/chrome_client.h
index 73cddb74781652fddae126f497bf8f76a2cd179c..07cc5202bd2fc38f5463a1ec651dc6dd3cc4b419 100644
--- a/third_party/blink/renderer/core/page/chrome_client.h
+++ b/third_party/blink/renderer/core/page/chrome_client.h
@@ -177,6 +177,10 @@ class CORE_EXPORT ChromeClient : public GarbageCollected<ChromeClient> {
virtual void SetKeyboardFocusURL(Element*) {}
+ // Returns true if the page should support drag regions via the app-region
+ // CSS property.
+ virtual bool SupportsAppRegion() = 0;
+
// Allow document lifecycle updates to be run in order to produce composited
// outputs. Updates are blocked from occurring during loading navigation in
// order to prevent contention and allow Blink to proceed more quickly. This
diff --git a/third_party/blink/renderer/core/page/chrome_client_impl.cc b/third_party/blink/renderer/core/page/chrome_client_impl.cc
index 55d3e4248f722c56951b9c0120f3ac4480f1b5fe..b047b993fa780b19e08fb9a5bd328f7e83cc5661 100644
--- a/third_party/blink/renderer/core/page/chrome_client_impl.cc
+++ b/third_party/blink/renderer/core/page/chrome_client_impl.cc
@@ -291,6 +291,10 @@ void ChromeClientImpl::SetKeyboardFocusURL(Element* new_focus_element) {
web_view_->SetKeyboardFocusURL(focus_url);
}
+bool ChromeClientImpl::SupportsAppRegion() {
+ return web_view_->SupportsAppRegion();
+}
+
void ChromeClientImpl::StartDragging(LocalFrame* frame,
const WebDragData& drag_data,
DragOperationsMask mask,
diff --git a/third_party/blink/renderer/core/page/chrome_client_impl.h b/third_party/blink/renderer/core/page/chrome_client_impl.h
index bc8f7fe91eaff2ee9a0676e91ddff806bcaee5ff..ad179bc9ea6290e7bbeba427f54f0ea6ab396338 100644
--- a/third_party/blink/renderer/core/page/chrome_client_impl.h
+++ b/third_party/blink/renderer/core/page/chrome_client_impl.h
@@ -77,6 +77,7 @@ class CORE_EXPORT ChromeClientImpl final : public ChromeClient {
bool CanTakeFocus(mojom::blink::FocusType) override;
void TakeFocus(mojom::blink::FocusType) override;
void SetKeyboardFocusURL(Element* new_focus_element) override;
+ bool SupportsAppRegion() override;
void BeginLifecycleUpdates(LocalFrame& main_frame) override;
void RegisterForCommitObservation(CommitObserver*) override;
void UnregisterFromCommitObservation(CommitObserver*) override;
diff --git a/third_party/blink/renderer/core/testing/internals.cc b/third_party/blink/renderer/core/testing/internals.cc
index 23cf906dbba8136c604a1e3a59d27882710368c6..9ff8b22cf794cd58bff985e054df37636e34aabd 100644
--- a/third_party/blink/renderer/core/testing/internals.cc
+++ b/third_party/blink/renderer/core/testing/internals.cc
@@ -3008,7 +3008,8 @@ DOMRectList* Internals::nonDraggableRegions(Document* document,
}
void Internals::SetSupportsAppRegion(bool supports_app_region) {
- GetFrame()->SetSupportsAppRegion(supports_app_region);
+ document_->GetPage()->GetChromeClient().GetWebView()->SetSupportsAppRegion(
+ supports_app_region);
}
DOMRectList* Internals::AnnotatedRegions(Document* document,

Просмотреть файл

@ -6,10 +6,10 @@ Subject: fix: export zlib symbols
This patch sets ZLIB_DLL so that we properly export zlib symbols.
diff --git a/third_party/zlib/BUILD.gn b/third_party/zlib/BUILD.gn
index 46627bca7eb158cae381a791067a6b7185534370..2bb92a3b382c28d5cf320e43fe7f4f760c7757b4 100644
index 7fff5762e81b6ac939395d473ae966063f333af7..50faecbd7227e95637a3052dc8d3b41f403bfb19 100644
--- a/third_party/zlib/BUILD.gn
+++ b/third_party/zlib/BUILD.gn
@@ -322,6 +322,10 @@ component("zlib") {
@@ -321,6 +321,10 @@ component("zlib") {
defines = []
deps = []

Просмотреть файл

@ -9,21 +9,28 @@ to support content settings UI. The support pulls in chrome content settings
and UI code which are not valid in the scope of Electron.
diff --git a/chrome/browser/picture_in_picture/picture_in_picture_window_manager.cc b/chrome/browser/picture_in_picture/picture_in_picture_window_manager.cc
index 297e37c11cc69025843b225a4ba8ae096e304915..6244f27cacbddeed4881463d07a2279083173a5b 100644
index fd46d3ce5f0d0beed2736186bbc1ff41ec93fdeb..2478f2047783e16c3af3801675bc5b8d90bd36a5 100644
--- a/chrome/browser/picture_in_picture/picture_in_picture_window_manager.cc
+++ b/chrome/browser/picture_in_picture/picture_in_picture_window_manager.cc
@@ -21,8 +21,10 @@
@@ -6,6 +6,7 @@
#include "base/memory/raw_ptr.h"
#include "base/numerics/safe_conversions.h"
+#include "build/branding_buildflags.h"
#include "chrome/browser/picture_in_picture/picture_in_picture_bounds_cache.h"
#include "chrome/browser/picture_in_picture/picture_in_picture_occlusion_tracker.h"
#include "chrome/browser/ui/browser_navigator_params.h"
@@ -22,7 +23,9 @@
#include "ui/gfx/geometry/size.h"
#if !BUILDFLAG(IS_ANDROID)
#include "base/task/sequenced_task_runner.h"
+#if BUILDFLAG(GOOGLE_CHROME_BRANDING)
#include "chrome/browser/picture_in_picture/auto_picture_in_picture_tab_helper.h"
#include "chrome/browser/picture_in_picture/auto_pip_setting_helper.h"
+#endif // BUILDFLAG(GOOGLE_CHROME_BRANDING)
#include "media/base/media_switches.h"
#include "net/base/url_util.h"
#include "third_party/blink/public/common/features.h"
#include "ui/views/view.h"
@@ -38,7 +40,7 @@ constexpr gfx::Size kMinWindowSize(240, 52);
@@ -43,7 +46,7 @@ constexpr gfx::Size kMinWindowSize(240, 52);
// not apply to video Picture-in-Picture windows.
constexpr double kMaxWindowSizeRatio = 0.8;
@ -32,16 +39,16 @@ index 297e37c11cc69025843b225a4ba8ae096e304915..6244f27cacbddeed4881463d07a22790
// Returns true if a document picture-in-picture window should be focused upon
// opening it.
bool ShouldFocusPictureInPictureWindow(const NavigateParams& params) {
@@ -170,7 +172,7 @@ bool PictureInPictureWindowManager::ExitPictureInPictureViaWindowUi(
@@ -175,7 +178,7 @@ bool PictureInPictureWindowManager::ExitPictureInPictureViaWindowUi(
return false;
}
-#if !BUILDFLAG(IS_ANDROID)
+#if !BUILDFLAG(IS_ANDROID) && BUILDFLAG(GOOGLE_CHROME_BRANDING)
if (auto_pip_setting_helper_) {
auto_pip_setting_helper_->OnUserClosedWindow();
}
@@ -353,7 +355,7 @@ gfx::Size PictureInPictureWindowManager::GetMaximumWindowSize(
// The user manually closed the pip window, so let the tab helper know in case
// the auto-pip permission dialog was visible.
if (auto* tab_helper = AutoPictureInPictureTabHelper::FromWebContents(
@@ -361,7 +364,7 @@ gfx::Size PictureInPictureWindowManager::GetMaximumWindowSize(
// static
void PictureInPictureWindowManager::SetWindowParams(NavigateParams& params) {
@ -50,27 +57,7 @@ index 297e37c11cc69025843b225a4ba8ae096e304915..6244f27cacbddeed4881463d07a22790
// Always show document picture-in-picture in a new window. When this is
// not opened via the AutoPictureInPictureTabHelper, focus the window.
params.window_action = ShouldFocusPictureInPictureWindow(params)
@@ -376,7 +378,7 @@ void PictureInPictureWindowManager::CloseWindowInternal() {
video_web_contents_observer_.reset();
pip_window_controller_->Close(false /* should_pause_video */);
pip_window_controller_ = nullptr;
-#if !BUILDFLAG(IS_ANDROID)
+#if !BUILDFLAG(IS_ANDROID) && BUILDFLAG(GOOGLE_CHROME_BRANDING)
auto_pip_setting_helper_.reset();
#endif // !BUILDFLAG(IS_ANDROID)
}
@@ -387,8 +389,10 @@ void PictureInPictureWindowManager::DocumentWebContentsDestroyed() {
// contents, so we only need to forget the controller here when user closes
// the parent web contents with the PiP window open.
document_web_contents_observer_.reset();
+#if BUILDFLAG(GOOGLE_CHROME_BRANDING)
// `auto_pip_setting_helper_` depends on the opener's WebContents.
auto_pip_setting_helper_.reset();
+#endif // BUILDFLAG(GOOGLE_CHROME_BRANDING)
if (pip_window_controller_)
pip_window_controller_ = nullptr;
}
@@ -410,6 +414,7 @@ PictureInPictureWindowManager::GetOverlayView(
@@ -433,6 +436,7 @@ PictureInPictureWindowManager::GetOverlayView(
return nullptr;
}
@ -78,7 +65,7 @@ index 297e37c11cc69025843b225a4ba8ae096e304915..6244f27cacbddeed4881463d07a22790
// It would be nice to create this in `EnterPictureInPicture*`, but detecting
// auto-pip while pip is in the process of opening doesn't work.
//
@@ -440,6 +445,8 @@ PictureInPictureWindowManager::GetOverlayView(
@@ -471,6 +475,8 @@ PictureInPictureWindowManager::GetOverlayView(
}
return overlay_view;
@ -87,78 +74,6 @@ index 297e37c11cc69025843b225a4ba8ae096e304915..6244f27cacbddeed4881463d07a22790
}
PictureInPictureOcclusionTracker*
@@ -450,6 +457,7 @@ PictureInPictureWindowManager::GetOcclusionTracker() {
#endif // !BUILDFLAG(IS_ANDROID)
#if !BUILDFLAG(IS_ANDROID)
+#if BUILDFLAG(GOOGLE_CHROME_BRANDING)
void PictureInPictureWindowManager::CreateAutoPipSettingHelperIfNeeded() {
// Because we have to defer creating this until after the tab helper finds out
// about pip, we don't care if there's already a helper. Just use it.
@@ -479,6 +487,7 @@ void PictureInPictureWindowManager::CreateAutoPipSettingHelperIfNeeded() {
web_contents,
base::BindOnce(&PictureInPictureWindowManager::ExitPictureInPictureSoon));
}
+#endif
void PictureInPictureWindowManager::CreateOcclusionTrackerIfNecessary() {
if (occlusion_tracker_) {
diff --git a/chrome/browser/picture_in_picture/picture_in_picture_window_manager.h b/chrome/browser/picture_in_picture/picture_in_picture_window_manager.h
index 5b3deb74d3e1cceebfd86a8f4bacf81a10967ade..8ca4f8d8fd6353177ae203e3c4c0810a11640b7c 100644
--- a/chrome/browser/picture_in_picture/picture_in_picture_window_manager.h
+++ b/chrome/browser/picture_in_picture/picture_in_picture_window_manager.h
@@ -11,6 +11,7 @@
#include "base/memory/singleton.h"
#include "base/observer_list.h"
#include "base/observer_list_types.h"
+#include "build/branding_buildflags.h"
#include "build/build_config.h"
#include "third_party/abseil-cpp/absl/types/optional.h"
#include "third_party/blink/public/mojom/picture_in_picture_window_options/picture_in_picture_window_options.mojom.h"
@@ -32,7 +33,9 @@ class Display;
} // namespace display
#if !BUILDFLAG(IS_ANDROID)
+#if BUILDFLAG(GOOGLE_CHROME_BRANDING)
class AutoPipSettingHelper;
+#endif
class PictureInPictureOcclusionTracker;
namespace views {
@@ -179,10 +182,11 @@ class PictureInPictureWindowManager {
const gfx::Rect& browser_view_overridden_bounds,
views::View* anchor_view,
views::BubbleBorder::Arrow arrow);
-
+#if BUILDFLAG(GOOGLE_CHROME_BRANDING)
AutoPipSettingHelper* get_setting_helper_for_testing() {
return auto_pip_setting_helper_.get();
}
+#endif
// Returns the PictureInPictureOcclusionTracker, which can inform observers
// when a widget has been occluded by a video or document picture-in-picture
@@ -238,8 +242,10 @@ class PictureInPictureWindowManager {
static void ExitPictureInPictureSoon();
#if !BUILDFLAG(IS_ANDROID)
+#if BUILDFLAG(GOOGLE_CHROME_BRANDING)
// Create the settings helper if this is auto-pip and we don't have one.
void CreateAutoPipSettingHelperIfNeeded();
+#endif
// Creates the `occlusion_tracker_` if it does not already exist and should
// exist.
@@ -256,7 +262,9 @@ class PictureInPictureWindowManager {
#if !BUILDFLAG(IS_ANDROID)
std::unique_ptr<DocumentWebContentsObserver> document_web_contents_observer_;
+#if BUILDFLAG(GOOGLE_CHROME_BRANDING)
std::unique_ptr<AutoPipSettingHelper> auto_pip_setting_helper_;
+#endif // BUILDFLAG(GOOGLE_CHROME_BRANDING)
std::unique_ptr<PictureInPictureOcclusionTracker> occlusion_tracker_;
#endif //! BUILDFLAG(IS_ANDROID)
diff --git a/chrome/browser/ui/views/overlay/video_overlay_window_views.cc b/chrome/browser/ui/views/overlay/video_overlay_window_views.cc
index b3419d2bb60ab0488fc0413843c33b5a926fee09..059754d92621ada9100e739ee6b5db01ae9ea75f 100644
--- a/chrome/browser/ui/views/overlay/video_overlay_window_views.cc

Просмотреть файл

@ -13,10 +13,10 @@ messages in the legacy window handle layer.
These conditions are regularly hit with WCO-enabled windows on Windows.
diff --git a/content/browser/renderer_host/legacy_render_widget_host_win.cc b/content/browser/renderer_host/legacy_render_widget_host_win.cc
index f86be81eb5c5509819d05a610d637453df3be7e5..ba0d88bf97b3820f40ca0bd1e7eb9a584e8a9b69 100644
index 2635d8967c42c85fb6830036e6de694b5736a97b..17bb1932f3a01c5027113061276f7050bb61f80e 100644
--- a/content/browser/renderer_host/legacy_render_widget_host_win.cc
+++ b/content/browser/renderer_host/legacy_render_widget_host_win.cc
@@ -319,12 +319,12 @@ LRESULT LegacyRenderWidgetHostHWND::OnKeyboardRange(UINT message,
@@ -322,12 +322,12 @@ LRESULT LegacyRenderWidgetHostHWND::OnKeyboardRange(UINT message,
LRESULT LegacyRenderWidgetHostHWND::OnMouseRange(UINT message,
WPARAM w_param,
LPARAM l_param) {
@ -31,7 +31,7 @@ index f86be81eb5c5509819d05a610d637453df3be7e5..ba0d88bf97b3820f40ca0bd1e7eb9a58
tme.hwndTrack = hwnd();
tme.dwHoverTime = 0;
TrackMouseEvent(&tme);
@@ -356,7 +356,10 @@ LRESULT LegacyRenderWidgetHostHWND::OnMouseRange(UINT message,
@@ -359,7 +359,10 @@ LRESULT LegacyRenderWidgetHostHWND::OnMouseRange(UINT message,
// out of the picture.
if (!msg_handled_ &&
(message >= WM_NCMOUSEMOVE && message <= WM_NCXBUTTONDBLCLK)) {
@ -44,10 +44,10 @@ index f86be81eb5c5509819d05a610d637453df3be7e5..ba0d88bf97b3820f40ca0bd1e7eb9a58
}
}
diff --git a/content/browser/renderer_host/legacy_render_widget_host_win.h b/content/browser/renderer_host/legacy_render_widget_host_win.h
index d42e46626f0a88e2172a6d37218d7a61b3d860bf..f4a9de3d7ef31eb33bd8c1d9f71b9e3a9678aebc 100644
index c478d6351ba160c76871ad657ede69b05b4e09ca..77631423937f7df7c52b4d3d309aa9335ab05bbb 100644
--- a/content/browser/renderer_host/legacy_render_widget_host_win.h
+++ b/content/browser/renderer_host/legacy_render_widget_host_win.h
@@ -95,6 +95,7 @@ class CONTENT_EXPORT LegacyRenderWidgetHostHWND
@@ -91,6 +91,7 @@ class CONTENT_EXPORT LegacyRenderWidgetHostHWND
CR_MESSAGE_HANDLER_EX(WM_NCHITTEST, OnNCHitTest)
CR_MESSAGE_RANGE_HANDLER_EX(WM_NCMOUSEMOVE, WM_NCXBUTTONDBLCLK,
OnMouseRange)

Просмотреть файл

@ -15,7 +15,7 @@ node does not change in this case.
chromium-bug: https://crbug.com/1369605
diff --git a/content/browser/renderer_host/render_widget_host_view_child_frame.cc b/content/browser/renderer_host/render_widget_host_view_child_frame.cc
index c4312c899d5293eeb59d679dfa81a8f005f30940..906b47e935bdc3d37cf8313e5938bf79da335517 100644
index 090d9d58eddac80f8bd191ac4754d2e8d87c1b39..0c5c78020b98795f51f375a526f06599f9c9a273 100644
--- a/content/browser/renderer_host/render_widget_host_view_child_frame.cc
+++ b/content/browser/renderer_host/render_widget_host_view_child_frame.cc
@@ -1039,6 +1039,12 @@ RenderWidgetHostViewChildFrame::DidUpdateVisualProperties(
@ -32,7 +32,7 @@ index c4312c899d5293eeb59d679dfa81a8f005f30940..906b47e935bdc3d37cf8313e5938bf79
if (!text_input_manager_)
return ui::TEXT_INPUT_TYPE_NONE;
diff --git a/content/browser/renderer_host/render_widget_host_view_child_frame.h b/content/browser/renderer_host/render_widget_host_view_child_frame.h
index e340087e3ab2f07937ed6e6bd8e0ec8aa2a76d48..2b29e246b2f6ecf5d7605abfa36028642a7850c0 100644
index 58b3038d3aa7ed6babab2e9f6ffe9e4670656243..b2adee153030e0e3c3bf8ae3c2877d78dce56929 100644
--- a/content/browser/renderer_host/render_widget_host_view_child_frame.h
+++ b/content/browser/renderer_host/render_widget_host_view_child_frame.h
@@ -181,6 +181,8 @@ class CONTENT_EXPORT RenderWidgetHostViewChildFrame
@ -45,10 +45,10 @@ index e340087e3ab2f07937ed6e6bd8e0ec8aa2a76d48..2b29e246b2f6ecf5d7605abfa3602864
// RenderFrameMetadataProvider::Observer implementation.
void OnRenderFrameMetadataChangedBeforeActivation(
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
index a2e8526344318df726ea3af130aab3f72a3125e1..35b1cdcd9099bac3fd926ab6c9587dc5597c0d7d 100644
index 07ac28fe51c8f54d814c4c0718cf6f4705d0dbda..00e0321382a562ffb3733c48540d4f3071f13527 100644
--- a/content/browser/web_contents/web_contents_impl.cc
+++ b/content/browser/web_contents/web_contents_impl.cc
@@ -8645,7 +8645,7 @@ void WebContentsImpl::OnFocusedElementChangedInFrame(
@@ -8729,7 +8729,7 @@ void WebContentsImpl::OnFocusedElementChangedInFrame(
"WebContentsImpl::OnFocusedElementChangedInFrame",
"render_frame_host", frame);
RenderWidgetHostViewBase* root_view =

Просмотреть файл

@ -11,7 +11,7 @@ This patch should be upstreamed as a conditional revert of the logic in desktop
vs mobile runtimes. i.e. restore the old logic only on desktop platforms
diff --git a/content/browser/renderer_host/render_widget_host_impl.cc b/content/browser/renderer_host/render_widget_host_impl.cc
index 6e1cf587c7cd1b406b8f6488f4a7f309476f11a8..18e6f21bbec999a3bdbf9ad10690ba3437f1830f 100644
index 1d3f8f9484f64be58f59e240b1dae1fb507acd59..16b86097341601629be93353eff71dc92e2d618b 100644
--- a/content/browser/renderer_host/render_widget_host_impl.cc
+++ b/content/browser/renderer_host/render_widget_host_impl.cc
@@ -2215,9 +2215,8 @@ RenderWidgetHostImpl::GetWidgetInputHandler() {

Просмотреть файл

@ -20,10 +20,10 @@ index b62b74eedc1e6ec62894566be806e301c1ff0a87..b8c4e8bb7fc9b1708192363115ed6cd8
injector_->ExpectsResults(), injector_->ShouldWaitForPromise());
}
diff --git a/third_party/blink/public/web/web_local_frame.h b/third_party/blink/public/web/web_local_frame.h
index 2cb6f7a6213fe7384e85c0ef3d9c06f112011e2f..c44c27d93da89c29b724fa27baba5643fea99b6f 100644
index 8936f507939a3869f97197baf609303472806bf8..291ea2eb485da35fab481167b10f47e60f8e46d9 100644
--- a/third_party/blink/public/web/web_local_frame.h
+++ b/third_party/blink/public/web/web_local_frame.h
@@ -441,6 +441,7 @@ class BLINK_EXPORT WebLocalFrame : public WebFrame {
@@ -440,6 +440,7 @@ class BLINK_EXPORT WebLocalFrame : public WebFrame {
mojom::EvaluationTiming,
mojom::LoadEventBlockingOption,
WebScriptExecutionCallback,
@ -64,10 +64,10 @@ index 4cd668a127a50e5462e3878c3f1dcb7384926768..dfbec49249404df8f8ebdbd26e6e865c
#endif // THIRD_PARTY_BLINK_PUBLIC_WEB_WEB_SCRIPT_EXECUTION_CALLBACK_H_
diff --git a/third_party/blink/renderer/core/frame/local_frame.cc b/third_party/blink/renderer/core/frame/local_frame.cc
index 3964559a7caf7657a134d8a69d1587084e0ecfbb..8cd79df2968ca7e98761b5aa604fb0228cbeaa8d 100644
index c7547b2e7bae19db54635834a52116ec654629d6..269cd62a579b45b1d41e4f55ced7676fd7112c71 100644
--- a/third_party/blink/renderer/core/frame/local_frame.cc
+++ b/third_party/blink/renderer/core/frame/local_frame.cc
@@ -2912,6 +2912,7 @@ void LocalFrame::RequestExecuteScript(
@@ -2928,6 +2928,7 @@ void LocalFrame::RequestExecuteScript(
mojom::blink::EvaluationTiming evaluation_timing,
mojom::blink::LoadEventBlockingOption blocking_option,
WebScriptExecutionCallback callback,
@ -75,7 +75,7 @@ index 3964559a7caf7657a134d8a69d1587084e0ecfbb..8cd79df2968ca7e98761b5aa604fb022
BackForwardCacheAware back_forward_cache_aware,
mojom::blink::WantResultOption want_result_option,
mojom::blink::PromiseResultOption promise_behavior) {
@@ -2945,7 +2946,7 @@ void LocalFrame::RequestExecuteScript(
@@ -2961,7 +2962,7 @@ void LocalFrame::RequestExecuteScript(
PausableScriptExecutor::CreateAndRun(
script_state, std::move(script_sources), execute_script_policy,
user_gesture, evaluation_timing, blocking_option, want_result_option,
@ -85,10 +85,10 @@ index 3964559a7caf7657a134d8a69d1587084e0ecfbb..8cd79df2968ca7e98761b5aa604fb022
void LocalFrame::SetEvictCachedSessionStorageOnFreezeOrUnload() {
diff --git a/third_party/blink/renderer/core/frame/local_frame.h b/third_party/blink/renderer/core/frame/local_frame.h
index bc6f0807960ac1d450e334f10f2c3d35cde319a4..eb5ec8620c583e8850ea40deca9d19b08a144323 100644
index 088d5fb724130e7f0f3146d0cd73c576fe4ec6ad..df26aba980a92ccade2c08810171848f11d6decd 100644
--- a/third_party/blink/renderer/core/frame/local_frame.h
+++ b/third_party/blink/renderer/core/frame/local_frame.h
@@ -821,6 +821,7 @@ class CORE_EXPORT LocalFrame final
@@ -819,6 +819,7 @@ class CORE_EXPORT LocalFrame final
mojom::blink::EvaluationTiming,
mojom::blink::LoadEventBlockingOption,
WebScriptExecutionCallback,
@ -204,7 +204,7 @@ index fa65331f40b90d812b71a489fd560e9359152d2b..390714d631dc88ef92d59ef9618a5706
const mojom::blink::UserActivationOption user_activation_option_;
const mojom::blink::LoadEventBlockingOption blocking_option_;
diff --git a/third_party/blink/renderer/core/frame/web_frame_test.cc b/third_party/blink/renderer/core/frame/web_frame_test.cc
index c9646c493c5f93dba207fd46e7fc88f9b763b458..c59adf0360919655063468d6462879e9d9c049c1 100644
index b704f5d3532fc91ed31583adaa19e00c9eb7a884..018f2874c21a3fea5fcc7113de8474ff58b6fafc 100644
--- a/third_party/blink/renderer/core/frame/web_frame_test.cc
+++ b/third_party/blink/renderer/core/frame/web_frame_test.cc
@@ -285,6 +285,7 @@ void ExecuteScriptsInMainWorld(
@ -216,7 +216,7 @@ index c9646c493c5f93dba207fd46e7fc88f9b763b458..c59adf0360919655063468d6462879e9
mojom::blink::WantResultOption::kWantResult, wait_for_promise);
}
diff --git a/third_party/blink/renderer/core/frame/web_local_frame_impl.cc b/third_party/blink/renderer/core/frame/web_local_frame_impl.cc
index 3fb4db1c30008420ec2c16e95aedac7ee57689e7..20bc251e545627ac87de9bfa825e0b4d503fbe79 100644
index b6a622acf02054cb425a34c27471b4450596f7f1..7747568ad1b8921eef7b639232dac99a7f816a9f 100644
--- a/third_party/blink/renderer/core/frame/web_local_frame_impl.cc
+++ b/third_party/blink/renderer/core/frame/web_local_frame_impl.cc
@@ -1125,14 +1125,15 @@ void WebLocalFrameImpl::RequestExecuteScript(
@ -238,10 +238,10 @@ index 3fb4db1c30008420ec2c16e95aedac7ee57689e7..20bc251e545627ac87de9bfa825e0b4d
v8::MaybeLocal<v8::Value> WebLocalFrameImpl::CallFunctionEvenIfScriptDisabled(
diff --git a/third_party/blink/renderer/core/frame/web_local_frame_impl.h b/third_party/blink/renderer/core/frame/web_local_frame_impl.h
index 5c6ff2a2da3d3d585f08020c2885e23b3acbf824..2eb4bf48607823119548071e4b445e468e5b033c 100644
index f4ef9bfc74daa63f3863bc143513ca5006400074..8fd56b42955860428c8215bf562bb81be0c051eb 100644
--- a/third_party/blink/renderer/core/frame/web_local_frame_impl.h
+++ b/third_party/blink/renderer/core/frame/web_local_frame_impl.h
@@ -194,6 +194,7 @@ class CORE_EXPORT WebLocalFrameImpl final
@@ -195,6 +195,7 @@ class CORE_EXPORT WebLocalFrameImpl final
mojom::blink::EvaluationTiming,
mojom::blink::LoadEventBlockingOption,
WebScriptExecutionCallback,
@ -250,10 +250,10 @@ index 5c6ff2a2da3d3d585f08020c2885e23b3acbf824..2eb4bf48607823119548071e4b445e46
mojom::blink::WantResultOption,
mojom::blink::PromiseResultOption) override;
diff --git a/third_party/blink/renderer/core/scheduler_integration_tests/virtual_time_test.cc b/third_party/blink/renderer/core/scheduler_integration_tests/virtual_time_test.cc
index c34270e92a9268eebc7933c956eca8c8a4b282ec..aa145d19fddf4a572c67d7b173fe5b34377549d7 100644
index b1e363d8ea4bce0d80daef6f32b1cf055047d086..1fcd8f667cf966ebce3ab3c970673742fb5ac654 100644
--- a/third_party/blink/renderer/core/scheduler_integration_tests/virtual_time_test.cc
+++ b/third_party/blink/renderer/core/scheduler_integration_tests/virtual_time_test.cc
@@ -58,6 +58,7 @@ class VirtualTimeTest : public SimTest {
@@ -59,6 +59,7 @@ class VirtualTimeTest : public SimTest {
mojom::blink::LoadEventBlockingOption::kDoNotBlock,
WTF::BindOnce(&ScriptExecutionCallbackHelper::Completed,
base::Unretained(&callback_helper)),

Просмотреть файл

@ -6,7 +6,7 @@ Subject: fix: select the first menu item when opened via keyboard
This fixes an accessibility issue where the root view is 'focused' to the screen reader instead of the first menu item as with all other native menus. This patch will be upstreamed.
diff --git a/ui/views/controls/menu/menu_controller.cc b/ui/views/controls/menu/menu_controller.cc
index df0d88908371c960b9d29edc38c39dc88b0a7c5d..59e40bc7b37b75e6de998e95fde3bdc0690ede05 100644
index 50fd3ae4ff13ecc4b9c99f49f1851d368751fafa..fb8253a58ef86bcec24acdfa15ec08226bdcccc2 100644
--- a/ui/views/controls/menu/menu_controller.cc
+++ b/ui/views/controls/menu/menu_controller.cc
@@ -566,6 +566,7 @@ void MenuController::Run(Widget* parent,

Просмотреть файл

@ -0,0 +1,32 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: John Kleinschmidt <jkleinsc@electronjs.org>
Date: Wed, 24 Jan 2024 11:14:50 -0500
Subject: fix: suppress clang -Wimplicit-const-int-float-conversion in
v8_binding_for_core
fixes the following error on build:
../../third_party/blink/renderer/bindings/core/v8/v8_binding_for_core.h:272:38: error: implicit conversion from 'const uint64_t' (aka 'const unsigned long') to 'double' changes value from 18446744073709551615 to 18446744073709551616 [-Werror,-Wimplicit-const-int-float-conversion]
272 | double fmod_value = fmod(trunc(d), kMaxULL + 1.0);
| ^~~~~~~ ~
This error appears to be caused by https://chromium-review.googlesource.com/c/chromium/src/+/5224201
but doesn't appear to be reproducible in chrome.
Given the nature of this code it appears safe to ignore this check.
diff --git a/third_party/blink/renderer/bindings/core/v8/v8_binding_for_core.h b/third_party/blink/renderer/bindings/core/v8/v8_binding_for_core.h
index 29d361a9e2784a9e44880dff08d8a769e12c7455..256792a3dbe3dcf0a71573d337386ead622358e9 100644
--- a/third_party/blink/renderer/bindings/core/v8/v8_binding_for_core.h
+++ b/third_party/blink/renderer/bindings/core/v8/v8_binding_for_core.h
@@ -269,7 +269,10 @@ inline uint64_t DoubleToInteger(double d) {
constexpr uint64_t kMaxULL = std::numeric_limits<uint64_t>::max();
// -2^{64} < fmod_value < 2^{64}.
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wimplicit-const-int-float-conversion"
double fmod_value = fmod(trunc(d), kMaxULL + 1.0);
+#pragma clang diagnostic pop
if (fmod_value >= 0) {
// 0 <= fmod_value < 2^{64}.
// 0 <= value < 2^{64}. This cast causes no loss.

Просмотреть файл

@ -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 7c85f3e5bdee4797da773219404fd9b1bc9f529a..b979d6b567024aa7fc2945e86da8c613a5a19b76 100644
index 67cbdec6cdb18be2d99efb86436b371dc7aa3d69..9292d04288a2feeccb68d35ac26bb7eda441785f 100644
--- a/content/browser/renderer_host/render_frame_host_manager.cc
+++ b/content/browser/renderer_host/render_frame_host_manager.cc
@@ -4219,6 +4219,9 @@ RenderFrameHostManager::GetSiteInstanceForNavigationRequest(
@@ -4237,6 +4237,9 @@ RenderFrameHostManager::GetSiteInstanceForNavigationRequest(
request->ResetStateForSiteInstanceChange();
}
@ -20,7 +20,7 @@ index 7c85f3e5bdee4797da773219404fd9b1bc9f529a..b979d6b567024aa7fc2945e86da8c613
}
diff --git a/content/public/browser/content_browser_client.h b/content/public/browser/content_browser_client.h
index 51cf95131a2637e5fd4ff2b22a258231db9e1528..6a2b96de99317d6a0f9f4f7d89293541106611c3 100644
index dbeebb4ed9aa1fcba31cc2ce7e2031a483f7f1fe..c7f6be5f6a651647cc3f6814f25ce4cb0bf1e4ef 100644
--- a/content/public/browser/content_browser_client.h
+++ b/content/public/browser/content_browser_client.h
@@ -298,6 +298,11 @@ class CONTENT_EXPORT ContentBrowserClient {

Просмотреть файл

@ -7,10 +7,10 @@ We don't use gin to create the V8 platform, because we need to inject Node
things.
diff --git a/gin/isolate_holder.cc b/gin/isolate_holder.cc
index 4cb88241eeaaacdd1c1e419759fd56bc003dbaf3..1c3536a183aad1965e834b1681e36a3fc46ae419 100644
index cdaa098dd404ae477d208375cc4c9ca1b5ac43e4..cb2529a65f62c40e39d7cd4c96e50e1b72abbd53 100644
--- a/gin/isolate_holder.cc
+++ b/gin/isolate_holder.cc
@@ -140,9 +140,10 @@ void IsolateHolder::Initialize(ScriptMode mode,
@@ -151,9 +151,10 @@ void IsolateHolder::Initialize(ScriptMode mode,
const intptr_t* reference_table,
const std::string js_command_line_flags,
v8::FatalErrorCallback fatal_error_callback,
@ -38,10 +38,10 @@ index c19eb72e8d37fe8145b813d07875addf793e12dc..a5db8841773618814ac90f740201d4d7
// Returns whether `Initialize` has already been invoked in the process.
// Initialization is a one-way operation (i.e., this method cannot return
diff --git a/gin/v8_initializer.cc b/gin/v8_initializer.cc
index b3647cb580bfa3ba7678511072f18a8d53cd0a6a..7dca3d0f45b63a270e6705180ffac4a05430f5ec 100644
index 0b7fcb2ffd5e1a803b3d9b63e6c4285d32909364..f823cf647d1ae3d57fba3aa7a2325debcdf6050a 100644
--- a/gin/v8_initializer.cc
+++ b/gin/v8_initializer.cc
@@ -443,7 +443,8 @@ void SetFlags(IsolateHolder::ScriptMode mode,
@@ -451,7 +451,8 @@ void SetFlags(IsolateHolder::ScriptMode mode,
// static
void V8Initializer::Initialize(IsolateHolder::ScriptMode mode,
const std::string js_command_line_flags,
@ -51,7 +51,7 @@ index b3647cb580bfa3ba7678511072f18a8d53cd0a6a..7dca3d0f45b63a270e6705180ffac4a0
static bool v8_is_initialized = false;
if (v8_is_initialized)
return;
@@ -453,7 +454,8 @@ void V8Initializer::Initialize(IsolateHolder::ScriptMode mode,
@@ -461,7 +462,8 @@ void V8Initializer::Initialize(IsolateHolder::ScriptMode mode,
// See https://crbug.com/v8/11043
SetFlags(mode, js_command_line_flags);

Просмотреть файл

@ -12,7 +12,7 @@ rendering and there is no signal from browser process on this event
to identify it.
diff --git a/content/browser/gpu/gpu_data_manager_impl.cc b/content/browser/gpu/gpu_data_manager_impl.cc
index e496fc3cab0eed155123f5fc0e3cb5c4332bfcea..db062a89b241ea7d73b01a28adf6725e9f951e4d 100644
index 0582075df870162a97b463f6b3035a30bcfe36ae..d94c18d16f5ad80f14120c249e83e795c50c5106 100644
--- a/content/browser/gpu/gpu_data_manager_impl.cc
+++ b/content/browser/gpu/gpu_data_manager_impl.cc
@@ -225,6 +225,11 @@ void GpuDataManagerImpl::TerminateInfoCollectionGpuProcess() {
@ -28,7 +28,7 @@ index e496fc3cab0eed155123f5fc0e3cb5c4332bfcea..db062a89b241ea7d73b01a28adf6725e
void GpuDataManagerImpl::PostCreateThreads() {
diff --git a/content/browser/gpu/gpu_data_manager_impl.h b/content/browser/gpu/gpu_data_manager_impl.h
index c57305681efb469d296c90df68b6cdbea927580d..6dda1a5465e08df64b539ee203b7c40386d16e72 100644
index 25896ab0f3ca233ae17bf509f2a6ae5a6cc3c54b..5a8e6d184e276833034c604be8c48e01122207e2 100644
--- a/content/browser/gpu/gpu_data_manager_impl.h
+++ b/content/browser/gpu/gpu_data_manager_impl.h
@@ -121,6 +121,7 @@ class CONTENT_EXPORT GpuDataManagerImpl : public GpuDataManager,
@ -40,7 +40,7 @@ index c57305681efb469d296c90df68b6cdbea927580d..6dda1a5465e08df64b539ee203b7c403
// Called from BrowserMainLoop::PostCreateThreads().
// TODO(content/browser/gpu/OWNERS): This should probably use a
diff --git a/content/browser/gpu/gpu_data_manager_impl_private.cc b/content/browser/gpu/gpu_data_manager_impl_private.cc
index 6b7f461089ea44ab26e06889c786e65c5bdcd286..392ca4f7222fc1612de02ea2c4d0654d5d37867d 100644
index 4fa857fed71485898f4ba7c6e78cc8be37d8dbf7..3306a36044eed8395b3a13cffa4754cadee1048d 100644
--- a/content/browser/gpu/gpu_data_manager_impl_private.cc
+++ b/content/browser/gpu/gpu_data_manager_impl_private.cc
@@ -1222,6 +1222,12 @@ void GpuDataManagerImplPrivate::TerminateInfoCollectionGpuProcess() {
@ -57,7 +57,7 @@ index 6b7f461089ea44ab26e06889c786e65c5bdcd286..392ca4f7222fc1612de02ea2c4d0654d
void GpuDataManagerImplPrivate::PostCreateThreads() {
diff --git a/content/browser/gpu/gpu_data_manager_impl_private.h b/content/browser/gpu/gpu_data_manager_impl_private.h
index 6d5e9789ad9eab175087cc6bd30100d83d90a13b..d1946374205973cf2856acf4fe81fbe7c62c923e 100644
index 20e883daaa07133f977c5fe0c822f324d2642793..28306624ec6f7f9a7848e65787d4dc5aa738a76c 100644
--- a/content/browser/gpu/gpu_data_manager_impl_private.h
+++ b/content/browser/gpu/gpu_data_manager_impl_private.h
@@ -86,6 +86,7 @@ class CONTENT_EXPORT GpuDataManagerImplPrivate {

Просмотреть файл

@ -6,10 +6,10 @@ Subject: gritsettings_resource_ids.patch
Add electron resources file to the list of resource ids generation.
diff --git a/tools/gritsettings/resource_ids.spec b/tools/gritsettings/resource_ids.spec
index 98769c240b3569ffcc1f987c6a2a312860aecbbf..7ab4bf1213d1eb18214b9c76eb7d032c561f1888 100644
index df93fa972dff69ce23af64f2eadc1b91ff9765ab..8d419eaf8a74b918112c35fd78d0bc08923c72b8 100644
--- a/tools/gritsettings/resource_ids.spec
+++ b/tools/gritsettings/resource_ids.spec
@@ -1291,6 +1291,11 @@
@@ -1266,6 +1266,11 @@
"includes": [8440],
},

Просмотреть файл

@ -11,7 +11,7 @@ If removing this patch causes no sync failures, it's safe to delete :+1:
Ref https://chromium-review.googlesource.com/c/chromium/src/+/2953903
diff --git a/tools/clang/scripts/update.py b/tools/clang/scripts/update.py
index 47835edabbf4ea89942fa54987982c3479ca2793..13d8aec7c907cf925912dc0981dd63de45bd5fc0 100755
index a7a7a1ac4bf95282eb53ecfb85a5b6a0221de3c6..109a27a8f833810a3017914e2c411e6e00088094 100755
--- a/tools/clang/scripts/update.py
+++ b/tools/clang/scripts/update.py
@@ -306,6 +306,8 @@ def GetDefaultHostOs():

Просмотреть файл

@ -15,10 +15,10 @@ for us to register the isolate in between Isolate::Allocate and
Isolate::Initialize.
diff --git a/gin/isolate_holder.cc b/gin/isolate_holder.cc
index 1c3536a183aad1965e834b1681e36a3fc46ae419..1923f18cf2d4fff5094e6fe60bbef06b3e2cb06b 100644
index cb2529a65f62c40e39d7cd4c96e50e1b72abbd53..da16bf73c566b3fce3708ad0609c49c5841c8811 100644
--- a/gin/isolate_holder.cc
+++ b/gin/isolate_holder.cc
@@ -73,7 +73,8 @@ IsolateHolder::IsolateHolder(
@@ -75,7 +75,8 @@ IsolateHolder::IsolateHolder(
IsolateCreationMode isolate_creation_mode,
v8::CreateHistogramCallback create_histogram_callback,
v8::AddHistogramSampleCallback add_histogram_sample_callback,
@ -28,7 +28,7 @@ index 1c3536a183aad1965e834b1681e36a3fc46ae419..1923f18cf2d4fff5094e6fe60bbef06b
: IsolateHolder(std::move(task_runner),
access_mode,
isolate_type,
@@ -82,7 +83,8 @@ IsolateHolder::IsolateHolder(
@@ -84,7 +85,8 @@ IsolateHolder::IsolateHolder(
create_histogram_callback,
add_histogram_sample_callback),
isolate_creation_mode,
@ -38,7 +38,7 @@ index 1c3536a183aad1965e834b1681e36a3fc46ae419..1923f18cf2d4fff5094e6fe60bbef06b
IsolateHolder::IsolateHolder(
scoped_refptr<base::SingleThreadTaskRunner> task_runner,
@@ -90,7 +92,8 @@ IsolateHolder::IsolateHolder(
@@ -92,7 +94,8 @@ IsolateHolder::IsolateHolder(
IsolateType isolate_type,
std::unique_ptr<v8::Isolate::CreateParams> params,
IsolateCreationMode isolate_creation_mode,
@ -48,7 +48,7 @@ index 1c3536a183aad1965e834b1681e36a3fc46ae419..1923f18cf2d4fff5094e6fe60bbef06b
: access_mode_(access_mode), isolate_type_(isolate_type) {
CHECK(Initialized())
<< "You need to invoke gin::IsolateHolder::Initialize first";
@@ -101,7 +104,7 @@ IsolateHolder::IsolateHolder(
@@ -103,7 +106,7 @@ IsolateHolder::IsolateHolder(
v8::ArrayBuffer::Allocator* allocator = params->array_buffer_allocator;
DCHECK(allocator);

Просмотреть файл

@ -9,7 +9,7 @@ but due to the nature of electron, we need to load the v8 snapshot
in the browser process.
diff --git a/content/app/content_main_runner_impl.cc b/content/app/content_main_runner_impl.cc
index bf6ea2945dfeaad391f893797a25dd7912c242f7..496cf165cd37711fcb27fe74e4d3b00709941d19 100644
index 0e6cd686e0b05fac5e109594a857a15fa34aceba..5fa68db39e6ded11d4d0f6bee46c7938b2f011c0 100644
--- a/content/app/content_main_runner_impl.cc
+++ b/content/app/content_main_runner_impl.cc
@@ -274,11 +274,8 @@ void LoadV8SnapshotFile(const base::CommandLine& command_line) {

Просмотреть файл

@ -9,10 +9,10 @@ be created for each child process, despite logs being redirected to a
file.
diff --git a/content/app/content_main.cc b/content/app/content_main.cc
index 4320694e7f69179fcffd8ede4c499681f6fb3e95..31bebe229724917b0e93ca8563032f51711ce60d 100644
index aebbccad2a503caf5cf0ee5f3056a56e312cb42f..982a60250812f17b22c9bbdb6be2aceaa587d206 100644
--- a/content/app/content_main.cc
+++ b/content/app/content_main.cc
@@ -309,14 +309,13 @@ RunContentProcess(ContentMainParams params,
@@ -310,14 +310,13 @@ RunContentProcess(ContentMainParams params,
#if BUILDFLAG(IS_WIN)
// Route stdio to parent console (if any) or create one.

Просмотреть файл

@ -35,10 +35,10 @@ system font by checking if it's kCTFontPriorityAttribute is set to
system priority.
diff --git a/base/BUILD.gn b/base/BUILD.gn
index ccbf80dcc16734d1f8fd4f8bb574dd4534f3e7c4..3c07d4c27bdf22986e4d832cc36da573db4cfbc4 100644
index c00c41bc2c7fd716589c325722d69316d939ecfe..83fc835ecab873c9203ffe58ad21f2404ff80d4b 100644
--- a/base/BUILD.gn
+++ b/base/BUILD.gn
@@ -1038,6 +1038,7 @@ component("base") {
@@ -1047,6 +1047,7 @@ component("base") {
"//build/config/compiler:prevent_unsafe_narrowing",
"//build/config/compiler:wexit_time_destructors",
"//build/config/compiler:wglobal_constructors",
@ -159,19 +159,19 @@ index 94a028be3c315edc0056408ab9ab41b6b001a1c1..0d830234edb5621f57e39f4a951d357a
} // namespace base
diff --git a/components/os_crypt/sync/BUILD.gn b/components/os_crypt/sync/BUILD.gn
index 445b70c2f381cde2c540fe386ecd34d30ad973b7..1a8072f6e0456569db8f435248e8051374212b4c 100644
index db26459da52479751d042e89935d97c74c329c54..3d068770c0c06f5f042791731e394abd39248e32 100644
--- a/components/os_crypt/sync/BUILD.gn
+++ b/components/os_crypt/sync/BUILD.gn
@@ -47,6 +47,7 @@ component("os_crypt") {
"keychain_password_mac.mm",
@@ -48,6 +48,7 @@ component("os_crypt") {
"os_crypt_mac.mm",
]
deps += [ "//crypto:mock_apple_keychain" ]
+ configs += ["//electron/build/config:mas_build"]
}
if (is_win) {
diff --git a/components/remote_cocoa/app_shim/BUILD.gn b/components/remote_cocoa/app_shim/BUILD.gn
index 0369b1efab3783c0c61e086f82b3724772e4dff0..11a35c9f611fba4f5313994e41a440658cbe040a 100644
index 1ed0027978b0a3ff70d194421078b472aac977e0..7b7c669125948d2aa3650dde4238e9f3f8d42032 100644
--- a/components/remote_cocoa/app_shim/BUILD.gn
+++ b/components/remote_cocoa/app_shim/BUILD.gn
@@ -16,6 +16,7 @@ component("app_shim") {
@ -303,10 +303,10 @@ index 085d9821933390c781fe11d441910501bf22d601..6c79434e2a5b59267c9801ac23c318c9
// The NSWindow used by BridgedNativeWidget. Provides hooks into AppKit that
// can only be accomplished by overriding methods.
diff --git a/components/remote_cocoa/app_shim/native_widget_mac_nswindow.mm b/components/remote_cocoa/app_shim/native_widget_mac_nswindow.mm
index 6e837d66209e6322324227bc596e40e56fccc495..3c3c5db57cfaba8e59867e74b81b4fad1cf7a8ed 100644
index eeeaec7e1064ca250ffc4ef5d5e174c562dcd640..7b0c310ab949140811031f68f0e7163e5329326f 100644
--- a/components/remote_cocoa/app_shim/native_widget_mac_nswindow.mm
+++ b/components/remote_cocoa/app_shim/native_widget_mac_nswindow.mm
@@ -101,7 +101,9 @@ void OrderChildWindow(NSWindow* child_window,
@@ -104,7 +104,9 @@ void OrderChildWindow(NSWindow* child_window,
} // namespace
@interface NSWindow (Private)
@ -316,7 +316,7 @@ index 6e837d66209e6322324227bc596e40e56fccc495..3c3c5db57cfaba8e59867e74b81b4fad
- (BOOL)hasKeyAppearance;
- (long long)_resizeDirectionForMouseLocation:(CGPoint)location;
- (BOOL)_isConsideredOpenForPersistentState;
@@ -139,6 +141,8 @@ - (void)cr_mouseDownOnFrameView:(NSEvent*)event {
@@ -143,6 +145,8 @@ - (void)cr_mouseDownOnFrameView:(NSEvent*)event {
}
@end
@ -325,7 +325,7 @@ index 6e837d66209e6322324227bc596e40e56fccc495..3c3c5db57cfaba8e59867e74b81b4fad
@implementation NativeWidgetMacNSWindowTitledFrame
- (void)mouseDown:(NSEvent*)event {
if (self.window.isMovable)
@@ -165,6 +169,8 @@ - (BOOL)usesCustomDrawing {
@@ -169,6 +173,8 @@ - (BOOL)usesCustomDrawing {
}
@end
@ -334,7 +334,7 @@ index 6e837d66209e6322324227bc596e40e56fccc495..3c3c5db57cfaba8e59867e74b81b4fad
@implementation NativeWidgetMacNSWindow {
@private
CommandDispatcher* __strong _commandDispatcher;
@@ -353,6 +359,8 @@ - (NSAccessibilityRole)accessibilityRole {
@@ -357,6 +363,8 @@ - (NSAccessibilityRole)accessibilityRole {
// NSWindow overrides.
@ -343,7 +343,7 @@ index 6e837d66209e6322324227bc596e40e56fccc495..3c3c5db57cfaba8e59867e74b81b4fad
+ (Class)frameViewClassForStyleMask:(NSWindowStyleMask)windowStyle {
if (windowStyle & NSWindowStyleMaskTitled) {
if (Class customFrame = [NativeWidgetMacNSWindowTitledFrame class])
@@ -364,6 +372,8 @@ + (Class)frameViewClassForStyleMask:(NSWindowStyleMask)windowStyle {
@@ -368,6 +376,8 @@ + (Class)frameViewClassForStyleMask:(NSWindowStyleMask)windowStyle {
return [super frameViewClassForStyleMask:windowStyle];
}
@ -370,10 +370,10 @@ index 053b8a2182778b469941116eab3acd5fd6fd8099..d085258d5970b37215fe0d5591e6c030
// Beware: This view was briefly removed (in favor of a bare CALayer) in
// https://crrev.com/c/1236675. The ordering of unassociated layers relative
diff --git a/components/viz/service/BUILD.gn b/components/viz/service/BUILD.gn
index 12f99e2640142c922944d7101633a4e75baa4a92..27b8d9c767ca3f4dede7f79d6295ec8cc06eaffe 100644
index 5a5791600d1aac6d3792c997d59ba501965ff1b9..53428bbfddb82c38995b0ab727c995d325713189 100644
--- a/components/viz/service/BUILD.gn
+++ b/components/viz/service/BUILD.gn
@@ -335,6 +335,7 @@ viz_component("service") {
@@ -358,6 +358,7 @@ viz_component("service") {
"frame_sinks/external_begin_frame_source_mac.h",
]
}
@ -381,7 +381,7 @@ index 12f99e2640142c922944d7101633a4e75baa4a92..27b8d9c767ca3f4dede7f79d6295ec8c
}
if (is_android || use_ozone) {
@@ -594,6 +595,7 @@ viz_source_set("unit_tests") {
@@ -618,6 +619,7 @@ viz_source_set("unit_tests") {
"display_embedder/software_output_device_mac_unittest.mm",
]
frameworks = [ "IOSurface.framework" ]
@ -405,7 +405,7 @@ index eaf077d33ca54a5394b1f1ab9024b22c4e496ae5..ac2b42196188bc32b9842f95df74aa4c
void ForwardKeyboardEvent(const content::NativeWebKeyboardEvent& key_event,
diff --git a/content/app_shim_remote_cocoa/render_widget_host_view_cocoa.mm b/content/app_shim_remote_cocoa/render_widget_host_view_cocoa.mm
index 8c32ab0c35f68ae57f93002455a979f9381e3ac6..77782bb1847baf847d53e9bea926316c36f92838 100644
index 76959be428bd4ea2efe5e73c78b0aed77246fd96..58c8c975b737c9452674090396637122bb1cde7b 100644
--- a/content/app_shim_remote_cocoa/render_widget_host_view_cocoa.mm
+++ b/content/app_shim_remote_cocoa/render_widget_host_view_cocoa.mm
@@ -2020,15 +2020,21 @@ - (NSAccessibilityRole)accessibilityRole {
@ -431,7 +431,7 @@ index 8c32ab0c35f68ae57f93002455a979f9381e3ac6..77782bb1847baf847d53e9bea926316c
return kAttributes;
}
diff --git a/content/browser/BUILD.gn b/content/browser/BUILD.gn
index e67304f208e1ad657fff4b9c958fba4e74b75bf4..62695d9439c28ef29a18999909ae9c5fc442181a 100644
index a460c6503d69549a0b236a04d9e457c2d36ee405..821e5db63fd5d69b3fcc329ec02f71a1a7907ada 100644
--- a/content/browser/BUILD.gn
+++ b/content/browser/BUILD.gn
@@ -53,6 +53,7 @@ source_set("browser") {
@ -443,7 +443,7 @@ index e67304f208e1ad657fff4b9c958fba4e74b75bf4..62695d9439c28ef29a18999909ae9c5f
libs = []
frameworks = []
diff --git a/content/browser/accessibility/browser_accessibility_manager_mac.mm b/content/browser/accessibility/browser_accessibility_manager_mac.mm
index 5a6706495ed2a8f1cd781da9bde8572318bf6897..afd4d1f728a7f056e49b2ecb006c5a05388d3409 100644
index ce3623bd6353674fee92ba1c36eeda8da8906882..62746522bf5f398b12a8cee35f49bb4fc3b51b53 100644
--- a/content/browser/accessibility/browser_accessibility_manager_mac.mm
+++ b/content/browser/accessibility/browser_accessibility_manager_mac.mm
@@ -21,7 +21,9 @@
@ -456,7 +456,7 @@ index 5a6706495ed2a8f1cd781da9bde8572318bf6897..afd4d1f728a7f056e49b2ecb006c5a05
namespace {
@@ -224,6 +226,7 @@ void PostAnnouncementNotification(NSString* announcement,
@@ -225,6 +227,7 @@ void PostAnnouncementNotification(NSString* announcement,
return;
}
@ -464,7 +464,7 @@ index 5a6706495ed2a8f1cd781da9bde8572318bf6897..afd4d1f728a7f056e49b2ecb006c5a05
BrowserAccessibilityManager* root_manager = GetManagerForRootFrame();
if (root_manager) {
BrowserAccessibilityManagerMac* root_manager_mac =
@@ -246,6 +249,7 @@ void PostAnnouncementNotification(NSString* announcement,
@@ -247,6 +250,7 @@ void PostAnnouncementNotification(NSString* announcement,
return;
}
}
@ -472,7 +472,7 @@ index 5a6706495ed2a8f1cd781da9bde8572318bf6897..afd4d1f728a7f056e49b2ecb006c5a05
// Use native VoiceOver support for live regions.
BrowserAccessibilityCocoa* retained_node = native_node;
@@ -632,6 +636,7 @@ void PostAnnouncementNotification(NSString* announcement,
@@ -633,6 +637,7 @@ void PostAnnouncementNotification(NSString* announcement,
return window == [NSApp accessibilityFocusedWindow];
}
@ -480,7 +480,7 @@ index 5a6706495ed2a8f1cd781da9bde8572318bf6897..afd4d1f728a7f056e49b2ecb006c5a05
// TODO(accessibility): We need a solution to the problem described below.
// If the window is NSAccessibilityRemoteUIElement, there are some challenges:
// 1. NSApp is the browser which spawned the PWA, and what it considers the
@@ -660,6 +665,7 @@ void PostAnnouncementNotification(NSString* announcement,
@@ -661,6 +666,7 @@ void PostAnnouncementNotification(NSString* announcement,
if ([window isKindOfClass:[NSAccessibilityRemoteUIElement class]]) {
return true;
}
@ -489,7 +489,7 @@ index 5a6706495ed2a8f1cd781da9bde8572318bf6897..afd4d1f728a7f056e49b2ecb006c5a05
return false;
}
diff --git a/content/browser/renderer_host/render_widget_host_view_mac.h b/content/browser/renderer_host/render_widget_host_view_mac.h
index 04033ad13703e6e2a96ac3eec298c778c52512a1..24eb6f80dd31c55af90153dccd3b450edeb1bcb0 100644
index d730d482d7e6561937a5f911ba2af9dddbc7ad3f..2434cc9ac680024660f3967cc6055330fc8520f2 100644
--- a/content/browser/renderer_host/render_widget_host_view_mac.h
+++ b/content/browser/renderer_host/render_widget_host_view_mac.h
@@ -49,7 +49,9 @@ class ScopedPasswordInputEnabler;
@ -515,7 +515,7 @@ index 04033ad13703e6e2a96ac3eec298c778c52512a1..24eb6f80dd31c55af90153dccd3b450e
// Used to force the NSApplication's focused accessibility element to be the
// content::BrowserAccessibilityCocoa accessibility tree when the NSView for
diff --git a/content/browser/renderer_host/render_widget_host_view_mac.mm b/content/browser/renderer_host/render_widget_host_view_mac.mm
index 816e03b7a9c8d3dd1ca7ec2dc354a02e9b03a2f0..1c89ef6bfe1ad78e0f7d25135619f481746c75b6 100644
index 0ae21acbcc4cf1cd8a4a317edfac89bf04f10337..8e89fb47039493ae0040b0789a3e9ed2f742464e 100644
--- a/content/browser/renderer_host/render_widget_host_view_mac.mm
+++ b/content/browser/renderer_host/render_widget_host_view_mac.mm
@@ -272,8 +272,10 @@
@ -529,7 +529,7 @@ index 816e03b7a9c8d3dd1ca7ec2dc354a02e9b03a2f0..1c89ef6bfe1ad78e0f7d25135619f481
// Reset `ns_view_` before resetting `remote_ns_view_` to avoid dangling
// pointers. `ns_view_` gets reinitialized later in this method.
@@ -1644,8 +1646,10 @@ void CombineTextNodesAndMakeCallback(SpeechCallback callback,
@@ -1643,8 +1645,10 @@ void CombineTextNodesAndMakeCallback(SpeechCallback callback,
gfx::NativeViewAccessible
RenderWidgetHostViewMac::AccessibilityGetNativeViewAccessibleForWindow() {
@ -540,7 +540,7 @@ index 816e03b7a9c8d3dd1ca7ec2dc354a02e9b03a2f0..1c89ef6bfe1ad78e0f7d25135619f481
return [GetInProcessNSView() window];
}
@@ -1690,9 +1694,11 @@ void CombineTextNodesAndMakeCallback(SpeechCallback callback,
@@ -1689,9 +1693,11 @@ void CombineTextNodesAndMakeCallback(SpeechCallback callback,
}
void RenderWidgetHostViewMac::SetAccessibilityWindow(NSWindow* window) {
@ -552,7 +552,7 @@ index 816e03b7a9c8d3dd1ca7ec2dc354a02e9b03a2f0..1c89ef6bfe1ad78e0f7d25135619f481
}
bool RenderWidgetHostViewMac::SyncIsWidgetForMainFrame(
@@ -2199,12 +2205,14 @@ void CombineTextNodesAndMakeCallback(SpeechCallback callback,
@@ -2198,12 +2204,14 @@ void CombineTextNodesAndMakeCallback(SpeechCallback callback,
void RenderWidgetHostViewMac::SetRemoteAccessibilityWindowToken(
const std::vector<uint8_t>& window_token) {
@ -568,10 +568,10 @@ index 816e03b7a9c8d3dd1ca7ec2dc354a02e9b03a2f0..1c89ef6bfe1ad78e0f7d25135619f481
///////////////////////////////////////////////////////////////////////////////
diff --git a/content/common/BUILD.gn b/content/common/BUILD.gn
index 3c5d755932014bc28cd1ced41a49bd8c920c93b0..a15ed2cee75e5a82a3e43457c77471735e4c0fa2 100644
index 250d68fe80384f4409e91dd94a37ebc6ad34d383..4f5f1021dcdf2ca45531b8f56fed44b4c1097e8f 100644
--- a/content/common/BUILD.gn
+++ b/content/common/BUILD.gn
@@ -238,6 +238,7 @@ source_set("common") {
@@ -240,6 +240,7 @@ source_set("common") {
"//content:content_implementation",
"//build/config:precompiled_headers",
]
@ -660,10 +660,10 @@ index a119b4439bfb9218c7aaf09dca8e78527da7f20d..faa813b003940280c6eeb87e70173019
} // namespace content
diff --git a/content/test/BUILD.gn b/content/test/BUILD.gn
index 39fbfa15fb71497baa79e2989a1bafc87fa83fd4..0b71495e29c2d8fd512110ae416c277075ecd168 100644
index 581d0df81ddf0caf748abb13eac8097af91b0ac0..0c66545a917a12e710c594ff3b82ee023e7a1069 100644
--- a/content/test/BUILD.gn
+++ b/content/test/BUILD.gn
@@ -475,6 +475,7 @@ static_library("test_support") {
@@ -477,6 +477,7 @@ static_library("test_support") {
configs += [
"//build/config:precompiled_headers",
"//v8:external_startup_data",
@ -671,7 +671,7 @@ index 39fbfa15fb71497baa79e2989a1bafc87fa83fd4..0b71495e29c2d8fd512110ae416c2770
]
public_deps = [
@@ -1050,6 +1051,7 @@ static_library("browsertest_support") {
@@ -1052,6 +1053,7 @@ static_library("browsertest_support") {
}
configs += [ "//v8:external_startup_data" ]
@ -687,7 +687,7 @@ index 39fbfa15fb71497baa79e2989a1bafc87fa83fd4..0b71495e29c2d8fd512110ae416c2770
public_deps = [
":test_interfaces",
@@ -2912,6 +2915,7 @@ test("content_unittests") {
@@ -2917,6 +2920,7 @@ test("content_unittests") {
}
configs += [ "//build/config:precompiled_headers" ]
@ -709,10 +709,10 @@ index 38e5fd5c3af79a9f0ed80b2e15d748e9144b7982..508816a935744166cbc15561de07d7e7
sources += [ "browser/web_test_shell_platform_delegate_mac.mm" ]
} else if (toolkit_views && !is_castos) {
diff --git a/device/bluetooth/BUILD.gn b/device/bluetooth/BUILD.gn
index 6a662873b042a50f052e88bc849e3ef623963961..8b429cb2a5d6cd4555d7d56d3b072b05f87a30e6 100644
index e09b425de7f7c799f675d385d6a8189baaeb13dd..3ddb0afe42879933c7a15c1bb82309736e78a15a 100644
--- a/device/bluetooth/BUILD.gn
+++ b/device/bluetooth/BUILD.gn
@@ -242,6 +242,7 @@ component("bluetooth") {
@@ -243,6 +243,7 @@ component("bluetooth") {
"IOKit.framework",
"Foundation.framework",
]
@ -849,10 +849,10 @@ index 9c4e8e2536819610648aa5b3d11eaa5d2da24a9c..0b3660e51b0a15102b7b1726e17b34d5
ca_layer_tree_coordinator_->GetIOSurfaceForDisplay();
if (io_surface) {
diff --git a/media/audio/BUILD.gn b/media/audio/BUILD.gn
index 878a23986aa6c2bc3db8943c2a25414efdae51b4..d5d1d657faea0d949a47f1d2d5d07d2a73353f38 100644
index b3c80d0943c7418658e0c8cbe286d994aec14a3f..08228fde75372936b6f17efad7ed23cd05eaa06b 100644
--- a/media/audio/BUILD.gn
+++ b/media/audio/BUILD.gn
@@ -209,6 +209,7 @@ source_set("audio") {
@@ -199,6 +199,7 @@ source_set("audio") {
"CoreMedia.framework",
]
weak_frameworks = [ "ScreenCaptureKit.framework" ] # macOS 13.0
@ -861,7 +861,7 @@ index 878a23986aa6c2bc3db8943c2a25414efdae51b4..d5d1d657faea0d949a47f1d2d5d07d2a
if (is_ios) {
diff --git a/media/audio/mac/audio_low_latency_input_mac.cc b/media/audio/mac/audio_low_latency_input_mac.cc
index a21d4afac7ed2e17d6d31255be381b465de70e5b..00556993be4176b921be59dad57a5b0dff2e0da1 100644
index 244df26cbaecd482e812d53c96b6d63ac0a579e7..6ea4763fc7ba0d0747bd70615e076474b204853c 100644
--- a/media/audio/mac/audio_low_latency_input_mac.cc
+++ b/media/audio/mac/audio_low_latency_input_mac.cc
@@ -33,19 +33,23 @@
@ -889,7 +889,7 @@ index a21d4afac7ed2e17d6d31255be381b465de70e5b..00556993be4176b921be59dad57a5b0d
} // namespace
#endif
diff --git a/media/audio/mac/audio_manager_mac.cc b/media/audio/mac/audio_manager_mac.cc
index 473162885a2249cbc9b20bd810de95f54f0876f7..2fb15fcb7a04bfff01d7a22e79d467ba946b37d8 100644
index e229c574bbbc7933043418c9155daf7d78e75b68..4664ab42fed9b3071696265984d6a811fd528273 100644
--- a/media/audio/mac/audio_manager_mac.cc
+++ b/media/audio/mac/audio_manager_mac.cc
@@ -970,7 +970,7 @@ AudioParameters AudioManagerMac::GetPreferredOutputStreamParameters(
@ -902,10 +902,10 @@ index 473162885a2249cbc9b20bd810de95f54f0876f7..2fb15fcb7a04bfff01d7a22e79d467ba
}
diff --git a/net/dns/BUILD.gn b/net/dns/BUILD.gn
index 909de8327d937fea1fc690383fcef321f12929e7..4f686c1f826be0008ddd4f36acc292149f0ee058 100644
index 0c5cb82b1248997ef3b97f17bef52f880fed26fd..8adecabe9aee119c7474834c038c79b271ad888e 100644
--- a/net/dns/BUILD.gn
+++ b/net/dns/BUILD.gn
@@ -177,6 +177,8 @@ source_set("dns") {
@@ -183,6 +183,8 @@ source_set("dns") {
":host_resolver_manager",
":mdns_client",
]
@ -915,7 +915,7 @@ index 909de8327d937fea1fc690383fcef321f12929e7..4f686c1f826be0008ddd4f36acc29214
# The standard API of net/dns.
diff --git a/net/dns/dns_config_service_posix.cc b/net/dns/dns_config_service_posix.cc
index a93e7cd74d2a9d692304ecf10279fae8e96bb695..3506d6ca555701bad6623cc1c614e0081892e42b 100644
index 04c2079aac882cb2913583d4692302fdf564a74d..2a03be8bb4b089473e61601323646d257da5e39e 100644
--- a/net/dns/dns_config_service_posix.cc
+++ b/net/dns/dns_config_service_posix.cc
@@ -130,8 +130,8 @@ class DnsConfigServicePosix::Watcher : public DnsConfigService::Watcher {
@ -1278,7 +1278,7 @@ index eb81a70e4d5d5cd3e6ae9b45f8cd1c795ea76c51..dc30306f2c5d20503399fc3a8860773a
} // namespace sandbox
diff --git a/third_party/blink/renderer/core/BUILD.gn b/third_party/blink/renderer/core/BUILD.gn
index d9349048bd9f0dbf4058a0085211c31140fd8818..58b32362c3c6821257ca93311b8e3d54281f570b 100644
index b39c4b213855c1028e0d8149a9f3d46080023d2f..5b844fca5705299df8c91c5e3fb9060d714782e9 100644
--- a/third_party/blink/renderer/core/BUILD.gn
+++ b/third_party/blink/renderer/core/BUILD.gn
@@ -312,6 +312,7 @@ component("core") {
@ -1345,10 +1345,10 @@ index dcf493d62990018040a3f84b6f875af737bd2214..6ffffe8b3946e0427aead8be19878c53
void DisplayCALayerTree::GotIOSurfaceFrame(
diff --git a/ui/accessibility/platform/BUILD.gn b/ui/accessibility/platform/BUILD.gn
index 1fa9aeacd09eea1c90742f62528da0e71bc5bd34..8c25910bb27a2ed24feef30c7d6bcbd21fa59e82 100644
index 181b77f7ca4114540957343193cf7f3eecf6cf1f..8874adb1df8b0d9b9ff2bdb921472b59c027052d 100644
--- a/ui/accessibility/platform/BUILD.gn
+++ b/ui/accessibility/platform/BUILD.gn
@@ -253,6 +253,7 @@ component("platform") {
@@ -254,6 +254,7 @@ component("platform") {
weak_frameworks = [
"Accessibility.framework", # macOS 11
]
@ -1377,7 +1377,7 @@ index c737a2ca1afb44083aef33c6aa4518bea68d1aba..879f1357b5129849c5a1aa1731cf7697
// Accessible object
if (AXElementWrapper::IsValidElement(value)) {
diff --git a/ui/base/BUILD.gn b/ui/base/BUILD.gn
index cec02efe6a5d1e40e5141151fb0f75f9b8bc88b5..a048095f800eece7cede1ee528093d2721902e8f 100644
index 1147a6e268f64abc72f84ab05a5d558a98120c89..86d5b9c05961cb803b2f61738328bf5b81c7bc2b 100644
--- a/ui/base/BUILD.gn
+++ b/ui/base/BUILD.gn
@@ -359,6 +359,7 @@ component("base") {
@ -1556,10 +1556,10 @@ index b28640bb4d89ba9508d4086c9e5ca9ed4a9a7023..15cb883b91f624c1f23f4458dbf8d147
// enough.
return PlatformFontMac::SystemFontType::kGeneral;
diff --git a/ui/views/BUILD.gn b/ui/views/BUILD.gn
index b9d7fa0a32d7487d93918d87f0903fa663271d1f..5dbda740b1dd7c119ad9b0d2ce70050a2db735c7 100644
index 3600dd711ffdde460cda5b4c11817997bf61704a..6bb301dda6562e419bc36ec80d5974babc9aeb50 100644
--- a/ui/views/BUILD.gn
+++ b/ui/views/BUILD.gn
@@ -701,6 +701,7 @@ component("views") {
@@ -703,6 +703,7 @@ component("views") {
"IOSurface.framework",
"QuartzCore.framework",
]
@ -1567,7 +1567,7 @@ index b9d7fa0a32d7487d93918d87f0903fa663271d1f..5dbda740b1dd7c119ad9b0d2ce70050a
}
if (is_win) {
@@ -1132,6 +1133,8 @@ source_set("test_support") {
@@ -1134,6 +1135,8 @@ source_set("test_support") {
"//testing/gtest",
]

Просмотреть файл

@ -7,10 +7,10 @@ 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 dc72b9420d81824b01448f862f300877c762e5c5..c3d269712d75d0982302cedd2fc3a23973498fa9 100644
index 4547a0dc6956204da4a8b6d8ac203a78b678767a..8dd57dc6d943054bda0e3ab9d992732f36ec6d3e 100644
--- a/services/network/network_context.cc
+++ b/services/network/network_context.cc
@@ -146,6 +146,11 @@
@@ -150,6 +150,11 @@
#include "third_party/abseil-cpp/absl/types/optional.h"
#include "url/gurl.h"
@ -22,7 +22,7 @@ index dc72b9420d81824b01448f862f300877c762e5c5..c3d269712d75d0982302cedd2fc3a239
#if BUILDFLAG(IS_CT_SUPPORTED)
// gn check does not account for BUILDFLAG(). So, for iOS builds, it will
// complain about a missing dependency on the target exposing this header. Add a
@@ -426,6 +431,99 @@ bool GetFullDataFilePath(
@@ -513,6 +518,99 @@ bool GetFullDataFilePath(
} // namespace
@ -122,7 +122,7 @@ index dc72b9420d81824b01448f862f300877c762e5c5..c3d269712d75d0982302cedd2fc3a239
constexpr uint32_t NetworkContext::kMaxOutstandingRequestsPerProcess;
NetworkContext::NetworkContextHttpAuthPreferences::
@@ -791,6 +889,13 @@ void NetworkContext::SetClient(
@@ -878,6 +976,13 @@ void NetworkContext::SetClient(
client_.Bind(std::move(client));
}
@ -136,7 +136,7 @@ index dc72b9420d81824b01448f862f300877c762e5c5..c3d269712d75d0982302cedd2fc3a239
void NetworkContext::CreateURLLoaderFactory(
mojo::PendingReceiver<mojom::URLLoaderFactory> receiver,
mojom::URLLoaderFactoryParamsPtr params) {
@@ -2341,6 +2446,9 @@ URLRequestContextOwner NetworkContext::MakeURLRequestContext(
@@ -2327,6 +2432,9 @@ URLRequestContextOwner NetworkContext::MakeURLRequestContext(
std::move(cert_verifier));
cert_verifier = base::WrapUnique(cert_verifier_with_trust_anchors_.get());
#endif // BUILDFLAG(IS_CHROMEOS)
@ -147,7 +147,7 @@ index dc72b9420d81824b01448f862f300877c762e5c5..c3d269712d75d0982302cedd2fc3a239
builder.SetCertVerifier(IgnoreErrorsCertVerifier::MaybeWrapCertVerifier(
diff --git a/services/network/network_context.h b/services/network/network_context.h
index 5a8232b338453ce3374d51ceebe8a85fc26f2a52..bd06da51ad2106b6a95abb9d773d66ca7d4f8c15 100644
index ebadb14137f7d3bc2a30d050dceaf90645a40e70..453ab6cf11c5fd5aea9f8e30f1d2582cd20f36c4 100644
--- a/services/network/network_context.h
+++ b/services/network/network_context.h
@@ -113,6 +113,7 @@ class URLMatcher;
@ -158,7 +158,7 @@ index 5a8232b338453ce3374d51ceebe8a85fc26f2a52..bd06da51ad2106b6a95abb9d773d66ca
class CookieManager;
class HostResolver;
class MdnsResponderManager;
@@ -246,6 +247,8 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
@@ -245,6 +246,8 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
void CreateURLLoaderFactory(
mojo::PendingReceiver<mojom::URLLoaderFactory> receiver,
mojom::URLLoaderFactoryParamsPtr params) override;
@ -167,7 +167,7 @@ index 5a8232b338453ce3374d51ceebe8a85fc26f2a52..bd06da51ad2106b6a95abb9d773d66ca
void ResetURLLoaderFactories() override;
void GetViaObliviousHttp(
mojom::ObliviousHttpRequestPtr request,
@@ -887,6 +890,8 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
@@ -880,6 +883,8 @@ class COMPONENT_EXPORT(NETWORK_SERVICE) NetworkContext
std::vector<base::OnceClosure> dismount_closures_;
#endif // BUILDFLAG(IS_DIRECTORY_TRANSFER_REQUIRED)
@ -177,10 +177,10 @@ index 5a8232b338453ce3374d51ceebe8a85fc26f2a52..bd06da51ad2106b6a95abb9d773d66ca
std::unique_ptr<HostResolver> internal_host_resolver_;
// Map values set to non-null only if that HostResolver has its own private
diff --git a/services/network/public/mojom/network_context.mojom b/services/network/public/mojom/network_context.mojom
index b80b7c98ddd4660ef63f0d40c8889c7e71dfde81..fc3b31beea192b21f24f35debf6df12dfab40c65 100644
index 3096bd7d6719b99818ad2e5befefd4dbeee0ddb8..fee16e02e0160825e44c668672176546abe7d99d 100644
--- a/services/network/public/mojom/network_context.mojom
+++ b/services/network/public/mojom/network_context.mojom
@@ -310,6 +310,16 @@ struct SocketBrokerRemotes {
@@ -297,6 +297,16 @@ struct SocketBrokerRemotes {
pending_remote<SocketBroker> server;
};
@ -197,7 +197,7 @@ index b80b7c98ddd4660ef63f0d40c8889c7e71dfde81..fc3b31beea192b21f24f35debf6df12d
// Parameters for constructing a network context.
struct NetworkContextParams {
@@ -952,6 +962,9 @@ interface NetworkContext {
@@ -970,6 +980,9 @@ interface NetworkContext {
// Sets a client for this network context.
SetClient(pending_remote<NetworkContextClient> client);
@ -208,7 +208,7 @@ index b80b7c98ddd4660ef63f0d40c8889c7e71dfde81..fc3b31beea192b21f24f35debf6df12d
CreateURLLoaderFactory(pending_receiver<URLLoaderFactory> url_loader_factory,
URLLoaderFactoryParams params);
diff --git a/services/network/test/test_network_context.h b/services/network/test/test_network_context.h
index 23694108d7d81ac70085513ef32f569f89564682..be94ed854cb5cf9e165e7e83a2e8cd3d3ab498cd 100644
index caf25a79cface282294e4646dcb8fd08d6ca6efd..381c00fbe1af5711860b3237be1165e1c58540c0 100644
--- a/services/network/test/test_network_context.h
+++ b/services/network/test/test_network_context.h
@@ -62,6 +62,8 @@ class TestNetworkContext : public mojom::NetworkContext {

Просмотреть файл

@ -7,7 +7,7 @@ Pass RenderFrameHost through to PlatformNotificationService
so Electron can identify which renderer a notification came from.
diff --git a/chrome/browser/notifications/platform_notification_service_impl.cc b/chrome/browser/notifications/platform_notification_service_impl.cc
index 89534cf6d7ec55c4d422a88531543285f72ec309..a51115e4195f469beb8f38a0a682b828b8b113c0 100644
index 100dba0d749d11bbf751f42c88514d3b493ca670..cb0dc4f235282076b13fa84d9d4549525c443783 100644
--- a/chrome/browser/notifications/platform_notification_service_impl.cc
+++ b/chrome/browser/notifications/platform_notification_service_impl.cc
@@ -198,6 +198,7 @@ bool PlatformNotificationServiceImpl::WasClosedProgrammatically(
@ -19,7 +19,7 @@ index 89534cf6d7ec55c4d422a88531543285f72ec309..a51115e4195f469beb8f38a0a682b828
const GURL& origin,
const GURL& document_url,
diff --git a/chrome/browser/notifications/platform_notification_service_impl.h b/chrome/browser/notifications/platform_notification_service_impl.h
index 2552c32ed769482c8bbb7b7538bf59cb66dcc16d..7fda86e70ad47766211a9ff8b5ed732068f0b885 100644
index 557b1daecbd01ed7d6ed0940da6d1746d772a094..b73eb24074d097867f105a619fe7587468dfe8d9 100644
--- a/chrome/browser/notifications/platform_notification_service_impl.h
+++ b/chrome/browser/notifications/platform_notification_service_impl.h
@@ -57,6 +57,7 @@ class PlatformNotificationServiceImpl
@ -79,10 +79,10 @@ index e7cc73f375ada7ee8715d331c3d372e0f59a0cdf..c0a142bea4a9a30c10dbb30c72fedce9
scoped_refptr<ServiceWorkerContextWrapper> service_worker_context_;
diff --git a/content/browser/notifications/blink_notification_service_impl_unittest.cc b/content/browser/notifications/blink_notification_service_impl_unittest.cc
index 15525538284b202acdcd3bacdd2b55db16cf6cb7..454e0307bd374a443d3e2f2dbb4ffa330d22d04f 100644
index a437b634d9c644b2238a142cdd494535cbaa6438..66ef22b1d19a76f03a5f1eb0b70cd04629500322 100644
--- a/content/browser/notifications/blink_notification_service_impl_unittest.cc
+++ b/content/browser/notifications/blink_notification_service_impl_unittest.cc
@@ -130,7 +130,7 @@ class BlinkNotificationServiceImplTest : public ::testing::Test {
@@ -132,7 +132,7 @@ class BlinkNotificationServiceImplTest : public ::testing::Test {
notification_service_ = std::make_unique<BlinkNotificationServiceImpl>(
notification_context_.get(), &browser_context_,
embedded_worker_helper_->context_wrapper(), &render_process_host_,
@ -92,7 +92,7 @@ index 15525538284b202acdcd3bacdd2b55db16cf6cb7..454e0307bd374a443d3e2f2dbb4ffa33
contents_.get()->GetPrimaryMainFrame()->GetWeakDocumentPtr(),
RenderProcessHost::NotificationServiceCreatorType::kDocument,
diff --git a/content/browser/notifications/platform_notification_context_impl.cc b/content/browser/notifications/platform_notification_context_impl.cc
index 18cca28edc35dadd4eb9173558d1764b1bf85dd5..4cda3b7f2db6be365e4edb9456e1f72244a5158e 100644
index 91d36320a27dbc5eff347cde519eda207eae1144..320668dd8f6f1eb9312d3a74990e08da83045310 100644
--- a/content/browser/notifications/platform_notification_context_impl.cc
+++ b/content/browser/notifications/platform_notification_context_impl.cc
@@ -268,6 +268,7 @@ void PlatformNotificationContextImpl::Shutdown() {
@ -113,10 +113,10 @@ index 18cca28edc35dadd4eb9173558d1764b1bf85dd5..4cda3b7f2db6be365e4edb9456e1f722
}
diff --git a/content/browser/notifications/platform_notification_context_impl.h b/content/browser/notifications/platform_notification_context_impl.h
index 1dc5478b8d0787a1cc82dc9fcb0227fed3f583c2..9a76f675ccdd4b173afa65aa05b733d456f30cff 100644
index 38c8cf36fdf9366121c7ada96c167a4c9664952e..03b37fb62655a355e104870a088e4222932bdc17 100644
--- a/content/browser/notifications/platform_notification_context_impl.h
+++ b/content/browser/notifications/platform_notification_context_impl.h
@@ -46,6 +46,7 @@ class PlatformNotificationServiceProxy;
@@ -47,6 +47,7 @@ class PlatformNotificationServiceProxy;
class RenderProcessHost;
class ServiceWorkerContextWrapper;
class WeakDocumentPtr;
@ -124,7 +124,7 @@ index 1dc5478b8d0787a1cc82dc9fcb0227fed3f583c2..9a76f675ccdd4b173afa65aa05b733d4
// Implementation of the Web Notification storage context. The public methods
// defined in this interface must only be called on the UI thread.
@@ -79,6 +80,7 @@ class CONTENT_EXPORT PlatformNotificationContextImpl
@@ -80,6 +81,7 @@ class CONTENT_EXPORT PlatformNotificationContextImpl
// service is created by a dedicated worker, or is `nullptr` otherwise.
void CreateService(
RenderProcessHost* render_process_host,
@ -133,10 +133,10 @@ index 1dc5478b8d0787a1cc82dc9fcb0227fed3f583c2..9a76f675ccdd4b173afa65aa05b733d4
const GURL& document_url,
const WeakDocumentPtr& weak_document_ptr,
diff --git a/content/browser/renderer_host/render_process_host_impl.cc b/content/browser/renderer_host/render_process_host_impl.cc
index 552b65924a415df32bffca6d2518cc76bce0505f..23c2f323ce9172d6e8a42d0cc031da5a0540ce35 100644
index b656054d342f53d655b8c068b127250a8e8af6c3..5f6267cce7c59eab684dda3f8bfc7982b6407841 100644
--- a/content/browser/renderer_host/render_process_host_impl.cc
+++ b/content/browser/renderer_host/render_process_host_impl.cc
@@ -2041,7 +2041,7 @@ void RenderProcessHostImpl::CreateNotificationService(
@@ -2045,7 +2045,7 @@ void RenderProcessHostImpl::CreateNotificationService(
case RenderProcessHost::NotificationServiceCreatorType::kSharedWorker:
case RenderProcessHost::NotificationServiceCreatorType::kDedicatedWorker: {
storage_partition_impl_->GetPlatformNotificationContext()->CreateService(
@ -145,7 +145,7 @@ index 552b65924a415df32bffca6d2518cc76bce0505f..23c2f323ce9172d6e8a42d0cc031da5a
creator_type, std::move(receiver));
break;
}
@@ -2049,7 +2049,7 @@ void RenderProcessHostImpl::CreateNotificationService(
@@ -2053,7 +2053,7 @@ void RenderProcessHostImpl::CreateNotificationService(
CHECK(rfh);
storage_partition_impl_->GetPlatformNotificationContext()->CreateService(
@ -176,7 +176,7 @@ index 82db1db4175fb9f4ee7490d5a163164ef4495ecb..4f51683be14ba6ee657a290c7747969e
const GURL& origin,
const GURL& document_url,
diff --git a/content/test/mock_platform_notification_service.cc b/content/test/mock_platform_notification_service.cc
index 2d3b66e8f1960b46d0e790d803fefb3b85c62603..c8106d1390e75bd74fc38cf138cca37ad08b1486 100644
index 32a0cf38389989d3e1c287ad4a3f26b6d3615370..8a788f243e913ef26246b5ea4ac4ac5c1dfc4b86 100644
--- a/content/test/mock_platform_notification_service.cc
+++ b/content/test/mock_platform_notification_service.cc
@@ -29,6 +29,7 @@ MockPlatformNotificationService::MockPlatformNotificationService(
@ -188,10 +188,10 @@ index 2d3b66e8f1960b46d0e790d803fefb3b85c62603..c8106d1390e75bd74fc38cf138cca37a
const GURL& origin,
const GURL& document_url,
diff --git a/content/test/mock_platform_notification_service.h b/content/test/mock_platform_notification_service.h
index 66fd1e7f1171fec33c337375a9f8f11fcc6ab27e..188d507b42544dfab7abceed24097766496086b5 100644
index 5e91d867ba1b04358ecb670ba407adc65793b417..a0c5eaafd9ec2242927fe9170e9acd4069f654a0 100644
--- a/content/test/mock_platform_notification_service.h
+++ b/content/test/mock_platform_notification_service.h
@@ -52,6 +52,7 @@ class MockPlatformNotificationService : public PlatformNotificationService {
@@ -53,6 +53,7 @@ class MockPlatformNotificationService : public PlatformNotificationService {
// PlatformNotificationService implementation.
void DisplayNotification(

Просмотреть файл

@ -11,10 +11,10 @@ majority of changes originally come from these PRs:
This patch also fixes callback for manual user cancellation and success.
diff --git a/BUILD.gn b/BUILD.gn
index 2fafbb88224a6290733379631a08e5e20b08218d..81bc36fa8525d6b7dd9482284553fc67a403c4b1 100644
index 067b08552d5fcb3f9f25b9971c0252a6c26282d7..11b3c6286fa6860138edbd387945453d5a1548b6 100644
--- a/BUILD.gn
+++ b/BUILD.gn
@@ -966,7 +966,6 @@ if (is_win) {
@@ -971,7 +971,6 @@ if (is_win) {
"//media:media_unittests",
"//media/midi:midi_unittests",
"//net:net_unittests",
@ -22,7 +22,7 @@ index 2fafbb88224a6290733379631a08e5e20b08218d..81bc36fa8525d6b7dd9482284553fc67
"//sql:sql_unittests",
"//third_party/breakpad:symupload($host_toolchain)",
"//ui/base:ui_base_unittests",
@@ -975,6 +974,10 @@ if (is_win) {
@@ -980,6 +979,10 @@ if (is_win) {
"//ui/views:views_unittests",
"//url:url_unittests",
]
@ -34,10 +34,10 @@ index 2fafbb88224a6290733379631a08e5e20b08218d..81bc36fa8525d6b7dd9482284553fc67
}
diff --git a/chrome/browser/printing/print_job.cc b/chrome/browser/printing/print_job.cc
index c60e2083bf70d2310bec57646df797856aa7d2dd..dabf6536a0dd67635a551a4d8aaed981bdaca4de 100644
index 874b9efcf9e70650728885519009360ee770a79f..6c4d24d44e69d796bc6bfec5f7092f5b3ae28703 100644
--- a/chrome/browser/printing/print_job.cc
+++ b/chrome/browser/printing/print_job.cc
@@ -95,6 +95,7 @@ bool PrintWithReducedRasterization(PrefService* prefs) {
@@ -96,6 +96,7 @@ bool PrintWithReducedRasterization(PrefService* prefs) {
return base::FeatureList::IsEnabled(features::kPrintWithReducedRasterization);
}
@ -45,7 +45,7 @@ index c60e2083bf70d2310bec57646df797856aa7d2dd..dabf6536a0dd67635a551a4d8aaed981
PrefService* GetPrefsForWebContents(content::WebContents* web_contents) {
// TODO(thestig): Figure out why crbug.com/1083911 occurred, which is likely
// because `web_contents` was null. As a result, this section has many more
@@ -109,6 +110,7 @@ content::WebContents* GetWebContents(content::GlobalRenderFrameHostId rfh_id) {
@@ -110,6 +111,7 @@ content::WebContents* GetWebContents(content::GlobalRenderFrameHostId rfh_id) {
auto* rfh = content::RenderFrameHost::FromID(rfh_id);
return rfh ? content::WebContents::FromRenderFrameHost(rfh) : nullptr;
}
@ -53,7 +53,7 @@ index c60e2083bf70d2310bec57646df797856aa7d2dd..dabf6536a0dd67635a551a4d8aaed981
#endif // BUILDFLAG(IS_WIN)
@@ -149,10 +151,8 @@ void PrintJob::Initialize(std::unique_ptr<PrinterQuery> query,
@@ -150,10 +152,8 @@ void PrintJob::Initialize(std::unique_ptr<PrinterQuery> query,
#if BUILDFLAG(IS_WIN)
pdf_page_mapping_ = PageNumber::GetPages(settings->ranges(), page_count);
@ -66,7 +66,7 @@ index c60e2083bf70d2310bec57646df797856aa7d2dd..dabf6536a0dd67635a551a4d8aaed981
#endif
auto new_doc = base::MakeRefCounted<PrintedDocument>(std::move(settings),
@@ -403,8 +403,10 @@ void PrintJob::StartPdfToEmfConversion(
@@ -404,8 +404,10 @@ void PrintJob::StartPdfToEmfConversion(
const PrintSettings& settings = document()->settings();
@ -78,7 +78,7 @@ index c60e2083bf70d2310bec57646df797856aa7d2dd..dabf6536a0dd67635a551a4d8aaed981
using RenderMode = PdfRenderSettings::Mode;
RenderMode mode = print_with_reduced_rasterization
@@ -496,8 +498,10 @@ void PrintJob::StartPdfToPostScriptConversion(
@@ -497,8 +499,10 @@ void PrintJob::StartPdfToPostScriptConversion(
if (ps_level2) {
mode = PdfRenderSettings::Mode::POSTSCRIPT_LEVEL2;
} else {
@ -91,10 +91,10 @@ index c60e2083bf70d2310bec57646df797856aa7d2dd..dabf6536a0dd67635a551a4d8aaed981
: PdfRenderSettings::Mode::POSTSCRIPT_LEVEL3;
}
diff --git a/chrome/browser/printing/print_view_manager_base.cc b/chrome/browser/printing/print_view_manager_base.cc
index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f09d5d571 100644
index 301a4a47fb4dfb6007c2214b04ffdff744cc3043..427a045c310109475b83a229637f4d09b1e78450 100644
--- a/chrome/browser/printing/print_view_manager_base.cc
+++ b/chrome/browser/printing/print_view_manager_base.cc
@@ -22,7 +22,9 @@
@@ -23,7 +23,9 @@
#include "build/chromeos_buildflags.h"
#include "chrome/browser/bad_message.h"
#include "chrome/browser/browser_process.h"
@ -104,7 +104,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
#include "chrome/browser/printing/print_job.h"
#include "chrome/browser/printing/print_job_manager.h"
#include "chrome/browser/printing/print_view_manager_common.h"
@@ -80,6 +82,20 @@ namespace printing {
@@ -81,6 +83,20 @@ namespace printing {
namespace {
@ -125,7 +125,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
void OnDidGetDefaultPrintSettings(
scoped_refptr<PrintQueriesQueue> queue,
bool want_pdf_settings,
@@ -88,9 +104,11 @@ void OnDidGetDefaultPrintSettings(
@@ -89,9 +105,11 @@ void OnDidGetDefaultPrintSettings(
DCHECK_CURRENTLY_ON(content::BrowserThread::UI);
if (printer_query->last_status() != mojom::ResultCode::kSuccess) {
@ -137,7 +137,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
std::move(callback).Run(nullptr);
return;
}
@@ -100,9 +118,11 @@ void OnDidGetDefaultPrintSettings(
@@ -101,9 +119,11 @@ void OnDidGetDefaultPrintSettings(
params->document_cookie = printer_query->cookie();
if (!PrintMsgPrintParamsIsValid(*params)) {
@ -149,7 +149,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
std::move(callback).Run(nullptr);
return;
}
@@ -114,11 +134,15 @@ void OnDidGetDefaultPrintSettings(
@@ -115,11 +135,15 @@ void OnDidGetDefaultPrintSettings(
void OnDidScriptedPrint(
scoped_refptr<PrintQueriesQueue> queue,
std::unique_ptr<PrinterQuery> printer_query,
@ -166,7 +166,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
std::move(callback).Run(nullptr);
return;
}
@@ -171,9 +195,11 @@ PrintViewManagerBase::PrintViewManagerBase(content::WebContents* web_contents)
@@ -176,9 +200,11 @@ PrintViewManagerBase::PrintViewManagerBase(content::WebContents* web_contents)
: PrintManager(web_contents),
queue_(g_browser_process->print_job_manager()->queue()) {
DCHECK(queue_);
@ -179,7 +179,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
}
PrintViewManagerBase::~PrintViewManagerBase() {
@@ -197,12 +223,17 @@ void PrintViewManagerBase::DisableThirdPartyBlocking() {
@@ -202,12 +228,17 @@ void PrintViewManagerBase::DisableThirdPartyBlocking() {
}
#endif // BUILDFLAG(IS_WIN) && BUILDFLAG(GOOGLE_CHROME_BRANDING)
@ -199,7 +199,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
for (auto& observer : GetTestObservers()) {
observer.OnPrintNow(rfh);
@@ -331,12 +362,13 @@ void PrintViewManagerBase::OnDidUpdatePrintableArea(
@@ -336,12 +367,13 @@ void PrintViewManagerBase::OnDidUpdatePrintableArea(
}
PRINTER_LOG(EVENT) << "Paper printable area updated for vendor id "
<< print_settings->requested_media().vendor_id;
@ -214,7 +214,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
base::Value::Dict job_settings,
std::unique_ptr<PrintSettings> print_settings,
UpdatePrintSettingsCallback callback) {
@@ -344,7 +376,8 @@ void PrintViewManagerBase::CompleteUpdatePrintSettings(
@@ -349,7 +381,8 @@ void PrintViewManagerBase::CompleteUpdatePrintSettings(
settings->pages = GetPageRangesFromJobSettings(job_settings);
settings->params = mojom::PrintParams::New();
RenderParamsFromPrintSettings(*print_settings, settings->params.get());
@ -224,7 +224,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
if (!PrintMsgPrintParamsIsValid(*settings->params)) {
mojom::PrinterType printer_type = static_cast<mojom::PrinterType>(
*job_settings.FindInt(kSettingPrinterType));
@@ -356,6 +389,10 @@ void PrintViewManagerBase::CompleteUpdatePrintSettings(
@@ -361,6 +394,10 @@ void PrintViewManagerBase::CompleteUpdatePrintSettings(
return;
}
@ -235,7 +235,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
set_cookie(settings->params->document_cookie);
std::move(callback).Run(std::move(settings));
}
@@ -642,10 +679,12 @@ void PrintViewManagerBase::DidPrintDocument(
@@ -647,11 +684,12 @@ void PrintViewManagerBase::DidPrintDocument(
void PrintViewManagerBase::GetDefaultPrintSettings(
GetDefaultPrintSettingsCallback callback) {
DCHECK_CURRENTLY_ON(content::BrowserThread::UI);
@ -244,11 +244,12 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
GetDefaultPrintSettingsReply(std::move(callback), nullptr);
return;
}
-
+#endif
#if BUILDFLAG(ENABLE_OOP_PRINTING)
if (ShouldPrintJobOop() &&
#if BUILDFLAG(ENABLE_PRINT_CONTENT_ANALYSIS)
@@ -697,10 +736,12 @@ void PrintViewManagerBase::UpdatePrintSettings(
content::RenderFrameHost* render_frame_host = GetCurrentTargetFrame();
if (base::FeatureList::IsEnabled(kCheckPrintRfhIsActive) &&
!render_frame_host->IsActive()) {
@@ -710,10 +748,12 @@ void PrintViewManagerBase::UpdatePrintSettings(
base::Value::Dict job_settings,
UpdatePrintSettingsCallback callback) {
DCHECK_CURRENTLY_ON(content::BrowserThread::UI);
@ -259,9 +260,9 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
}
+#endif // Printing is always enabled.
absl::optional<int> printer_type_value =
std::optional<int> printer_type_value =
job_settings.FindInt(kSettingPrinterType);
@@ -711,6 +752,7 @@ void PrintViewManagerBase::UpdatePrintSettings(
@@ -724,6 +764,7 @@ void PrintViewManagerBase::UpdatePrintSettings(
mojom::PrinterType printer_type =
static_cast<mojom::PrinterType>(*printer_type_value);
@ -269,7 +270,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
if (printer_type != mojom::PrinterType::kExtension &&
printer_type != mojom::PrinterType::kPdf &&
printer_type != mojom::PrinterType::kLocal) {
@@ -730,6 +772,7 @@ void PrintViewManagerBase::UpdatePrintSettings(
@@ -743,6 +784,7 @@ void PrintViewManagerBase::UpdatePrintSettings(
if (value > 0)
job_settings.Set(kSettingRasterizePdfDpi, value);
}
@ -277,7 +278,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
std::unique_ptr<PrintSettings> print_settings =
PrintSettingsFromJobSettings(job_settings);
@@ -749,7 +792,21 @@ void PrintViewManagerBase::UpdatePrintSettings(
@@ -762,7 +804,21 @@ void PrintViewManagerBase::UpdatePrintSettings(
}
}
@ -300,7 +301,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
// TODO(crbug.com/1424368): Remove this if the printable areas can be made
// fully available from `PrintBackend::GetPrinterSemanticCapsAndDefaults()`
// for in-browser queries.
@@ -771,8 +828,6 @@ void PrintViewManagerBase::UpdatePrintSettings(
@@ -784,8 +840,6 @@ void PrintViewManagerBase::UpdatePrintSettings(
}
#endif
@ -309,7 +310,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
}
void PrintViewManagerBase::SetAccessibilityTree(
@@ -788,7 +843,7 @@ void PrintViewManagerBase::SetAccessibilityTree(
@@ -801,7 +855,7 @@ void PrintViewManagerBase::SetAccessibilityTree(
void PrintViewManagerBase::IsPrintingEnabled(
IsPrintingEnabledCallback callback) {
DCHECK_CURRENTLY_ON(content::BrowserThread::UI);
@ -318,7 +319,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
}
void PrintViewManagerBase::ScriptedPrint(mojom::ScriptedPrintParamsPtr params,
@@ -839,6 +894,7 @@ void PrintViewManagerBase::PrintingFailed(int32_t cookie,
@@ -852,6 +906,7 @@ void PrintViewManagerBase::PrintingFailed(int32_t cookie,
PrintManager::PrintingFailed(cookie, reason);
@ -326,7 +327,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
// `PrintingFailed()` can occur because asynchronous compositing results
// don't complete until after a print job has already failed and been
// destroyed. In such cases the error notification to the user will
@@ -848,7 +904,7 @@ void PrintViewManagerBase::PrintingFailed(int32_t cookie,
@@ -861,7 +916,7 @@ void PrintViewManagerBase::PrintingFailed(int32_t cookie,
print_job_->document()->cookie() == cookie) {
ShowPrintErrorDialogForGenericError();
}
@ -335,7 +336,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
ReleasePrinterQuery();
}
@@ -860,15 +916,24 @@ void PrintViewManagerBase::RemoveTestObserver(TestObserver& observer) {
@@ -873,15 +928,24 @@ void PrintViewManagerBase::RemoveTestObserver(TestObserver& observer) {
test_observers_.RemoveObserver(&observer);
}
@ -360,7 +361,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
}
void PrintViewManagerBase::RenderFrameDeleted(
@@ -920,7 +985,12 @@ void PrintViewManagerBase::OnJobDone() {
@@ -933,7 +997,12 @@ void PrintViewManagerBase::OnJobDone() {
// Printing is done, we don't need it anymore.
// print_job_->is_job_pending() may still be true, depending on the order
// of object registration.
@ -374,7 +375,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
ReleasePrintJob();
}
@@ -929,9 +999,10 @@ void PrintViewManagerBase::OnCanceling() {
@@ -942,9 +1011,10 @@ void PrintViewManagerBase::OnCanceling() {
}
void PrintViewManagerBase::OnFailed() {
@ -386,7 +387,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
TerminatePrintJob(true);
}
@@ -941,7 +1012,7 @@ bool PrintViewManagerBase::RenderAllMissingPagesNow() {
@@ -954,7 +1024,7 @@ bool PrintViewManagerBase::RenderAllMissingPagesNow() {
// Is the document already complete?
if (print_job_->document() && print_job_->document()->IsComplete()) {
@ -395,7 +396,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
return true;
}
@@ -994,7 +1065,10 @@ bool PrintViewManagerBase::SetupNewPrintJob(
@@ -1007,7 +1077,10 @@ bool PrintViewManagerBase::SetupNewPrintJob(
// Disconnect the current `print_job_`.
auto weak_this = weak_ptr_factory_.GetWeakPtr();
@ -407,7 +408,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
if (!weak_this)
return false;
@@ -1014,7 +1088,7 @@ bool PrintViewManagerBase::SetupNewPrintJob(
@@ -1027,7 +1100,7 @@ bool PrintViewManagerBase::SetupNewPrintJob(
#endif
print_job_->AddObserver(*this);
@ -416,7 +417,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
return true;
}
@@ -1082,6 +1156,11 @@ void PrintViewManagerBase::ReleasePrintJob() {
@@ -1095,6 +1168,11 @@ void PrintViewManagerBase::ReleasePrintJob() {
}
#endif
@ -428,7 +429,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
if (!print_job_)
return;
@@ -1089,7 +1168,7 @@ void PrintViewManagerBase::ReleasePrintJob() {
@@ -1102,7 +1180,7 @@ void PrintViewManagerBase::ReleasePrintJob() {
// printing_rfh_ should only ever point to a RenderFrameHost with a live
// RenderFrame.
DCHECK(rfh->IsRenderFrameLive());
@ -437,7 +438,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
}
print_job_->RemoveObserver(*this);
@@ -1131,7 +1210,7 @@ bool PrintViewManagerBase::RunInnerMessageLoop() {
@@ -1144,7 +1222,7 @@ bool PrintViewManagerBase::RunInnerMessageLoop() {
}
bool PrintViewManagerBase::OpportunisticallyCreatePrintJob(int cookie) {
@ -446,7 +447,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
return true;
if (!cookie) {
@@ -1285,6 +1364,8 @@ void PrintViewManagerBase::CompleteScriptedPrint(
@@ -1298,6 +1376,8 @@ void PrintViewManagerBase::CompleteScriptedPrint(
auto callback_wrapper = base::BindOnce(
&PrintViewManagerBase::ScriptedPrintReply, weak_ptr_factory_.GetWeakPtr(),
std::move(callback), render_process_host->GetID());
@ -455,7 +456,7 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
#if BUILDFLAG(IS_WIN) && BUILDFLAG(GOOGLE_CHROME_BRANDING)
DisableThirdPartyBlocking();
#endif
@@ -1299,7 +1380,7 @@ void PrintViewManagerBase::CompleteScriptedPrint(
@@ -1312,7 +1392,7 @@ void PrintViewManagerBase::CompleteScriptedPrint(
params->expected_pages_count, params->has_selection, params->margin_type,
params->is_scripted, !render_process_host->IsPdf(),
base::BindOnce(&OnDidScriptedPrint, queue_, std::move(printer_query),
@ -465,19 +466,19 @@ index f033faa6f451074adfb58d4430e9465999f803bb..84b604a103666dec5cdca9921bebdc8f
#if BUILDFLAG(ENABLE_PRINT_CONTENT_ANALYSIS)
diff --git a/chrome/browser/printing/print_view_manager_base.h b/chrome/browser/printing/print_view_manager_base.h
index f137fc60162622a37c2e4896f521fa3da9dac68e..f7a15e6189736bd86474be3b86a080fdf8b78984 100644
index 24a2bc8b26462e6cafbcd5eb89e838b73266ec70..402aab3b14e6987bde0e22e6c82ac438d465330a 100644
--- a/chrome/browser/printing/print_view_manager_base.h
+++ b/chrome/browser/printing/print_view_manager_base.h
@@ -44,6 +44,8 @@ namespace printing {
class PrintQueriesQueue;
class PrinterQuery;
@@ -49,6 +49,8 @@ class PrinterQuery;
// rollout.
BASE_DECLARE_FEATURE(kCheckPrintRfhIsActive);
+using CompletionCallback = base::OnceCallback<void(bool, const std::string&)>;
+
// Base class for managing the print commands for a WebContents.
class PrintViewManagerBase : public PrintManager, public PrintJob::Observer {
public:
@@ -77,7 +79,10 @@ class PrintViewManagerBase : public PrintManager, public PrintJob::Observer {
@@ -82,7 +84,10 @@ class PrintViewManagerBase : public PrintManager, public PrintJob::Observer {
// Prints the current document immediately. Since the rendering is
// asynchronous, the actual printing will not be completed on the return of
// this function. Returns false if printing is impossible at the moment.
@ -489,7 +490,7 @@ index f137fc60162622a37c2e4896f521fa3da9dac68e..f7a15e6189736bd86474be3b86a080fd
// Like PrintNow(), but for the node under the context menu, instead of the
// entire frame.
@@ -131,8 +136,10 @@ class PrintViewManagerBase : public PrintManager, public PrintJob::Observer {
@@ -136,8 +141,10 @@ class PrintViewManagerBase : public PrintManager, public PrintJob::Observer {
void IsPrintingEnabled(IsPrintingEnabledCallback callback) override;
void ScriptedPrint(mojom::ScriptedPrintParamsPtr params,
ScriptedPrintCallback callback) override;
@ -500,7 +501,7 @@ index f137fc60162622a37c2e4896f521fa3da9dac68e..f7a15e6189736bd86474be3b86a080fd
// Adds and removes observers for `PrintViewManagerBase` events. The order in
// which notifications are sent to observers is undefined. Observers must be
@@ -140,6 +147,14 @@ class PrintViewManagerBase : public PrintManager, public PrintJob::Observer {
@@ -145,6 +152,14 @@ class PrintViewManagerBase : public PrintManager, public PrintJob::Observer {
void AddTestObserver(TestObserver& observer);
void RemoveTestObserver(TestObserver& observer);
@ -515,7 +516,7 @@ index f137fc60162622a37c2e4896f521fa3da9dac68e..f7a15e6189736bd86474be3b86a080fd
protected:
explicit PrintViewManagerBase(content::WebContents* web_contents);
@@ -263,6 +278,7 @@ class PrintViewManagerBase : public PrintManager, public PrintJob::Observer {
@@ -268,6 +283,7 @@ class PrintViewManagerBase : public PrintManager, public PrintJob::Observer {
bool success);
#endif
void CompleteUpdatePrintSettings(
@ -523,7 +524,7 @@ index f137fc60162622a37c2e4896f521fa3da9dac68e..f7a15e6189736bd86474be3b86a080fd
base::Value::Dict job_settings,
std::unique_ptr<PrintSettings> print_settings,
UpdatePrintSettingsCallback callback);
@@ -357,8 +373,11 @@ class PrintViewManagerBase : public PrintManager, public PrintJob::Observer {
@@ -362,8 +378,11 @@ class PrintViewManagerBase : public PrintManager, public PrintJob::Observer {
// The current RFH that is printing with a system printing dialog.
raw_ptr<content::RenderFrameHost> printing_rfh_ = nullptr;
@ -537,7 +538,7 @@ index f137fc60162622a37c2e4896f521fa3da9dac68e..f7a15e6189736bd86474be3b86a080fd
// Indication that the job is getting canceled.
bool canceling_job_ = false;
diff --git a/chrome/browser/printing/printer_query.cc b/chrome/browser/printing/printer_query.cc
index 75fb743f95c375420f07b0cd93b2a13bf83b33f6..e60f5f4ca226c7575082fe31e7209ccaa10616d4 100644
index 418f53b0db3a2b2624298fca5628aacdd2a99c94..4a110fda692e16ec887cb90c6a2fa611c67b8d6f 100644
--- a/chrome/browser/printing/printer_query.cc
+++ b/chrome/browser/printing/printer_query.cc
@@ -355,17 +355,19 @@ void PrinterQuery::UpdatePrintSettings(base::Value::Dict new_settings,
@ -829,10 +830,10 @@ index 3cf735c0bf3ba4ed4a871f4608f43cf9767de62f..fccabc0c51ba2fc1ccd8646d30da782f
// Calculate number of pages in source document.
uint32_t CalculateNumberOfPages(blink::WebLocalFrame* frame,
diff --git a/content/browser/BUILD.gn b/content/browser/BUILD.gn
index 62695d9439c28ef29a18999909ae9c5fc442181a..09f92c1b1ff60783580d02c320e7a7a5bf417f0c 100644
index 821e5db63fd5d69b3fcc329ec02f71a1a7907ada..143c98e3294fb07b08c1d8e97013034f8453e074 100644
--- a/content/browser/BUILD.gn
+++ b/content/browser/BUILD.gn
@@ -2963,8 +2963,9 @@ source_set("browser") {
@@ -2974,8 +2974,9 @@ source_set("browser") {
"//ppapi/shared_impl",
]
@ -845,10 +846,10 @@ index 62695d9439c28ef29a18999909ae9c5fc442181a..09f92c1b1ff60783580d02c320e7a7a5
if (is_chromeos) {
sources += [
diff --git a/printing/printing_context.cc b/printing/printing_context.cc
index 94f51e9f280a4282a3e9676c2895703e1bf55422..94555c2577d821ce2cbb521eee269138bbbf1a2b 100644
index 9866f21c5530ac389f3392350de1f6f413df147a..8656f221a96622cd7684e4c4c4a4c080a3963362 100644
--- a/printing/printing_context.cc
+++ b/printing/printing_context.cc
@@ -145,7 +145,6 @@ void PrintingContext::UsePdfSettings() {
@@ -154,7 +154,6 @@ void PrintingContext::UsePdfSettings() {
mojom::ResultCode PrintingContext::UpdatePrintSettings(
base::Value::Dict job_settings) {
@ -857,10 +858,10 @@ index 94f51e9f280a4282a3e9676c2895703e1bf55422..94555c2577d821ce2cbb521eee269138
std::unique_ptr<PrintSettings> settings =
PrintSettingsFromJobSettings(job_settings);
diff --git a/printing/printing_context.h b/printing/printing_context.h
index 6db58a9992642e557bac669b10f109bf6fd0f6ad..e1a5fcdca50d612dcb56faaf846752a44a697b84 100644
index 63f170c95050416c595e62f4c460c4cd6b7dbd1c..157e3d046889f9c63fdf0fd5d503890fb82c038d 100644
--- a/printing/printing_context.h
+++ b/printing/printing_context.h
@@ -202,6 +202,9 @@ class COMPONENT_EXPORT(PRINTING) PrintingContext {
@@ -206,6 +206,9 @@ class COMPONENT_EXPORT(PRINTING) PrintingContext {
bool PrintingAborted() const { return abort_printing_; }
@ -869,8 +870,8 @@ index 6db58a9992642e557bac669b10f109bf6fd0f6ad..e1a5fcdca50d612dcb56faaf846752a4
+
int job_id() const { return job_id_; }
protected:
@@ -213,9 +216,6 @@ class COMPONENT_EXPORT(PRINTING) PrintingContext {
#if BUILDFLAG(ENABLE_OOP_PRINTING)
@@ -224,9 +227,6 @@ class COMPONENT_EXPORT(PRINTING) PrintingContext {
Delegate* delegate,
ProcessBehavior process_behavior);

Просмотреть файл

@ -51,7 +51,7 @@ index b05c0157ecca222452fb38e3b28c9d7cc6bcfbfd..02d9eabfef9521722340739bf86df3df
base::win::MessageWindow window_; // The message-only window.
bool is_virtualized_; // Stuck inside Microsoft Softricity VM environment.
diff --git a/chrome/browser/process_singleton_posix.cc b/chrome/browser/process_singleton_posix.cc
index f4692fd100b157d571cff4bcd2ca30f33d132af3..09108f231a54b117a143e71efa3f3663d64a63e6 100644
index f2913f2d78edb2547ae21816b34936d38f1870a9..298c9c81fa110ad7900d0bd6822136bb57f0382e 100644
--- a/chrome/browser/process_singleton_posix.cc
+++ b/chrome/browser/process_singleton_posix.cc
@@ -54,6 +54,7 @@
@ -70,29 +70,25 @@ index f4692fd100b157d571cff4bcd2ca30f33d132af3..09108f231a54b117a143e71efa3f3663
#include "base/threading/platform_thread.h"
#include "base/time/time.h"
#include "base/timer/timer.h"
@@ -97,9 +99,11 @@
@@ -97,7 +99,7 @@
#include "ui/base/l10n/l10n_util.h"
#include "ui/base/resource/scoped_startup_resource_bundle.h"
-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)
+#if 0
#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)
#include "chrome/browser/ui/process_singleton_dialog_linux.h"
#endif
+#endif
using content::BrowserThread;
@@ -343,6 +347,9 @@ bool SymlinkPath(const base::FilePath& target, const base::FilePath& path) {
@@ -343,6 +345,8 @@ bool SymlinkPath(const base::FilePath& target, const base::FilePath& path) {
bool DisplayProfileInUseError(const base::FilePath& lock_path,
const std::string& hostname,
int pid) {
+ return true;
+
+#if 0
// Ensure there is an instance of ResourceBundle that is initialized for
// localized string resource accesses.
ui::ScopedStartupResourceBundle ensure_startup_resource_bundle;
@@ -366,6 +373,7 @@ bool DisplayProfileInUseError(const base::FilePath& lock_path,
@@ -366,6 +370,7 @@ bool DisplayProfileInUseError(const base::FilePath& lock_path,
NOTREACHED();
return false;
@ -100,8 +96,8 @@ index f4692fd100b157d571cff4bcd2ca30f33d132af3..09108f231a54b117a143e71efa3f3663
}
bool IsChromeProcess(pid_t pid) {
@@ -406,6 +414,21 @@ bool CheckCookie(const base::FilePath& path, const base::FilePath& cookie) {
return (cookie == ReadLink(path));
@@ -378,6 +383,21 @@ bool IsChromeProcess(pid_t pid) {
base::FilePath(chrome::kBrowserProcessExecutableName));
}
+bool IsAppSandboxed() {
@ -119,13 +115,13 @@ index f4692fd100b157d571cff4bcd2ca30f33d132af3..09108f231a54b117a143e71efa3f3663
+#endif // BUILDFLAG(IS_MAC)
+}
+
bool ConnectSocket(ScopedSocket* socket,
const base::FilePath& socket_path,
const base::FilePath& cookie_path) {
@@ -773,6 +796,10 @@ ProcessSingleton::ProcessSingleton(
ProcessSingleton::~ProcessSingleton() {
DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_);
// A helper class to hold onto a socket.
class ScopedSocket {
public:
@@ -781,6 +801,10 @@ ProcessSingleton::~ProcessSingleton() {
if (watcher_) {
watcher_->OnEminentProcessSingletonDestruction();
}
+ // Manually free resources with IO explicitly allowed.
+ base::ScopedAllowBlocking allow_blocking;
+ watcher_ = nullptr;
@ -133,13 +129,10 @@ index f4692fd100b157d571cff4bcd2ca30f33d132af3..09108f231a54b117a143e71efa3f3663
}
ProcessSingleton::NotifyResult ProcessSingleton::NotifyOtherProcess() {
@@ -1036,14 +1063,32 @@ bool ProcessSingleton::Create() {
#endif
}
- // Create the socket file somewhere in /tmp which is usually mounted as a
- // normal filesystem. Some network filesystems (notably AFS) are screwy and
- // do not support Unix domain sockets.
@@ -1047,11 +1071,32 @@ bool ProcessSingleton::Create() {
// Create the socket file somewhere in /tmp which is usually mounted as a
// normal filesystem. Some network filesystems (notably AFS) are screwy and
// do not support Unix domain sockets.
- if (!socket_dir_.CreateUniqueTempDir()) {
- LOG(ERROR) << "Failed to create socket directory.";
+ base::FilePath tmp_dir;

Просмотреть файл

@ -8,7 +8,7 @@ Chrome moved the SetCursor IPC message to mojo, which we use to tell OSR about `
Refs: https://chromium-review.googlesource.com/c/chromium/src/+/2172779
diff --git a/content/browser/renderer_host/render_widget_host_delegate.h b/content/browser/renderer_host/render_widget_host_delegate.h
index c4255d8dfc2e3c4f1f32506e4e9edbb90a74340a..142398a8adafc94e6724ee750b612a66d23d724b 100644
index acf92799b643246222306a37aa4fc611ef65149a..4eabd290955e5df65951a0ec2378588598dd5830 100644
--- a/content/browser/renderer_host/render_widget_host_delegate.h
+++ b/content/browser/renderer_host/render_widget_host_delegate.h
@@ -23,6 +23,7 @@
@ -30,7 +30,7 @@ index c4255d8dfc2e3c4f1f32506e4e9edbb90a74340a..142398a8adafc94e6724ee750b612a66
// RenderWidgetHost on the primary main frame, and false otherwise.
virtual bool IsWidgetForPrimaryMainFrame(RenderWidgetHostImpl*);
diff --git a/content/browser/renderer_host/render_widget_host_impl.cc b/content/browser/renderer_host/render_widget_host_impl.cc
index f15ba3475d6733bf33f1d3d243773928c29dd776..6e1cf587c7cd1b406b8f6488f4a7f309476f11a8 100644
index 033634314d706196b5a68fc44114971d31bda3cb..1d3f8f9484f64be58f59e240b1dae1fb507acd59 100644
--- a/content/browser/renderer_host/render_widget_host_impl.cc
+++ b/content/browser/renderer_host/render_widget_host_impl.cc
@@ -2141,6 +2141,9 @@ void RenderWidgetHostImpl::SetCursor(const ui::Cursor& cursor) {
@ -44,10 +44,10 @@ index f15ba3475d6733bf33f1d3d243773928c29dd776..6e1cf587c7cd1b406b8f6488f4a7f309
void RenderWidgetHostImpl::ShowContextMenuAtPoint(
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
index 38b5a462873a48d37ea11b1a3d41da46ef63284a..038cef59809065f0a775e1a0282bfeb9f31a4551 100644
index e9ce07551ccd183cb205aedba787b3a9700e2a2b..245e7c6e3228001d17e62b8ace3647023cac9a73 100644
--- a/content/browser/web_contents/web_contents_impl.cc
+++ b/content/browser/web_contents/web_contents_impl.cc
@@ -5109,6 +5109,11 @@ TextInputManager* WebContentsImpl::GetTextInputManager() {
@@ -5162,6 +5162,11 @@ TextInputManager* WebContentsImpl::GetTextInputManager() {
return text_input_manager_.get();
}
@ -60,10 +60,10 @@ index 38b5a462873a48d37ea11b1a3d41da46ef63284a..038cef59809065f0a775e1a0282bfeb9
RenderWidgetHostImpl* render_widget_host) {
return render_widget_host == GetPrimaryMainFrame()->GetRenderWidgetHost();
diff --git a/content/browser/web_contents/web_contents_impl.h b/content/browser/web_contents/web_contents_impl.h
index 3ba96d4aede6844ac358074e145ae89373bb06d2..dcce544ee23fe7fe9ce0c6b1c89840aedb514f5f 100644
index 30aedd4fb82fe48f768522fc1b9eae09a8e617ac..b4c0dcffe022db9c21ecf4796bd037c652966cd8 100644
--- a/content/browser/web_contents/web_contents_impl.h
+++ b/content/browser/web_contents/web_contents_impl.h
@@ -1011,6 +1011,7 @@ class CONTENT_EXPORT WebContentsImpl : public WebContents,
@@ -1022,6 +1022,7 @@ class CONTENT_EXPORT WebContentsImpl : public WebContents,
void SendScreenRects() override;
void SendActiveState(bool active) override;
TextInputManager* GetTextInputManager() override;
@ -72,10 +72,10 @@ index 3ba96d4aede6844ac358074e145ae89373bb06d2..dcce544ee23fe7fe9ce0c6b1c89840ae
RenderWidgetHostImpl* render_widget_host) override;
bool IsShowingContextMenuOnPage() const override;
diff --git a/content/public/browser/web_contents_observer.h b/content/public/browser/web_contents_observer.h
index a3b5e3b1ad2dfc01ac500ac5cd02b33c3b866437..b8ca4c6aabe1a872fdcf7cf2ede2193ab1793f39 100644
index 839fa5e82f140bc582606738285e3b9a78769d6f..181004251d2dd0432b92f917efe1a117973a2da4 100644
--- a/content/public/browser/web_contents_observer.h
+++ b/content/public/browser/web_contents_observer.h
@@ -32,6 +32,7 @@
@@ -33,6 +33,7 @@
#include "third_party/blink/public/mojom/loader/resource_load_info.mojom-forward.h"
#include "third_party/blink/public/mojom/media/capture_handle_config.mojom-forward.h"
#include "third_party/skia/include/core/SkColor.h"
@ -83,7 +83,7 @@ index a3b5e3b1ad2dfc01ac500ac5cd02b33c3b866437..b8ca4c6aabe1a872fdcf7cf2ede2193a
#include "ui/base/page_transition_types.h"
#include "ui/base/window_open_disposition.h"
@@ -568,6 +569,9 @@ class CONTENT_EXPORT WebContentsObserver : public base::CheckedObserver {
@@ -570,6 +571,9 @@ class CONTENT_EXPORT WebContentsObserver : public base::CheckedObserver {
// Invoked when the primary main frame changes size.
virtual void PrimaryMainFrameWasResized(bool width_changed) {}

Просмотреть файл

@ -7,10 +7,10 @@ Subject: refactor: expose HostImportModuleDynamically and
This is so that Electron can blend Blink's and Node's implementations of these isolate handlers.
diff --git a/third_party/blink/renderer/bindings/core/v8/v8_initializer.cc b/third_party/blink/renderer/bindings/core/v8/v8_initializer.cc
index 99df9217e06a302f1280162293241d5d8b67b9b2..9597f5bb6cdbc26d07752ba196307c4abe65c9cb 100644
index 35b2d7b2462de78087f70dac1a908cef71785216..7d20ca8d3a4d6eb3a7a0d9e2e6b3c1aff64cea03 100644
--- a/third_party/blink/renderer/bindings/core/v8/v8_initializer.cc
+++ b/third_party/blink/renderer/bindings/core/v8/v8_initializer.cc
@@ -624,7 +624,9 @@ bool JavaScriptCompileHintsMagicEnabledCallback(
@@ -616,7 +616,9 @@ bool JavaScriptCompileHintsMagicEnabledCallback(
execution_context);
}
@ -21,7 +21,7 @@ index 99df9217e06a302f1280162293241d5d8b67b9b2..9597f5bb6cdbc26d07752ba196307c4a
v8::Local<v8::Context> context,
v8::Local<v8::Data> v8_host_defined_options,
v8::Local<v8::Value> v8_referrer_resource_url,
@@ -702,7 +704,7 @@ v8::MaybeLocal<v8::Promise> HostImportModuleDynamically(
@@ -694,7 +696,7 @@ v8::MaybeLocal<v8::Promise> HostImportModuleDynamically(
}
// https://html.spec.whatwg.org/C/#hostgetimportmetaproperties
@ -30,7 +30,7 @@ index 99df9217e06a302f1280162293241d5d8b67b9b2..9597f5bb6cdbc26d07752ba196307c4a
v8::Local<v8::Module> module,
v8::Local<v8::Object> meta) {
ScriptState* script_state = ScriptState::From(context);
@@ -745,9 +747,6 @@ std::ostream& operator<<(std::ostream& os, const PrintV8OOM& oom_details) {
@@ -737,9 +739,6 @@ std::ostream& operator<<(std::ostream& os, const PrintV8OOM& oom_details) {
return os;
}
@ -40,7 +40,7 @@ index 99df9217e06a302f1280162293241d5d8b67b9b2..9597f5bb6cdbc26d07752ba196307c4a
void V8Initializer::InitializeV8Common(v8::Isolate* isolate) {
// Set up garbage collection before setting up anything else as V8 may trigger
// GCs during Blink setup.
@@ -769,9 +768,9 @@ void V8Initializer::InitializeV8Common(v8::Isolate* isolate) {
@@ -760,9 +759,9 @@ void V8Initializer::InitializeV8Common(v8::Isolate* isolate) {
SharedArrayBufferConstructorEnabledCallback);
isolate->SetJavaScriptCompileHintsMagicEnabledCallback(
JavaScriptCompileHintsMagicEnabledCallback);

Просмотреть файл

@ -12,7 +12,7 @@ should be removed as soon as those have been updated. Patching because
every instance is a FTBFS that prevents testing any one instance's fix.
diff --git a/base/functional/callback_helpers.h b/base/functional/callback_helpers.h
index 3f532c9dfdbda4fcc7514f92b6d4b07e570a963a..34235aab0bc0ee7369170e6714fe7ede9ff739c5 100644
index f7af4f832fc342f8a9a052049dc1bd5cfefb16ee..e3f6495d4c43abd5d16ec14d8ec732fa3f6bc599 100644
--- a/base/functional/callback_helpers.h
+++ b/base/functional/callback_helpers.h
@@ -100,6 +100,22 @@ RepeatingCallback<void(Args...)> ForwardRepeatingCallbacks(

Просмотреть файл

@ -6,10 +6,10 @@ Subject: render_widget_host_view_base.patch
... something to do with OSR? and maybe <webview> as well? terrifying.
diff --git a/content/browser/renderer_host/render_widget_host_view_base.cc b/content/browser/renderer_host/render_widget_host_view_base.cc
index cfacbb911e5fd2cce13598cf4c2697e9d0c73038..114203c9fc5ff1ab82c80f478049ee47dd661bcf 100644
index 6b51fa563b1b796e60197fd3d4223c844d5fbef2..47783dcd82d1a256f14d69fde66063dea9cde564 100644
--- a/content/browser/renderer_host/render_widget_host_view_base.cc
+++ b/content/browser/renderer_host/render_widget_host_view_base.cc
@@ -695,6 +695,13 @@ bool RenderWidgetHostViewBase::ScreenRectIsUnstableForIOv2For(
@@ -700,6 +700,13 @@ bool RenderWidgetHostViewBase::ScreenRectIsUnstableForIOv2For(
return false;
}
@ -24,10 +24,10 @@ index cfacbb911e5fd2cce13598cf4c2697e9d0c73038..114203c9fc5ff1ab82c80f478049ee47
const blink::WebMouseEvent& event,
const ui::LatencyInfo& latency) {
diff --git a/content/browser/renderer_host/render_widget_host_view_base.h b/content/browser/renderer_host/render_widget_host_view_base.h
index 43531968500880d97911a7a777bd79a1f335681e..75fd40c7a484b923ff08a49367b407344d2cbae4 100644
index cc3738cade39af393c651cbfb8a6cce87d7f770d..482e8abc5fa65b1f04f7549f087b7bc4450152af 100644
--- a/content/browser/renderer_host/render_widget_host_view_base.h
+++ b/content/browser/renderer_host/render_widget_host_view_base.h
@@ -24,10 +24,13 @@
@@ -25,10 +25,13 @@
#include "components/viz/common/surfaces/surface_id.h"
#include "components/viz/host/hit_test/hit_test_query.h"
#include "content/browser/renderer_host/display_feature.h"
@ -72,7 +72,7 @@ index 43531968500880d97911a7a777bd79a1f335681e..75fd40c7a484b923ff08a49367b40734
// This only needs to be overridden by RenderWidgetHostViewBase subclasses
// that handle content embedded within other RenderWidgetHostViews.
gfx::PointF TransformPointToRootCoordSpaceF(
@@ -332,6 +340,11 @@ class CONTENT_EXPORT RenderWidgetHostViewBase : public RenderWidgetHostView,
@@ -335,6 +343,11 @@ class CONTENT_EXPORT RenderWidgetHostViewBase : public RenderWidgetHostView,
virtual void ProcessGestureEvent(const blink::WebGestureEvent& event,
const ui::LatencyInfo& latency);

Просмотреть файл

@ -8,7 +8,7 @@ respond to the first mouse click in their window, which is desirable for some
kinds of utility windows. Similarly for `disableAutoHideCursor`.
diff --git a/content/app_shim_remote_cocoa/render_widget_host_view_cocoa.mm b/content/app_shim_remote_cocoa/render_widget_host_view_cocoa.mm
index 1b4d385ae5cc8355f019710f0c67716d95864535..8c32ab0c35f68ae57f93002455a979f9381e3ac6 100644
index 6e85ff006ca89766192812351b93eed77936be80..76959be428bd4ea2efe5e73c78b0aed77246fd96 100644
--- a/content/app_shim_remote_cocoa/render_widget_host_view_cocoa.mm
+++ b/content/app_shim_remote_cocoa/render_widget_host_view_cocoa.mm
@@ -159,6 +159,15 @@ void ExtractUnderlines(NSAttributedString* string,

Просмотреть файл

@ -52,10 +52,10 @@ Some alternatives to this patch:
None of these options seems like a substantial maintainability win over this patch to me (@nornagon).
diff --git a/chrome/BUILD.gn b/chrome/BUILD.gn
index 91c29a96d2d97dfe916e29c14a3daa154b02f97c..3611378c052813bd9c9ab9ce7d1840d6535576bf 100644
index ef32e9c1315f963a59e15a02fa6f9d8cda5588b4..d09e7aeb788550e7ecefb4b9c177dd26ecc5ad4c 100644
--- a/chrome/BUILD.gn
+++ b/chrome/BUILD.gn
@@ -1602,7 +1602,7 @@ if (is_chrome_branded && !is_android) {
@@ -1575,7 +1575,7 @@ if (is_chrome_branded && !is_android) {
}
}
@ -64,7 +64,7 @@ index 91c29a96d2d97dfe916e29c14a3daa154b02f97c..3611378c052813bd9c9ab9ce7d1840d6
chrome_paks("packed_resources") {
if (is_mac) {
output_dir = "$root_gen_dir/repack"
@@ -1641,6 +1641,12 @@ if (!is_android) {
@@ -1614,6 +1614,12 @@ if (!is_android) {
}
}

Просмотреть файл

@ -6,10 +6,10 @@ Subject: Revert "Remove the AllowAggressiveThrottlingWithWebSocket feature."
This reverts commit 615c1810a187840ffeb04096087efff86edb37de.
diff --git a/third_party/blink/renderer/modules/websockets/websocket_channel_impl.cc b/third_party/blink/renderer/modules/websockets/websocket_channel_impl.cc
index 086679f616c3211324e0bae05c71e2d1bc459cf3..4103594b79d7482568b4c3a366b3290ee0523c0d 100644
index 2fadf23a48a5c13ec341fd1b10a00663c6604eeb..3764e58e2acd0f13c194008f7b230a9a2f4b3891 100644
--- a/third_party/blink/renderer/modules/websockets/websocket_channel_impl.cc
+++ b/third_party/blink/renderer/modules/websockets/websocket_channel_impl.cc
@@ -95,6 +95,17 @@ enum WebSocketOpCode {
@@ -96,6 +96,17 @@ enum WebSocketOpCode {
kOpCodeBinary = 0x2,
};
@ -27,7 +27,7 @@ index 086679f616c3211324e0bae05c71e2d1bc459cf3..4103594b79d7482568b4c3a366b3290e
} // namespace
void WebSocketChannelImpl::MessageDataDeleter::operator()(char* p) const {
@@ -285,7 +296,10 @@ bool WebSocketChannelImpl::Connect(const KURL& url, const String& protocol) {
@@ -286,7 +297,10 @@ bool WebSocketChannelImpl::Connect(const KURL& url, const String& protocol) {
// even if the `WebSocketChannel` is closed.
feature_handle_for_scheduler_ = scheduler->RegisterFeature(
SchedulingPolicy::Feature::kWebSocket,

Просмотреть файл

@ -6,7 +6,7 @@ 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 7c72b996ace8b4d5bef9788158061168ed20d201..64547996ba65e1f4385e3cfd322b170f1dc379bc 100644
index b67ee7e79eea7fe5f8873b8b4cca3c264c731482..4ec2dea38d5ed56577032cd4cc3e5d04934f1a0e 100644
--- a/content/renderer/render_thread_impl.cc
+++ b/content/renderer/render_thread_impl.cc
@@ -1224,7 +1224,7 @@ bool RenderThreadImpl::IsLcdTextEnabled() {

Просмотреть файл

@ -15,7 +15,7 @@ short-circuit all the permissions checks in MSDC for now to allow us to
unduplicate this code.
diff --git a/components/webrtc/media_stream_devices_controller.cc b/components/webrtc/media_stream_devices_controller.cc
index be66cc8226fa719645701d5cf708ae91c2bf823d..6cf82318db3cc74b2387cb76583284df5ddaed4a 100644
index e7aa270fce64dbf884393b08063890eb56f186a7..397a37518a094d2a538cefe9c3ff2ee85f7ef3ef 100644
--- a/components/webrtc/media_stream_devices_controller.cc
+++ b/components/webrtc/media_stream_devices_controller.cc
@@ -57,7 +57,8 @@ bool PermissionIsRequested(blink::PermissionType permission,
@ -28,20 +28,21 @@ index be66cc8226fa719645701d5cf708ae91c2bf823d..6cf82318db3cc74b2387cb76583284df
content::RenderFrameHost* rfh = content::RenderFrameHost::FromID(
request.render_process_id, request.render_frame_id);
// The RFH may have been destroyed by the time the request is processed.
@@ -93,6 +94,7 @@ void MediaStreamDevicesController::RequestPermissions(
@@ -92,7 +93,7 @@ void MediaStreamDevicesController::RequestPermissions(
std::move(callback)));
std::vector<blink::PermissionType> permission_types;
-
+#if 0
content::PermissionController* permission_controller =
web_contents->GetBrowserContext()->GetPermissionController();
@@ -153,21 +155,27 @@ void MediaStreamDevicesController::RequestPermissions(
permission_types.push_back(blink::PermissionType::CAMERA_PAN_TILT_ZOOM);
}
}
@@ -165,19 +166,26 @@ void MediaStreamDevicesController::RequestPermissions(
requested_audio_capture_device_ids;
permission_request_description.requested_video_capture_device_ids =
requested_video_capture_device_ids;
-
+#endif
// It is OK to ignore `request.security_origin` because it will be calculated
// from `render_frame_host` and we always ignore `requesting_origin` for
// `AUDIO_CAPTURE` and `VIDEO_CAPTURE`.
@ -50,9 +51,7 @@ index be66cc8226fa719645701d5cf708ae91c2bf823d..6cf82318db3cc74b2387cb76583284df
- rfh->GetBrowserContext()
- ->GetPermissionController()
- ->RequestPermissionsFromCurrentDocument(
- rfh,
- content::PermissionRequestDescription(permission_types,
- request.user_gesture),
- rfh, permission_request_description,
- base::BindOnce(
- &MediaStreamDevicesController::PromptAnsweredGroupedRequest,
- std::move(controller)));
@ -73,7 +72,7 @@ index be66cc8226fa719645701d5cf708ae91c2bf823d..6cf82318db3cc74b2387cb76583284df
}
MediaStreamDevicesController::~MediaStreamDevicesController() {
@@ -437,6 +445,7 @@ bool MediaStreamDevicesController::PermissionIsBlockedForReason(
@@ -447,6 +455,7 @@ bool MediaStreamDevicesController::PermissionIsBlockedForReason(
return false;
}
@ -81,7 +80,7 @@ index be66cc8226fa719645701d5cf708ae91c2bf823d..6cf82318db3cc74b2387cb76583284df
// TODO(raymes): This function wouldn't be needed if
// PermissionManager::RequestPermissions returned a denial reason.
content::PermissionResult result =
@@ -447,6 +456,7 @@ bool MediaStreamDevicesController::PermissionIsBlockedForReason(
@@ -457,6 +466,7 @@ bool MediaStreamDevicesController::PermissionIsBlockedForReason(
DCHECK_EQ(blink::mojom::PermissionStatus::DENIED, result.status);
return true;
}

Просмотреть файл

@ -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 23c2f323ce9172d6e8a42d0cc031da5a0540ce35..73cad457ad37cfdb5459c11e7828a543dc0cf31d 100644
index 5f6267cce7c59eab684dda3f8bfc7982b6407841..4551601cf77d57e74c725d4352b128c0ac8b09b7 100644
--- a/content/browser/renderer_host/render_process_host_impl.cc
+++ b/content/browser/renderer_host/render_process_host_impl.cc
@@ -1723,9 +1723,15 @@ bool RenderProcessHostImpl::Init() {
@@ -1727,9 +1727,15 @@ bool RenderProcessHostImpl::Init() {
std::unique_ptr<SandboxedProcessLauncherDelegate> sandbox_delegate =
std::make_unique<RendererSandboxedProcessLauncherDelegateWin>(
*cmd_line, IsPdf(), IsJitDisabled());

Просмотреть файл

@ -9,10 +9,10 @@ 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 8baab27c7bc1bd7e0bbc6342388327a33304f713..9f31e9e72019b437cb7ec1865003f0416bea24cd 100644
index af25cd45d6f087bc6fd06916bd5c7ba4ef69ddef..57d475186f6cda633e4542646abf74f19243e6ad 100644
--- a/content/browser/web_contents/web_contents_impl.cc
+++ b/content/browser/web_contents/web_contents_impl.cc
@@ -3452,6 +3452,13 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params,
@@ -3471,6 +3471,13 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params,
params.main_frame_name, GetOpener(), primary_main_frame_policy,
base::UnguessableToken::Create());
@ -26,7 +26,7 @@ index 8baab27c7bc1bd7e0bbc6342388327a33304f713..9f31e9e72019b437cb7ec1865003f041
std::unique_ptr<WebContentsViewDelegate> delegate =
GetContentClient()->browser()->GetWebContentsViewDelegate(this);
@@ -3462,6 +3469,7 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params,
@@ -3481,6 +3488,7 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params,
view_ = CreateWebContentsView(this, std::move(delegate),
&render_view_host_delegate_view_);
}
@ -35,10 +35,10 @@ index 8baab27c7bc1bd7e0bbc6342388327a33304f713..9f31e9e72019b437cb7ec1865003f041
CHECK(view_.get());
diff --git a/content/public/browser/web_contents.h b/content/public/browser/web_contents.h
index 0daa926807fed575455a143105618cc169a905d7..33764ec81294b07a3da4fa4fb0a1cd2f9bc56f54 100644
index 943d2c2a16821e0bf127a1766c5dd1648973cd8e..3f3d2655952296463ec2024db810765dae41fe75 100644
--- a/content/public/browser/web_contents.h
+++ b/content/public/browser/web_contents.h
@@ -100,10 +100,13 @@ class BrowserContext;
@@ -101,10 +101,13 @@ class BrowserContext;
class BrowserPluginGuestDelegate;
class RenderFrameHost;
class RenderViewHost;
@ -52,7 +52,7 @@ index 0daa926807fed575455a143105618cc169a905d7..33764ec81294b07a3da4fa4fb0a1cd2f
class WebUI;
struct DropData;
struct MHTMLGenerationParams;
@@ -250,6 +253,10 @@ class WebContents : public PageNavigator,
@@ -251,6 +254,10 @@ class WebContents : public PageNavigator,
network::mojom::WebSandboxFlags starting_sandbox_flags =
network::mojom::WebSandboxFlags::kNone;

Просмотреть файл

@ -15,10 +15,10 @@ Note that we also need to manually update embedder's
`api::WebContents::IsFullscreenForTabOrPending` value.
diff --git a/content/browser/renderer_host/render_frame_host_impl.cc b/content/browser/renderer_host/render_frame_host_impl.cc
index 6f5076ea646d356946c4789143fdbec538150051..1e1ca5cd60436cb8901516ca32691e23edce6360 100644
index 0a095cfd413f8cb7f30f8b143b29e5e829898ad0..bafeeb41441d7a585bef170f81d69fe54417da63 100644
--- a/content/browser/renderer_host/render_frame_host_impl.cc
+++ b/content/browser/renderer_host/render_frame_host_impl.cc
@@ -7417,6 +7417,17 @@ void RenderFrameHostImpl::EnterFullscreen(
@@ -7464,6 +7464,17 @@ void RenderFrameHostImpl::EnterFullscreen(
}
}
@ -37,10 +37,10 @@ index 6f5076ea646d356946c4789143fdbec538150051..1e1ca5cd60436cb8901516ca32691e23
if (had_fullscreen_token && !GetView()->HasFocus())
GetView()->Focus();
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
index 9f31e9e72019b437cb7ec1865003f0416bea24cd..a2e8526344318df726ea3af130aab3f72a3125e1 100644
index 57d475186f6cda633e4542646abf74f19243e6ad..07ac28fe51c8f54d814c4c0718cf6f4705d0dbda 100644
--- a/content/browser/web_contents/web_contents_impl.cc
+++ b/content/browser/web_contents/web_contents_impl.cc
@@ -3706,21 +3706,25 @@ KeyboardEventProcessingResult WebContentsImpl::PreHandleKeyboardEvent(
@@ -3725,21 +3725,25 @@ KeyboardEventProcessingResult WebContentsImpl::PreHandleKeyboardEvent(
const NativeWebKeyboardEvent& event) {
OPTIONAL_TRACE_EVENT0(TRACE_DISABLED_BY_DEFAULT("content.verbose"),
"WebContentsImpl::PreHandleKeyboardEvent");
@ -78,7 +78,7 @@ index 9f31e9e72019b437cb7ec1865003f0416bea24cd..a2e8526344318df726ea3af130aab3f7
}
bool WebContentsImpl::HandleMouseEvent(const blink::WebMouseEvent& event) {
@@ -3856,7 +3860,7 @@ void WebContentsImpl::EnterFullscreenMode(
@@ -3875,7 +3879,7 @@ void WebContentsImpl::EnterFullscreenMode(
OPTIONAL_TRACE_EVENT0("content", "WebContentsImpl::EnterFullscreenMode");
DCHECK(CanEnterFullscreenMode(requesting_frame, options));
DCHECK(requesting_frame->IsActive());
@ -88,7 +88,7 @@ index 9f31e9e72019b437cb7ec1865003f0416bea24cd..a2e8526344318df726ea3af130aab3f7
// When WebView is the `delegate_` we can end up with VisualProperties changes
// synchronously. Notify the view ahead so it can handle the transition.
diff --git a/third_party/blink/renderer/core/fullscreen/fullscreen.cc b/third_party/blink/renderer/core/fullscreen/fullscreen.cc
index ab0d67d69c96eefb0887edb4e69e2d5451595989..e2b61e9c2014c77e9a609aec6adbb988cc7fbbeb 100644
index eb1ca15be1502b49b5b864935acbafbd6c75d8aa..1e9c96808cdcbf1131a07f33f36b5666bb9ae1e8 100644
--- a/third_party/blink/renderer/core/fullscreen/fullscreen.cc
+++ b/third_party/blink/renderer/core/fullscreen/fullscreen.cc
@@ -111,7 +111,7 @@ void FullscreenElementChanged(Document& document,

Просмотреть файл

@ -10,10 +10,10 @@ An attempt to upstream this was made, but rejected:
https://chromium-review.googlesource.com/c/chromium/src/+/1954347
diff --git a/content/public/renderer/content_renderer_client.h b/content/public/renderer/content_renderer_client.h
index 72f72e2c6627d1f7159796f9151e697b04af66b1..4dfabec61229f50faba64d5c14255e5a726bf8f2 100644
index ff20508d76a6007674c4336eb55b6d5df5af4d0b..c1f4863fd3da8c028652742999ab72c077c362ab 100644
--- a/content/public/renderer/content_renderer_client.h
+++ b/content/public/renderer/content_renderer_client.h
@@ -381,6 +381,11 @@ class CONTENT_EXPORT ContentRendererClient {
@@ -382,6 +382,11 @@ class CONTENT_EXPORT ContentRendererClient {
virtual void DidInitializeWorkerContextOnWorkerThread(
v8::Local<v8::Context> context) {}
@ -26,10 +26,10 @@ index 72f72e2c6627d1f7159796f9151e697b04af66b1..4dfabec61229f50faba64d5c14255e5a
// 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 05576278ae00e27ab406551a02dc863e09f48ca3..635fbecee26f2a75b319193f680e29da0f10f6ec 100644
index 619323f485c6a976b9cd4c0ab6ada13ee7b78251..1567ebffe0a956fcbaf5ef2084c3ace6c6fa69ec 100644
--- a/content/renderer/renderer_blink_platform_impl.cc
+++ b/content/renderer/renderer_blink_platform_impl.cc
@@ -838,6 +838,12 @@ void RendererBlinkPlatformImpl::WillStopWorkerThread() {
@@ -839,6 +839,12 @@ void RendererBlinkPlatformImpl::WillStopWorkerThread() {
WorkerThreadRegistry::Instance()->WillStopCurrentWorkerThread();
}
@ -43,10 +43,10 @@ index 05576278ae00e27ab406551a02dc863e09f48ca3..635fbecee26f2a75b319193f680e29da
const v8::Local<v8::Context>& worker) {
GetContentClient()->renderer()->DidInitializeWorkerContextOnWorkerThread(
diff --git a/content/renderer/renderer_blink_platform_impl.h b/content/renderer/renderer_blink_platform_impl.h
index 9ff612df767dedab32338141a92b86adbb017526..0111d9e6c1004b0be7ac2fa88bedcb882adf9485 100644
index ecbcf12493f771f4498a39bb0b9b94d8457ac2f9..2345335fa06259a8caf35f628edfd39dd795907e 100644
--- a/content/renderer/renderer_blink_platform_impl.h
+++ b/content/renderer/renderer_blink_platform_impl.h
@@ -185,6 +185,7 @@ class CONTENT_EXPORT RendererBlinkPlatformImpl : public BlinkPlatformImpl {
@@ -186,6 +186,7 @@ class CONTENT_EXPORT RendererBlinkPlatformImpl : public BlinkPlatformImpl {
void DidStartWorkerThread() override;
void WillStopWorkerThread() override;
void WorkerContextCreated(const v8::Local<v8::Context>& worker) override;
@ -55,10 +55,10 @@ index 9ff612df767dedab32338141a92b86adbb017526..0111d9e6c1004b0be7ac2fa88bedcb88
const blink::WebSecurityOrigin& script_origin) override;
blink::ProtocolHandlerSecurityLevel GetProtocolHandlerSecurityLevel(
diff --git a/third_party/blink/public/platform/platform.h b/third_party/blink/public/platform/platform.h
index 7d91ca09f54e463b1ed2b2239800f9592045dfea..5f1d08715b1a46c0833dc817855125181abd1797 100644
index 52829e870d30a35dc3a7ead85f87db8f9d95dd1f..17c83183315654c41d6e53824e77905f9b4cd80f 100644
--- a/third_party/blink/public/platform/platform.h
+++ b/third_party/blink/public/platform/platform.h
@@ -634,6 +634,7 @@ class BLINK_PLATFORM_EXPORT Platform {
@@ -633,6 +633,7 @@ class BLINK_PLATFORM_EXPORT Platform {
virtual void DidStartWorkerThread() {}
virtual void WillStopWorkerThread() {}
virtual void WorkerContextCreated(const v8::Local<v8::Context>& worker) {}

Просмотреть файл

@ -19,10 +19,10 @@ that clearly establishes the worker script is ready for evaluation with the scop
initialized.
diff --git a/content/public/renderer/content_renderer_client.h b/content/public/renderer/content_renderer_client.h
index 4dfabec61229f50faba64d5c14255e5a726bf8f2..b91c37ed1dfccf2189cd17d61d2623c1042b086c 100644
index c1f4863fd3da8c028652742999ab72c077c362ab..c57ea8da0bbab375b23f996880f10a670a52a5f5 100644
--- a/content/public/renderer/content_renderer_client.h
+++ b/content/public/renderer/content_renderer_client.h
@@ -381,6 +381,11 @@ class CONTENT_EXPORT ContentRendererClient {
@@ -382,6 +382,11 @@ class CONTENT_EXPORT ContentRendererClient {
virtual void DidInitializeWorkerContextOnWorkerThread(
v8::Local<v8::Context> context) {}
@ -35,10 +35,10 @@ index 4dfabec61229f50faba64d5c14255e5a726bf8f2..b91c37ed1dfccf2189cd17d61d2623c1
// 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 635fbecee26f2a75b319193f680e29da0f10f6ec..b82a9ec9f2328559789ca5757c2cc7143cf9e927 100644
index 1567ebffe0a956fcbaf5ef2084c3ace6c6fa69ec..ad3de688660a6f6b02710cfd147e7ba42a965429 100644
--- a/content/renderer/renderer_blink_platform_impl.cc
+++ b/content/renderer/renderer_blink_platform_impl.cc
@@ -850,6 +850,12 @@ void RendererBlinkPlatformImpl::WorkerContextCreated(
@@ -851,6 +851,12 @@ void RendererBlinkPlatformImpl::WorkerContextCreated(
worker);
}
@ -52,10 +52,10 @@ index 635fbecee26f2a75b319193f680e29da0f10f6ec..b82a9ec9f2328559789ca5757c2cc714
const blink::WebSecurityOrigin& script_origin) {
return GetContentClient()->renderer()->AllowScriptExtensionForServiceWorker(
diff --git a/content/renderer/renderer_blink_platform_impl.h b/content/renderer/renderer_blink_platform_impl.h
index 0111d9e6c1004b0be7ac2fa88bedcb882adf9485..cd1e10f66847f071bcc5f02645f8c4ca0de7bd78 100644
index 2345335fa06259a8caf35f628edfd39dd795907e..e06885df70556d28c27a784a32e293e9a7a86252 100644
--- a/content/renderer/renderer_blink_platform_impl.h
+++ b/content/renderer/renderer_blink_platform_impl.h
@@ -185,6 +185,8 @@ class CONTENT_EXPORT RendererBlinkPlatformImpl : public BlinkPlatformImpl {
@@ -186,6 +186,8 @@ class CONTENT_EXPORT RendererBlinkPlatformImpl : public BlinkPlatformImpl {
void DidStartWorkerThread() override;
void WillStopWorkerThread() override;
void WorkerContextCreated(const v8::Local<v8::Context>& worker) override;
@ -65,10 +65,10 @@ index 0111d9e6c1004b0be7ac2fa88bedcb882adf9485..cd1e10f66847f071bcc5f02645f8c4ca
bool AllowScriptExtensionForServiceWorker(
const blink::WebSecurityOrigin& script_origin) override;
diff --git a/third_party/blink/public/platform/platform.h b/third_party/blink/public/platform/platform.h
index 5f1d08715b1a46c0833dc817855125181abd1797..47fcc7fb0811a634983c8d063ee1724c5ccb7b26 100644
index 17c83183315654c41d6e53824e77905f9b4cd80f..642f77a7c90e0ac6d6d087ef43cfb5020ce376db 100644
--- a/third_party/blink/public/platform/platform.h
+++ b/third_party/blink/public/platform/platform.h
@@ -634,6 +634,8 @@ class BLINK_PLATFORM_EXPORT Platform {
@@ -633,6 +633,8 @@ class BLINK_PLATFORM_EXPORT Platform {
virtual void DidStartWorkerThread() {}
virtual void WillStopWorkerThread() {}
virtual void WorkerContextCreated(const v8::Local<v8::Context>& worker) {}

Просмотреть файл

@ -10,10 +10,10 @@ to handle this without patching, but this is fairly clean for now and no longer
patching legacy devtools code.
diff --git a/front_end/entrypoints/main/MainImpl.ts b/front_end/entrypoints/main/MainImpl.ts
index 42707f3aed0dd3d6089178973c74afe17a0db273..2a359641e52579b062521a7ed4e21763bd6fd172 100644
index 4d51b17a1205562a799b5ac62f1f3a6a70db8455..ce4be3b83d4704e21c118a07e006c97ede8bf91e 100644
--- a/front_end/entrypoints/main/MainImpl.ts
+++ b/front_end/entrypoints/main/MainImpl.ts
@@ -726,6 +726,8 @@ export class MainImpl {
@@ -729,6 +729,8 @@ export class MainImpl {
globalThis.Main = globalThis.Main || {};
// @ts-ignore Exported for Tests.js
globalThis.Main.Main = MainImpl;

Просмотреть файл

@ -46,10 +46,10 @@ index 6cdf53b19c7d058bb66b9fcbe745874cc48daa99..8d112008c2667db97ed5b5af3f87c40d
V8_INLINE static void* GetAlignedPointerFromInternalField(
const BasicTracedReference<Object>& object, int index) {
diff --git a/src/api/api.cc b/src/api/api.cc
index 03b7167437fb11968a780dfbff99d61a91c6046f..db2f9a777231505c83ac80ffebb618c99e24ed2f 100644
index 8b709703b5fb51fed49832992f6c1dbeab933442..4e1c3bc844e18e7beb9c68823f7ff0be9a251871 100644
--- a/src/api/api.cc
+++ b/src/api/api.cc
@@ -6284,14 +6284,33 @@ Local<Data> v8::Object::SlowGetInternalField(int index) {
@@ -6283,14 +6283,33 @@ Local<Data> v8::Object::SlowGetInternalField(int index) {
isolate);
}

Просмотреть файл

@ -707,7 +707,7 @@ void ElectronBrowserClient::GetAdditionalWebUISchemes(
additional_schemes->push_back(content::kChromeDevToolsScheme);
}
void ElectronBrowserClient::SiteInstanceGotProcess(
void ElectronBrowserClient::SiteInstanceGotProcessAndSite(
content::SiteInstance* site_instance) {
#if BUILDFLAG(ENABLE_ELECTRON_EXTENSIONS)
auto* browser_context =
@ -1641,6 +1641,7 @@ std::unique_ptr<content::LoginDelegate>
ElectronBrowserClient::CreateLoginDelegate(
const net::AuthChallengeInfo& auth_info,
content::WebContents* web_contents,
content::BrowserContext* browser_context,
const content::GlobalRequestID& request_id,
bool is_main_frame,
const GURL& url,
@ -1658,7 +1659,8 @@ ElectronBrowserClient::CreateURLLoaderThrottles(
content::BrowserContext* browser_context,
const base::RepeatingCallback<content::WebContents*()>& wc_getter,
content::NavigationUIData* navigation_ui_data,
int frame_tree_node_id) {
int frame_tree_node_id,
absl::optional<int64_t> navigation_id) {
DCHECK_CURRENTLY_ON(BrowserThread::UI);
std::vector<std::unique_ptr<blink::URLLoaderThrottle>> result;

Просмотреть файл

@ -270,20 +270,23 @@ class ElectronBrowserClient : public content::ContentBrowserClient,
std::unique_ptr<content::LoginDelegate> CreateLoginDelegate(
const net::AuthChallengeInfo& auth_info,
content::WebContents* web_contents,
content::BrowserContext* browser_context,
const content::GlobalRequestID& request_id,
bool is_main_frame,
const GURL& url,
scoped_refptr<net::HttpResponseHeaders> response_headers,
bool first_auth_attempt,
LoginAuthRequiredCallback auth_required_callback) override;
void SiteInstanceGotProcess(content::SiteInstance* site_instance) override;
void SiteInstanceGotProcessAndSite(
content::SiteInstance* site_instance) override;
std::vector<std::unique_ptr<blink::URLLoaderThrottle>>
CreateURLLoaderThrottles(
const network::ResourceRequest& request,
content::BrowserContext* browser_context,
const base::RepeatingCallback<content::WebContents*()>& wc_getter,
content::NavigationUIData* navigation_ui_data,
int frame_tree_node_id) override;
int frame_tree_node_id,
absl::optional<int64_t> navigation_id) override;
base::flat_set<std::string> GetPluginMimeTypesWithExternalHandlers(
content::BrowserContext* browser_context) override;
bool IsSuitableHost(content::RenderProcessHost* process_host,

Просмотреть файл

@ -30,6 +30,7 @@
#include "content/browser/blob_storage/chrome_blob_storage_context.h" // nogncheck
#include "content/public/browser/browser_thread.h"
#include "content/public/browser/cors_origin_pattern_setter.h"
#include "content/public/browser/host_zoom_map.h"
#include "content/public/browser/render_process_host.h"
#include "content/public/browser/shared_cors_origin_access_list.h"
#include "content/public/browser/storage_partition.h"
@ -57,6 +58,7 @@
#include "shell/common/gin_helper/error_thrower.h"
#include "shell/common/options_switches.h"
#include "shell/common/thread_restrictions.h"
#include "third_party/blink/public/common/page/page_zoom.h"
#include "third_party/blink/public/mojom/media/capture_handle_config.mojom.h"
#include "third_party/blink/public/mojom/mediastream/media_stream.mojom.h"
@ -150,6 +152,29 @@ media::mojom::CaptureHandlePtr CreateCaptureHandle(
return result;
}
// Copied from chrome/browser/media/webrtc/desktop_capture_devices_util.cc.
absl::optional<int> GetZoomLevel(content::WebContents* capturer,
const url::Origin& capturer_origin,
const content::DesktopMediaID& captured_id) {
content::RenderFrameHost* const captured_rfh =
content::RenderFrameHost::FromID(
captured_id.web_contents_id.render_process_id,
captured_id.web_contents_id.main_render_frame_id);
if (!captured_rfh || !captured_rfh->IsActive()) {
return absl::nullopt;
}
content::WebContents* const captured_wc =
content::WebContents::FromRenderFrameHost(captured_rfh);
if (!captured_wc) {
return absl::nullopt;
}
double zoom_level = blink::PageZoomLevelToZoomFactor(
content::HostZoomMap::GetZoomLevel(captured_wc));
return std::round(100 * zoom_level);
}
// Copied from chrome/browser/media/webrtc/desktop_capture_devices_util.cc.
media::mojom::DisplayMediaInformationPtr
DesktopMediaIDToDisplayMediaInformation(
@ -169,6 +194,7 @@ DesktopMediaIDToDisplayMediaInformation(
#endif // defined(USE_AURA)
media::mojom::CaptureHandlePtr capture_handle;
int zoom_level = 100;
switch (media_id.type) {
case content::DesktopMediaID::TYPE_SCREEN:
display_surface = media::mojom::DisplayCaptureSurfaceType::MONITOR;
@ -184,13 +210,16 @@ DesktopMediaIDToDisplayMediaInformation(
display_surface = media::mojom::DisplayCaptureSurfaceType::BROWSER;
cursor = media::mojom::CursorCaptureType::MOTION;
capture_handle = CreateCaptureHandle(capturer, capturer_origin, media_id);
zoom_level =
GetZoomLevel(capturer, capturer_origin, media_id).value_or(100);
break;
case content::DesktopMediaID::TYPE_NONE:
break;
}
return media::mojom::DisplayMediaInformation::New(
display_surface, logical_surface, cursor, std::move(capture_handle));
display_surface, logical_surface, cursor, std::move(capture_handle),
zoom_level);
}
// Convert string to lower case and escape it.

Просмотреть файл

@ -216,7 +216,7 @@ void ElectronDownloadManagerDelegate::GetItemSaveDialogOptions(
void ElectronDownloadManagerDelegate::OnDownloadPathGenerated(
uint32_t download_id,
content::DownloadTargetCallback callback,
download::DownloadTargetCallback callback,
const base::FilePath& default_path) {
DCHECK_CURRENTLY_ON(content::BrowserThread::UI);
ScopedAllowBlockingForElectron allow_blocking;
@ -271,17 +271,20 @@ void ElectronDownloadManagerDelegate::OnDownloadPathGenerated(
std::ignore = dialog_promise.Then(std::move(dialog_callback));
file_dialog::ShowSaveDialog(settings, std::move(dialog_promise));
} else {
std::move(callback).Run(
path, download::DownloadItem::TARGET_DISPOSITION_PROMPT,
download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS,
item->GetInsecureDownloadStatus(), path, base::FilePath(),
std::string() /*mime_type*/, download::DOWNLOAD_INTERRUPT_REASON_NONE);
download::DownloadTargetInfo target_info;
target_info.target_path = path;
target_info.intermediate_path = path;
target_info.target_disposition =
download::DownloadItem::TARGET_DISPOSITION_PROMPT;
target_info.insecure_download_status = item->GetInsecureDownloadStatus();
std::move(callback).Run(std::move(target_info));
}
}
void ElectronDownloadManagerDelegate::OnDownloadSaveDialogDone(
uint32_t download_id,
content::DownloadTargetCallback download_callback,
download::DownloadTargetCallback download_callback,
gin_helper::Dictionary result) {
DCHECK_CURRENTLY_ON(content::BrowserThread::UI);
@ -311,11 +314,14 @@ void ElectronDownloadManagerDelegate::OnDownloadSaveDialogDone(
const auto interrupt_reason =
path.empty() ? download::DOWNLOAD_INTERRUPT_REASON_USER_CANCELED
: download::DOWNLOAD_INTERRUPT_REASON_NONE;
std::move(download_callback)
.Run(path, download::DownloadItem::TARGET_DISPOSITION_PROMPT,
download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS,
item->GetInsecureDownloadStatus(), path, base::FilePath(),
std::string() /*mime_type*/, interrupt_reason);
download::DownloadTargetInfo target_info;
target_info.target_path = path;
target_info.intermediate_path = path;
target_info.target_disposition =
download::DownloadItem::TARGET_DISPOSITION_PROMPT;
target_info.insecure_download_status = item->GetInsecureDownloadStatus();
target_info.interrupt_reason = interrupt_reason;
std::move(download_callback).Run(std::move(target_info));
}
void ElectronDownloadManagerDelegate::Shutdown() {
@ -325,17 +331,14 @@ void ElectronDownloadManagerDelegate::Shutdown() {
bool ElectronDownloadManagerDelegate::DetermineDownloadTarget(
download::DownloadItem* download,
content::DownloadTargetCallback* callback) {
download::DownloadTargetCallback* callback) {
DCHECK_CURRENTLY_ON(content::BrowserThread::UI);
if (!download->GetForcedFilePath().empty()) {
std::move(*callback).Run(
download->GetForcedFilePath(),
download::DownloadItem::TARGET_DISPOSITION_OVERWRITE,
download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS,
download::DownloadItem::InsecureDownloadStatus::UNKNOWN,
download->GetForcedFilePath(), base::FilePath(),
std::string() /*mime_type*/, download::DOWNLOAD_INTERRUPT_REASON_NONE);
download::DownloadTargetInfo target_info;
target_info.target_path = download->GetForcedFilePath();
target_info.intermediate_path = download->GetForcedFilePath();
std::move(*callback).Run(std::move(target_info));
return true;
}
@ -343,12 +346,10 @@ bool ElectronDownloadManagerDelegate::DetermineDownloadTarget(
base::FilePath save_path;
GetItemSavePath(download, &save_path);
if (!save_path.empty()) {
std::move(*callback).Run(
save_path, download::DownloadItem::TARGET_DISPOSITION_OVERWRITE,
download::DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS,
download::DownloadItem::InsecureDownloadStatus::UNKNOWN, save_path,
base::FilePath(), std::string() /*mime_type*/,
download::DOWNLOAD_INTERRUPT_REASON_NONE);
download::DownloadTargetInfo target_info;
target_info.target_path = save_path;
target_info.intermediate_path = save_path;
std::move(*callback).Run(std::move(target_info));
return true;
}

Просмотреть файл

@ -36,7 +36,7 @@ class ElectronDownloadManagerDelegate
void Shutdown() override;
bool DetermineDownloadTarget(
download::DownloadItem* download,
content::DownloadTargetCallback* callback) override;
download::DownloadTargetCallback* callback) override;
bool ShouldOpenDownload(
download::DownloadItem* download,
content::DownloadOpenDelayedCallback callback) override;
@ -49,12 +49,12 @@ class ElectronDownloadManagerDelegate
file_dialog::DialogSettings* options);
void OnDownloadPathGenerated(uint32_t download_id,
content::DownloadTargetCallback callback,
download::DownloadTargetCallback callback,
const base::FilePath& default_path);
void OnDownloadSaveDialogDone(
uint32_t download_id,
content::DownloadTargetCallback download_callback,
download::DownloadTargetCallback download_callback,
gin_helper::Dictionary result);
base::FilePath last_saved_directory_;

Просмотреть файл

@ -268,6 +268,13 @@ ElectronExtensionsBrowserClient::GetProcessManagerDelegate() const {
return process_manager_delegate_.get();
}
mojo::PendingRemote<network::mojom::URLLoaderFactory>
ElectronExtensionsBrowserClient::GetControlledFrameEmbedderURLLoader(
int frame_tree_node_id,
content::BrowserContext* browser_context) {
return mojo::PendingRemote<network::mojom::URLLoaderFactory>();
}
std::unique_ptr<extensions::ExtensionHostDelegate>
ElectronExtensionsBrowserClient::
CreateExtensionHostDelegate() { // TODO(samuelmaddock):

Просмотреть файл

@ -102,6 +102,10 @@ class ElectronExtensionsBrowserClient
const override;
extensions::ProcessManagerDelegate* GetProcessManagerDelegate()
const override;
mojo::PendingRemote<network::mojom::URLLoaderFactory>
GetControlledFrameEmbedderURLLoader(
int frame_tree_node_id,
content::BrowserContext* browser_context) override;
std::unique_ptr<extensions::ExtensionHostDelegate>
CreateExtensionHostDelegate() override;
bool DidVersionUpdate(content::BrowserContext* context) override;

Просмотреть файл

@ -39,7 +39,6 @@ void AsarFileValidator::OnRead(base::span<char> buffer,
if (current_block_ > max_block_) {
LOG(FATAL)
<< "Unexpected number of blocks while validating ASAR file stream";
return;
}
// Create a hash if we don't have one yet
@ -70,7 +69,6 @@ void AsarFileValidator::OnRead(base::span<char> buffer,
if (current_hash_byte_count_ == block_size && !FinishBlock()) {
LOG(FATAL) << "Failed to validate block while streaming ASAR file: "
<< current_block_;
return;
}
}
}
@ -105,7 +103,6 @@ bool AsarFileValidator::FinishBlock() {
std::vector<uint8_t> abandoned_buffer(bytes_needed);
if (!file_.ReadAndCheck(offset, abandoned_buffer)) {
LOG(FATAL) << "Failed to read required portion of streamed ASAR archive";
return false;
}
current_hash_->Update(&abandoned_buffer.front(), bytes_needed);

Просмотреть файл

@ -37,7 +37,7 @@ ElectronDesktopWindowTreeHostLinux::~ElectronDesktopWindowTreeHostLinux() =
bool ElectronDesktopWindowTreeHostLinux::SupportsClientFrameShadow() const {
return platform_window()->CanSetDecorationInsets() &&
platform_window()->IsTranslucentWindowOpacitySupported();
views::Widget::IsWindowCompositingSupported();
}
void ElectronDesktopWindowTreeHostLinux::OnWidgetInitDone() {
@ -97,6 +97,8 @@ void ElectronDesktopWindowTreeHostLinux::UpdateWindowState(
case ui::PlatformWindowState::kSnappedPrimary:
case ui::PlatformWindowState::kSnappedSecondary:
case ui::PlatformWindowState::kFloated:
case ui::PlatformWindowState::kPinnedFullscreen:
case ui::PlatformWindowState::kTrustedPinnedFullscreen:
break;
}
switch (new_state) {
@ -114,6 +116,8 @@ void ElectronDesktopWindowTreeHostLinux::UpdateWindowState(
case ui::PlatformWindowState::kSnappedPrimary:
case ui::PlatformWindowState::kSnappedSecondary:
case ui::PlatformWindowState::kFloated:
case ui::PlatformWindowState::kPinnedFullscreen:
case ui::PlatformWindowState::kTrustedPinnedFullscreen:
break;
}
window_state_ = new_state;
@ -146,7 +150,7 @@ void ElectronDesktopWindowTreeHostLinux::UpdateClientDecorationHints(
bool showing_frame = !native_window_view_->IsFullscreen();
float scale = device_scale_factor();
bool should_set_opaque_region = window->IsTranslucentWindowOpacitySupported();
bool should_set_opaque_region = views::Widget::IsWindowCompositingSupported();
gfx::Insets insets;
gfx::Insets input_insets;

Просмотреть файл

@ -132,9 +132,11 @@ void ClientFrameViewLinux::Init(NativeWindowViews* window,
window->GetAcceleratedWidget()));
host_supports_client_frame_shadow_ = tree_host->SupportsClientFrameShadow();
bool tiled = tiled_edges().top || tiled_edges().left ||
tiled_edges().bottom || tiled_edges().right;
frame_provider_ =
ui::LinuxUiTheme::GetForProfile(nullptr)->GetWindowFrameProvider(
!host_supports_client_frame_shadow_, frame_->IsMaximized());
!host_supports_client_frame_shadow_, tiled, frame_->IsMaximized());
UpdateWindowTitle();
@ -283,9 +285,11 @@ void ClientFrameViewLinux::Layout() {
return;
}
bool tiled = tiled_edges().top || tiled_edges().left ||
tiled_edges().bottom || tiled_edges().right;
frame_provider_ =
ui::LinuxUiTheme::GetForProfile(nullptr)->GetWindowFrameProvider(
!host_supports_client_frame_shadow_, frame_->IsMaximized());
!host_supports_client_frame_shadow_, tiled, frame_->IsMaximized());
UpdateButtonImages();
LayoutButtons();
@ -302,7 +306,7 @@ void ClientFrameViewLinux::OnPaint(gfx::Canvas* canvas) {
if (!frame_->IsFullscreen()) {
frame_provider_->PaintWindowFrame(canvas, GetLocalBounds(),
GetTitlebarBounds().bottom(),
ShouldPaintAsActive(), tiled_edges());
ShouldPaintAsActive(), GetInputInsets());
}
}

Просмотреть файл

@ -27,7 +27,7 @@ void Log(int severity, std::string text) {
break;
case logging::LOGGING_FATAL:
LOG(FATAL) << text;
break;
// break not needed here because LOG(FATAL) is [[noreturn]]
default:
LOG(ERROR) << "Unrecognized severity: " << severity;
break;

Просмотреть файл

@ -146,7 +146,6 @@ bool FillFileInfoWithNode(Archive::FileInfo* info,
if (!info->integrity.has_value()) {
LOG(FATAL) << "Failed to read integrity for file in ASAR archive";
return false;
}
}
#endif
@ -246,7 +245,6 @@ bool Archive::Init() {
if (!integrity.has_value()) {
LOG(FATAL) << "Failed to get integrity for validatable asar archive: "
<< RelativePath().value();
return false;
}
// Currently we only support the sha256 algorithm, we can add support for

Просмотреть файл

@ -27,7 +27,6 @@ std::optional<base::FilePath> Archive::RelativePath() const {
base::FilePath exe_path;
if (!base::PathService::Get(base::FILE_EXE, &exe_path)) {
LOG(FATAL) << "Couldn't get exe file path";
return std::nullopt;
}
base::FilePath relative_path;
@ -59,13 +58,11 @@ LoadIntegrityConfigCache() {
kIntegrityCheckResourceType);
if (!resource) {
PLOG(FATAL) << "FindResource failed.";
return *integrity_config_cache;
}
HGLOBAL rcData = ::LoadResource(module_handle, resource);
if (!rcData) {
PLOG(FATAL) << "LoadResource failed.";
return *integrity_config_cache;
}
auto* res_data = static_cast<const char*>(::LockResource(rcData));
@ -73,12 +70,10 @@ LoadIntegrityConfigCache() {
if (!res_data) {
PLOG(FATAL) << "Failed to integrity config from exe resource.";
return *integrity_config_cache;
}
if (!res_size) {
PLOG(FATAL) << "Unexpected empty integrity config from exe resource.";
return *integrity_config_cache;
}
// Parse integrity config payload
@ -88,13 +83,11 @@ LoadIntegrityConfigCache() {
if (!root.has_value()) {
LOG(FATAL) << "Invalid integrity config: NOT a valid JSON.";
return *integrity_config_cache;
}
const base::Value::List* file_configs = root.value().GetIfList();
if (!file_configs) {
LOG(FATAL) << "Invalid integrity config: NOT a list.";
return *integrity_config_cache;
}
// Parse each individual file integrity config
@ -157,7 +150,6 @@ std::optional<IntegrityPayload> Archive::HeaderIntegrity() const {
auto iter = integrity_config.value().find(rel_path_utf8);
if (iter == integrity_config.value().end()) {
LOG(FATAL) << "Failed to find file integrity info for " << rel_path_utf8;
return std::nullopt;
}
return iter->second;

Просмотреть файл

@ -88,7 +88,7 @@ bool ElectronExtensionsAPIProvider::IsAPISchemaGenerated(
return extensions::api::ElectronGeneratedSchemas::IsGenerated(name);
}
base::StringPiece ElectronExtensionsAPIProvider::GetAPISchema(
std::string_view ElectronExtensionsAPIProvider::GetAPISchema(
const std::string& name) {
return extensions::api::ElectronGeneratedSchemas::Get(name);
}

Просмотреть файл

@ -29,7 +29,7 @@ class ElectronExtensionsAPIProvider : public extensions::ExtensionsAPIProvider {
void AddAPIJSONSources(
extensions::JSONFeatureProviderSource* json_source) override;
bool IsAPISchemaGenerated(const std::string& name) override;
base::StringPiece GetAPISchema(const std::string& name) override;
std::string_view GetAPISchema(const std::string& name) override;
void RegisterPermissions(
extensions::PermissionsInfo* permissions_info) override;
void RegisterManifestHandlers() override;

Просмотреть файл

@ -2988,7 +2988,7 @@ describe('navigator.clipboard.read', () => {
it('returns clipboard contents when a PermissionRequestHandler is not defined', async () => {
const clipboard = await readClipboard();
expect(clipboard).to.not.equal('Read permission denied.');
expect(clipboard).to.not.contain('Read permission denied.');
});
it('returns an error when permission denied', async () => {
@ -3000,7 +3000,7 @@ describe('navigator.clipboard.read', () => {
}
});
const clipboard = await readClipboard();
expect(clipboard).to.equal('Read permission denied.');
expect(clipboard).to.contain('Read permission denied.');
});
it('returns clipboard contents when permission is granted', async () => {
@ -3012,7 +3012,7 @@ describe('navigator.clipboard.read', () => {
}
});
const clipboard = await readClipboard();
expect(clipboard).to.not.equal('Read permission denied.');
expect(clipboard).to.not.contain('Read permission denied.');
});
});
@ -3036,7 +3036,7 @@ describe('navigator.clipboard.write', () => {
it('returns clipboard contents when a PermissionRequestHandler is not defined', async () => {
const clipboard = await writeClipboard();
expect(clipboard).to.not.equal('Write permission denied.');
expect(clipboard).to.be.undefined();
});
it('returns an error when permission denied', async () => {
@ -3048,7 +3048,7 @@ describe('navigator.clipboard.write', () => {
}
});
const clipboard = await writeClipboard();
expect(clipboard).to.equal('Write permission denied.');
expect(clipboard).to.contain('Write permission denied.');
});
it('returns clipboard contents when permission is granted', async () => {
@ -3060,7 +3060,7 @@ describe('navigator.clipboard.write', () => {
}
});
const clipboard = await writeClipboard();
expect(clipboard).to.not.equal('Write permission denied.');
expect(clipboard).to.be.undefined();
});
});