Update to Chromium version 127.0.6533.0 (#1313161)

This commit is contained in:
Marshall Greenblatt
2024-06-14 13:01:45 -04:00
parent 4ed13d8c47
commit c44aa35bfc
144 changed files with 877 additions and 910 deletions

View File

@ -1,13 +0,0 @@
diff --git base/allocator/partition_allocator/src/partition_alloc/pointers/instance_tracer.cc base/allocator/partition_allocator/src/partition_alloc/pointers/instance_tracer.cc
index fecc2c35a3dcf..3745ac1d22a93 100644
--- base/allocator/partition_allocator/src/partition_alloc/pointers/instance_tracer.cc
+++ base/allocator/partition_allocator/src/partition_alloc/pointers/instance_tracer.cc
@@ -42,7 +42,7 @@ auto& GetStorage() {
}
auto& GetStorageMutex() {
- static partition_alloc::internal::base::NoDestructor<std::mutex>
+ static partition_alloc::internal::base::NoDestructor<std::recursive_mutex>
storage_mutex;
return *storage_mutex;
}

View File

@ -1,5 +1,5 @@
diff --git base/BUILD.gn base/BUILD.gn
index 575149b2f3246..74719a39cf4e4 100644
index 4ae52e5351615..272875eb5fe93 100644
--- base/BUILD.gn
+++ base/BUILD.gn
@@ -41,6 +41,7 @@ import("//build/nocompile.gni")
@ -10,7 +10,7 @@ index 575149b2f3246..74719a39cf4e4 100644
import("//testing/libfuzzer/fuzzer_test.gni")
import("//testing/test.gni")
@@ -1525,7 +1526,11 @@ component("base") {
@@ -1510,7 +1511,11 @@ component("base") {
"hash/md5_constexpr_internal.h",
"hash/sha1.h",
]
@ -23,7 +23,7 @@ index 575149b2f3246..74719a39cf4e4 100644
sources += [
"hash/md5_nacl.cc",
"hash/md5_nacl.h",
@@ -1954,6 +1959,12 @@ component("base") {
@@ -1939,6 +1944,12 @@ component("base") {
defines += [ "COM_INIT_CHECK_HOOK_DISABLED" ]
}
@ -73,11 +73,11 @@ index 215d636fec275..922e88f31b999 100644
#else
#include "base/hash/md5_boringssl.h"
diff --git base/hash/sha1.h base/hash/sha1.h
index 1891e95fa387d..fc190dc39ae7d 100644
index 857159d757637..63b5b396a00dd 100644
--- base/hash/sha1.h
+++ base/hash/sha1.h
@@ -14,7 +14,9 @@
#include "base/base_export.h"
@@ -15,7 +15,9 @@
#include "base/compiler_specific.h"
#include "base/containers/span.h"
#include "build/build_config.h"
-#if BUILDFLAG(IS_NACL)
@ -188,7 +188,7 @@ index 1f91a938caf55..e7b383ebe3986 100644
return lhs.token_ == rhs.token_;
#else
diff --git base/win/sid.cc base/win/sid.cc
index dd063382d97e1..6f8d6a0be91b1 100644
index dd063382d97e1..968dde0567c44 100644
--- base/win/sid.cc
+++ base/win/sid.cc
@@ -22,6 +22,7 @@
@ -220,13 +220,12 @@ index dd063382d97e1..6f8d6a0be91b1 100644
CRYPTO_library_init();
static_assert((SHA256_DIGEST_LENGTH / sizeof(DWORD)) ==
SECURITY_APP_PACKAGE_RID_COUNT);
@@ -143,6 +149,10 @@ Sid Sid::FromNamedCapability(const std::wstring& capability_name) {
@@ -143,6 +149,9 @@ Sid Sid::FromNamedCapability(const std::wstring& capability_name) {
reinterpret_cast<uint8_t*>(&rids[2]));
return FromSubAuthorities(SECURITY_APP_PACKAGE_AUTHORITY, std::size(rids),
rids);
+#else
+ NOTREACHED();
+ return Sid(WellKnownSid::kNull);
+#endif
}

View File

@ -1,8 +1,8 @@
diff --git base/test/BUILD.gn base/test/BUILD.gn
index feafabc3a60f9..f78cafeadb879 100644
index a60a2c1de0166..a191640ca0375 100644
--- base/test/BUILD.gn
+++ base/test/BUILD.gn
@@ -191,11 +191,6 @@ static_library("test_support") {
@@ -192,11 +192,6 @@ static_library("test_support") {
if (enable_base_tracing) {
public_deps += [ "//third_party/perfetto:perfetto_test_support" ]
@ -14,7 +14,7 @@ index feafabc3a60f9..f78cafeadb879 100644
deps += [
":amalgamated_perfetto_sql_stdlib",
":gen_cc_chrome_track_event_descriptor",
@@ -563,7 +558,7 @@ if (enable_base_tracing) {
@@ -564,7 +559,7 @@ if (enable_base_tracing) {
# processor depends on dev_sqlite. The two share the same symbols but have
# different implementations, so we need to hide dev_sqlite in this shared
# library even in non-component builds to prevent duplicate symbols.
@ -23,7 +23,7 @@ index feafabc3a60f9..f78cafeadb879 100644
if (is_ios) {
_target_type = "ios_framework_bundle"
}
@@ -572,6 +567,8 @@ if (enable_base_tracing) {
@@ -573,6 +568,8 @@ if (enable_base_tracing) {
defines = [ "TEST_TRACE_PROCESSOR_IMPL" ]
testonly = true
sources = [
@ -32,7 +32,7 @@ index feafabc3a60f9..f78cafeadb879 100644
"test_trace_processor_export.h",
"test_trace_processor_impl.cc",
"test_trace_processor_impl.h",
@@ -589,33 +586,6 @@ if (enable_base_tracing) {
@@ -590,33 +587,6 @@ if (enable_base_tracing) {
output_name = "TestTraceProcessor"
bundle_deps_filter = [ "//third_party/icu:icudata" ]
}
@ -88,10 +88,10 @@ index f5191b804bc07..aadb7d66ba4c3 100644
+
#endif // BASE_TEST_TEST_TRACE_PROCESSOR_EXPORT_H_
diff --git content/shell/BUILD.gn content/shell/BUILD.gn
index 2439098be9ada..7235455526000 100644
index fdc8e7ef0641d..494fa1379b5a3 100644
--- content/shell/BUILD.gn
+++ content/shell/BUILD.gn
@@ -908,7 +908,6 @@ if (is_mac) {
@@ -913,7 +913,6 @@ if (is_mac) {
# Specify a sensible install_name for static builds. The library is
# dlopen()ed so this is not used to resolve the module.
ldflags = [ "-Wl,-install_name,@executable_path/../Frameworks/$output_name.framework/$output_name" ]

View File

@ -0,0 +1,15 @@
diff --git base/task/thread_pool/thread_pool_impl.cc base/task/thread_pool/thread_pool_impl.cc
index 4ac5cea5f6c08..559593f1564c9 100644
--- base/task/thread_pool/thread_pool_impl.cc
+++ base/task/thread_pool/thread_pool_impl.cc
@@ -105,6 +105,10 @@ ThreadPoolImpl::ThreadPoolImpl(std::string_view histogram_label,
: kForegroundPoolEnvironmentParams.thread_type_hint,
task_tracker_->GetTrackedRef(), tracked_ref_factory_.GetTrackedRef());
}
+
+ // After https://crrev.com/e2e090c363 the ThreadPool is being created earlier
+ // during initialization. Detach now so we can rebind later on the UI thread.
+ DETACH_FROM_SEQUENCE(sequence_checker_);
}
ThreadPoolImpl::~ThreadPoolImpl() {

View File

@ -1,5 +1,5 @@
diff --git third_party/blink/public/web/web_element.h third_party/blink/public/web/web_element.h
index 103cbab74b515..3b763e5100340 100644
index 023ce7091b061..f175b3683f48f 100644
--- third_party/blink/public/web/web_element.h
+++ third_party/blink/public/web/web_element.h
@@ -82,6 +82,9 @@ class BLINK_EXPORT WebElement : public WebNode {
@ -10,13 +10,13 @@ index 103cbab74b515..3b763e5100340 100644
+ WebString AttributeValue(unsigned index) const;
+ unsigned AttributeCount() const;
// Returns true if the element's contenteditable attribute is in the true
// state or in the plaintext-only state:
// Returns true if the element's computed writing suggestions value is true.
// https://html.spec.whatwg.org/#writing-suggestions:computed-writing-suggestions-value
diff --git third_party/blink/renderer/core/exported/web_element.cc third_party/blink/renderer/core/exported/web_element.cc
index f05470ff9c673..7ffee95e4540b 100644
index da6ab6488ad80..7b23243e21a61 100644
--- third_party/blink/renderer/core/exported/web_element.cc
+++ third_party/blink/renderer/core/exported/web_element.cc
@@ -118,6 +118,24 @@ void WebElement::SetAttribute(const WebString& attr_name,
@@ -119,6 +119,24 @@ void WebElement::SetAttribute(const WebString& attr_name,
IGNORE_EXCEPTION_FOR_TESTING);
}

View File

@ -1,5 +1,5 @@
diff --git content/browser/scheduler/browser_task_executor.cc content/browser/scheduler/browser_task_executor.cc
index 68b69f564d911..0dba72515782f 100644
index e8283fc396ec7..527e81fac898a 100644
--- content/browser/scheduler/browser_task_executor.cc
+++ content/browser/scheduler/browser_task_executor.cc
@@ -209,7 +209,7 @@ BrowserTaskExecutor::OnUserInputStart() {

View File

@ -1,8 +1,8 @@
diff --git content/browser/child_process_security_policy_impl.cc content/browser/child_process_security_policy_impl.cc
index 7822aeab4826a..fa72112bfee98 100644
index 26fbdc7e7db0c..ac02e60276e5c 100644
--- content/browser/child_process_security_policy_impl.cc
+++ content/browser/child_process_security_policy_impl.cc
@@ -1988,6 +1988,16 @@ bool ChildProcessSecurityPolicyImpl::CanAccessMaybeOpaqueOrigin(
@@ -2048,6 +2048,16 @@ bool ChildProcessSecurityPolicyImpl::CanAccessMaybeOpaqueOrigin(
// DeclarativeApiTest.PersistRules.
if (actual_process_lock.matches_scheme(url::kDataScheme))
return true;
@ -20,10 +20,10 @@ index 7822aeab4826a..fa72112bfee98 100644
// Make an exception to allow most visited tiles to commit in
diff --git content/browser/renderer_host/navigation_request.cc content/browser/renderer_host/navigation_request.cc
index e3dd21898b85e..2176fde9c1764 100644
index 87db8bec18603..22c7d3fb838ab 100644
--- content/browser/renderer_host/navigation_request.cc
+++ content/browser/renderer_host/navigation_request.cc
@@ -7958,10 +7958,22 @@ NavigationRequest::GetOriginForURLLoaderFactoryBeforeResponseWithDebugInfo(
@@ -8057,10 +8057,22 @@ NavigationRequest::GetOriginForURLLoaderFactoryBeforeResponseWithDebugInfo(
bool use_opaque_origin =
(sandbox_flags & network::mojom::WebSandboxFlags::kOrigin) ==
network::mojom::WebSandboxFlags::kOrigin;
@ -47,7 +47,7 @@ index e3dd21898b85e..2176fde9c1764 100644
}
return origin_and_debug_info;
@@ -8069,6 +8081,15 @@ NavigationRequest::GetOriginForURLLoaderFactoryAfterResponseWithDebugInfo() {
@@ -8168,6 +8180,15 @@ NavigationRequest::GetOriginForURLLoaderFactoryAfterResponseWithDebugInfo() {
DetermineInitiatorRelationship(initiator_rfh,
frame_tree_node_->current_frame_host()));

View File

@ -1,5 +1,5 @@
diff --git build/config/compiler/BUILD.gn build/config/compiler/BUILD.gn
index 6efe967eb0a1c..429b3d8897085 100644
index f598fd188a4ce..ed515fc40d77c 100644
--- build/config/compiler/BUILD.gn
+++ build/config/compiler/BUILD.gn
@@ -133,6 +133,9 @@ declare_args() {
@ -12,7 +12,7 @@ index 6efe967eb0a1c..429b3d8897085 100644
# Initialize all local variables with a pattern. This flag will fill
# uninitialized floating-point types (and 32-bit pointers) with 0xFF and the
# rest with 0xAA. This makes behavior of uninitialized memory bugs consistent,
@@ -2179,11 +2182,13 @@ config("export_dynamic") {
@@ -2203,11 +2206,13 @@ config("export_dynamic") {
config("thin_archive") {
# The macOS and iOS default linker ld64 does not support reading thin
# archives.

View File

@ -1,5 +1,5 @@
diff --git chrome/browser/BUILD.gn chrome/browser/BUILD.gn
index c9ff70a8f2f71..d056d3758d564 100644
index 8e3fde5e841e1..8adc42aea0836 100644
--- chrome/browser/BUILD.gn
+++ chrome/browser/BUILD.gn
@@ -11,6 +11,7 @@ import("//build/config/compiler/pgo/pgo.gni")
@ -10,7 +10,7 @@ index c9ff70a8f2f71..d056d3758d564 100644
import("//chrome/browser/buildflags.gni")
import("//chrome/browser/downgrade/buildflags.gni")
import("//chrome/common/features.gni")
@@ -2091,6 +2092,7 @@ static_library("browser") {
@@ -2049,6 +2050,7 @@ static_library("browser") {
"//build/config/chromebox_for_meetings:buildflags",
"//build/config/compiler:compiler_buildflags",
"//cc",
@ -18,7 +18,7 @@ index c9ff70a8f2f71..d056d3758d564 100644
"//chrome:extra_resources",
"//chrome:resources",
"//chrome:strings",
@@ -2790,6 +2792,10 @@ static_library("browser") {
@@ -2769,6 +2771,10 @@ static_library("browser") {
]
}

View File

@ -14,10 +14,10 @@ index 21ab47267370b..eb9b383727995 100644
std::unique_ptr<BackgroundModeManager> manager) = 0;
#endif
diff --git chrome/browser/browser_process_impl.cc chrome/browser/browser_process_impl.cc
index f77210dcc2ff5..1d0eaa8ff245d 100644
index 762b9d42bc7f7..361e25df2d8f5 100644
--- chrome/browser/browser_process_impl.cc
+++ chrome/browser/browser_process_impl.cc
@@ -1113,18 +1113,14 @@ DownloadRequestLimiter* BrowserProcessImpl::download_request_limiter() {
@@ -1111,18 +1111,14 @@ DownloadRequestLimiter* BrowserProcessImpl::download_request_limiter() {
return download_request_limiter_.get();
}

View File

@ -13,7 +13,7 @@ index 2480282a19d12..dbd1fbf8a15b5 100644
return false;
}
diff --git chrome/browser/devtools/devtools_window.cc chrome/browser/devtools/devtools_window.cc
index e857e2363da9e..3dd4db8ae4267 100644
index 02ff1e580d3a7..7f51115896049 100644
--- chrome/browser/devtools/devtools_window.cc
+++ chrome/browser/devtools/devtools_window.cc
@@ -37,6 +37,7 @@
@ -24,7 +24,7 @@ index e857e2363da9e..3dd4db8ae4267 100644
#include "chrome/browser/ui/browser_list.h"
#include "chrome/browser/ui/browser_tabstrip.h"
#include "chrome/browser/ui/browser_window.h"
@@ -1235,6 +1236,13 @@ DevToolsWindow* DevToolsWindow::Create(
@@ -1234,6 +1235,13 @@ DevToolsWindow* DevToolsWindow::Create(
!browser->is_type_normal()) {
can_dock = false;
}
@ -38,7 +38,7 @@ index e857e2363da9e..3dd4db8ae4267 100644
}
// Create WebContents with devtools.
@@ -1916,12 +1924,28 @@ void DevToolsWindow::CreateDevToolsBrowser() {
@@ -1919,12 +1927,28 @@ void DevToolsWindow::CreateDevToolsBrowser() {
Browser::CreationStatus::kOk) {
return;
}
@ -74,7 +74,7 @@ index e857e2363da9e..3dd4db8ae4267 100644
}
diff --git chrome/browser/ui/BUILD.gn chrome/browser/ui/BUILD.gn
index 6ca4ed42a601d..feec87943fee4 100644
index 74460ac479210..8cf70c80a87ad 100644
--- chrome/browser/ui/BUILD.gn
+++ chrome/browser/ui/BUILD.gn
@@ -8,6 +8,7 @@ import("//build/config/compiler/compiler.gni")
@ -85,7 +85,7 @@ index 6ca4ed42a601d..feec87943fee4 100644
import("//chrome/browser/buildflags.gni")
import("//chrome/common/features.gni")
import("//chromeos/ash/components/assistant/assistant.gni")
@@ -403,6 +404,10 @@ static_library("ui") {
@@ -412,6 +413,10 @@ static_library("ui") {
"//build/config/compiler:wexit_time_destructors",
]
@ -96,7 +96,7 @@ index 6ca4ed42a601d..feec87943fee4 100644
# Since browser and browser_ui actually depend on each other,
# we must omit the dependency from browser_ui to browser.
# However, this means browser_ui and browser should more or less
@@ -429,6 +434,7 @@ static_library("ui") {
@@ -439,6 +444,7 @@ static_library("ui") {
"//build:chromeos_buildflags",
"//build/config/chromebox_for_meetings:buildflags",
"//cc/paint",
@ -104,8 +104,8 @@ index 6ca4ed42a601d..feec87943fee4 100644
"//chrome:resources",
"//chrome:strings",
"//chrome/app:chrome_dll_resources",
@@ -3000,6 +3006,8 @@ static_library("ui") {
"views/apps/app_dialog/app_block_dialog_view.h",
@@ -3040,6 +3046,8 @@ static_library("ui") {
"views/apps/app_dialog/app_local_block_dialog_view.h",
"views/apps/app_dialog/app_pause_dialog_view.cc",
"views/apps/app_dialog/app_pause_dialog_view.h",
+ "views/apps/app_dialog/app_uninstall_dialog_view.cc",
@ -113,7 +113,16 @@ index 6ca4ed42a601d..feec87943fee4 100644
"views/apps/app_info_dialog/arc_app_info_links_panel.cc",
"views/apps/app_info_dialog/arc_app_info_links_panel.h",
"views/apps/chrome_app_window_client_views_chromeos.cc",
@@ -5113,8 +5121,6 @@ static_library("ui") {
@@ -4249,8 +4257,6 @@ static_library("ui") {
"autofill/payments/webauthn_dialog_model.h",
"autofill/payments/webauthn_dialog_model_observer.h",
"autofill/payments/webauthn_dialog_state.h",
- "frame/window_frame_util.cc",
- "frame/window_frame_util.h",
"incognito_clear_browsing_data_dialog_interface.h",
"signin/signin_modal_dialog.cc",
"signin/signin_modal_dialog.h",
@@ -5125,8 +5131,6 @@ static_library("ui") {
"views/accessibility/theme_tracking_non_accessible_image_view.h",
"views/apps/app_dialog/app_dialog_view.cc",
"views/apps/app_dialog/app_dialog_view.h",
@ -122,7 +131,7 @@ index 6ca4ed42a601d..feec87943fee4 100644
"views/apps/app_info_dialog/app_info_dialog_container.cc",
"views/apps/app_info_dialog/app_info_dialog_container.h",
"views/apps/app_info_dialog/app_info_dialog_views.cc",
@@ -6965,6 +6971,7 @@ static_library("ui") {
@@ -6908,6 +6912,7 @@ static_library("ui") {
if (enable_printing) {
deps += [
"//components/printing/browser",
@ -131,10 +140,10 @@ index 6ca4ed42a601d..feec87943fee4 100644
]
}
diff --git chrome/browser/ui/browser.cc chrome/browser/ui/browser.cc
index a1d50c2e47056..e85ee7027bd19 100644
index 557abfcd71d85..fb64e93157148 100644
--- chrome/browser/ui/browser.cc
+++ chrome/browser/ui/browser.cc
@@ -269,6 +269,25 @@
@@ -272,6 +272,25 @@
#include "components/captive_portal/content/captive_portal_tab_helper.h"
#endif
@ -160,7 +169,7 @@ index a1d50c2e47056..e85ee7027bd19 100644
#if BUILDFLAG(ENABLE_EXTENSIONS)
#include "chrome/browser/extensions/extension_browser_window_helper.h"
#endif
@@ -515,6 +534,10 @@ Browser::Browser(const CreateParams& params)
@@ -537,6 +556,10 @@ Browser::Browser(const CreateParams& params)
type_(params.type),
profile_(params.profile),
window_(nullptr),
@ -171,7 +180,7 @@ index a1d50c2e47056..e85ee7027bd19 100644
tab_strip_model_delegate_(
std::make_unique<chrome::BrowserTabStripModelDelegate>(this)),
tab_strip_model_(std::make_unique<TabStripModel>(
@@ -722,6 +745,12 @@ Browser::~Browser() {
@@ -757,6 +780,12 @@ Browser::~Browser() {
// away so they don't try and call back to us.
if (select_file_dialog_.get())
select_file_dialog_->ListenerDestroyed();
@ -184,7 +193,7 @@ index a1d50c2e47056..e85ee7027bd19 100644
}
///////////////////////////////////////////////////////////////////////////////
@@ -1170,6 +1199,8 @@ void Browser::WindowFullscreenStateChanged() {
@@ -1217,6 +1246,8 @@ void Browser::WindowFullscreenStateChanged() {
->WindowFullscreenStateChanged();
command_controller_->FullscreenStateChanged();
UpdateBookmarkBarState(BOOKMARK_BAR_STATE_CHANGE_TOGGLE_FULLSCREEN);
@ -193,7 +202,7 @@ index a1d50c2e47056..e85ee7027bd19 100644
}
void Browser::FullscreenTopUIStateChanged() {
@@ -1511,6 +1542,14 @@ content::KeyboardEventProcessingResult Browser::PreHandleKeyboardEvent(
@@ -1584,6 +1615,14 @@ content::KeyboardEventProcessingResult Browser::PreHandleKeyboardEvent(
if (exclusive_access_manager_->HandleUserKeyEvent(event))
return content::KeyboardEventProcessingResult::HANDLED;
@ -208,7 +217,7 @@ index a1d50c2e47056..e85ee7027bd19 100644
return window()->PreHandleKeyboardEvent(event);
}
@@ -1518,8 +1557,18 @@ bool Browser::HandleKeyboardEvent(content::WebContents* source,
@@ -1591,8 +1630,18 @@ bool Browser::HandleKeyboardEvent(content::WebContents* source,
const NativeWebKeyboardEvent& event) {
DevToolsWindow* devtools_window =
DevToolsWindow::GetInstanceForInspectedWebContents(source);
@ -229,7 +238,7 @@ index a1d50c2e47056..e85ee7027bd19 100644
}
bool Browser::TabsNeedBeforeUnloadFired() const {
@@ -1695,6 +1744,16 @@ WebContents* Browser::OpenURLFromTab(
@@ -1768,6 +1817,16 @@ WebContents* Browser::OpenURLFromTab(
}
#endif // BUILDFLAG(IS_CHROMEOS_ASH)
@ -246,7 +255,7 @@ index a1d50c2e47056..e85ee7027bd19 100644
NavigateParams nav_params(this, params.url, params.transition);
nav_params.FillNavigateParamsFromOpenURLParams(params);
nav_params.source_contents = source;
@@ -1857,6 +1916,8 @@ void Browser::LoadingStateChanged(WebContents* source,
@@ -1930,6 +1989,8 @@ void Browser::LoadingStateChanged(WebContents* source,
bool should_show_loading_ui) {
ScheduleUIUpdate(source, content::INVALIDATE_TYPE_LOAD);
UpdateWindowForLoadingStateChanged(source, should_show_loading_ui);
@ -255,7 +264,7 @@ index a1d50c2e47056..e85ee7027bd19 100644
}
void Browser::CloseContents(WebContents* source) {
@@ -1885,6 +1946,8 @@ void Browser::SetContentsBounds(WebContents* source, const gfx::Rect& bounds) {
@@ -1958,6 +2019,8 @@ void Browser::SetContentsBounds(WebContents* source, const gfx::Rect& bounds) {
}
void Browser::UpdateTargetURL(WebContents* source, const GURL& url) {
@ -264,7 +273,7 @@ index a1d50c2e47056..e85ee7027bd19 100644
if (!GetStatusBubble())
return;
@@ -1892,6 +1955,17 @@ void Browser::UpdateTargetURL(WebContents* source, const GURL& url) {
@@ -1965,6 +2028,17 @@ void Browser::UpdateTargetURL(WebContents* source, const GURL& url) {
GetStatusBubble()->SetURL(url);
}
@ -282,7 +291,7 @@ index a1d50c2e47056..e85ee7027bd19 100644
void Browser::ContentsMouseEvent(WebContents* source, const ui::Event& event) {
const ui::EventType type = event.type();
const bool exited = type == ui::ET_MOUSE_EXITED;
@@ -1919,6 +1993,19 @@ bool Browser::TakeFocus(content::WebContents* source, bool reverse) {
@@ -1992,6 +2066,19 @@ bool Browser::TakeFocus(content::WebContents* source, bool reverse) {
return false;
}
@ -302,7 +311,7 @@ index a1d50c2e47056..e85ee7027bd19 100644
void Browser::BeforeUnloadFired(WebContents* web_contents,
bool proceed,
bool* proceed_to_fire_unload) {
@@ -2018,12 +2105,24 @@ void Browser::WebContentsCreated(WebContents* source_contents,
@@ -2091,12 +2178,24 @@ void Browser::WebContentsCreated(WebContents* source_contents,
// Make the tab show up in the task manager.
task_manager::WebContentsTags::CreateForTabContents(new_contents);
@ -327,7 +336,7 @@ index a1d50c2e47056..e85ee7027bd19 100644
// Don't show the page hung dialog when a HTML popup hangs because
// the dialog will take the focus and immediately close the popup.
RenderWidgetHostView* view = render_widget_host->GetView();
@@ -2036,6 +2135,13 @@ void Browser::RendererUnresponsive(
@@ -2109,6 +2208,13 @@ void Browser::RendererUnresponsive(
void Browser::RendererResponsive(
WebContents* source,
content::RenderWidgetHost* render_widget_host) {
@ -341,7 +350,7 @@ index a1d50c2e47056..e85ee7027bd19 100644
RenderWidgetHostView* view = render_widget_host->GetView();
if (view && !render_widget_host->GetView()->IsHTMLFormPopup()) {
TabDialogs::FromWebContents(source)->HideHungRendererDialog(
@@ -2045,6 +2151,15 @@ void Browser::RendererResponsive(
@@ -2118,6 +2224,15 @@ void Browser::RendererResponsive(
content::JavaScriptDialogManager* Browser::GetJavaScriptDialogManager(
WebContents* source) {
@ -357,7 +366,7 @@ index a1d50c2e47056..e85ee7027bd19 100644
return javascript_dialogs::TabModalDialogManager::FromWebContents(source);
}
@@ -2089,6 +2204,11 @@ void Browser::DraggableRegionsChanged(
@@ -2153,6 +2268,11 @@ void Browser::DraggableRegionsChanged(
if (app_controller_) {
app_controller_->DraggableRegionsChanged(regions, contents);
}
@ -369,7 +378,7 @@ index a1d50c2e47056..e85ee7027bd19 100644
}
void Browser::DidFinishNavigation(
@@ -2169,11 +2289,15 @@ void Browser::EnterFullscreenModeForTab(
@@ -2233,11 +2353,15 @@ void Browser::EnterFullscreenModeForTab(
const blink::mojom::FullscreenOptions& options) {
exclusive_access_manager_->fullscreen_controller()->EnterFullscreenModeForTab(
requesting_frame, options.display_id);
@ -385,7 +394,7 @@ index a1d50c2e47056..e85ee7027bd19 100644
}
bool Browser::IsFullscreenForTabOrPending(const WebContents* web_contents) {
@@ -2373,6 +2497,15 @@ void Browser::RequestMediaAccessPermission(
@@ -2437,6 +2561,15 @@ void Browser::RequestMediaAccessPermission(
content::WebContents* web_contents,
const content::MediaStreamRequest& request,
content::MediaResponseCallback callback) {
@ -401,7 +410,7 @@ index a1d50c2e47056..e85ee7027bd19 100644
const extensions::Extension* extension =
GetExtensionForOrigin(profile_, request.security_origin);
MediaCaptureDevicesDispatcher::GetInstance()->ProcessMediaAccessRequest(
@@ -2917,9 +3050,11 @@ void Browser::RemoveScheduledUpdatesFor(WebContents* contents) {
@@ -2981,9 +3114,11 @@ void Browser::RemoveScheduledUpdatesFor(WebContents* contents) {
// Browser, Getters for UI (private):
StatusBubble* Browser::GetStatusBubble() {
@ -414,7 +423,7 @@ index a1d50c2e47056..e85ee7027bd19 100644
}
// We hide the status bar for web apps windows as this matches native
@@ -2927,6 +3062,12 @@ StatusBubble* Browser::GetStatusBubble() {
@@ -2991,6 +3126,12 @@ StatusBubble* Browser::GetStatusBubble() {
// mode, as the minimal browser UI includes the status bar.
if (web_app::AppBrowserController::IsWebApp(this) &&
!app_controller()->HasMinimalUiButtons()) {
@ -427,7 +436,7 @@ index a1d50c2e47056..e85ee7027bd19 100644
return nullptr;
}
@@ -3076,6 +3217,8 @@ void Browser::SetAsDelegate(WebContents* web_contents, bool set_delegate) {
@@ -3140,6 +3281,8 @@ void Browser::SetAsDelegate(WebContents* web_contents, bool set_delegate) {
BookmarkTabHelper::FromWebContents(web_contents)->RemoveObserver(this);
web_contents_collection_.StopObserving(web_contents);
}
@ -436,7 +445,7 @@ index a1d50c2e47056..e85ee7027bd19 100644
}
void Browser::TabDetachedAtImpl(content::WebContents* contents,
@@ -3230,6 +3373,14 @@ bool Browser::PictureInPictureBrowserSupportsWindowFeature(
@@ -3294,6 +3437,14 @@ bool Browser::PictureInPictureBrowserSupportsWindowFeature(
bool Browser::SupportsWindowFeatureImpl(WindowFeature feature,
bool check_can_support) const {
@ -452,7 +461,7 @@ index a1d50c2e47056..e85ee7027bd19 100644
case TYPE_NORMAL:
return NormalBrowserSupportsWindowFeature(feature, check_can_support);
diff --git chrome/browser/ui/browser.h chrome/browser/ui/browser.h
index af562dfe07909..c81b2b05a85df 100644
index 69f2c9c0ff003..3cae24a0e42d2 100644
--- chrome/browser/ui/browser.h
+++ chrome/browser/ui/browser.h
@@ -22,6 +22,7 @@
@ -463,7 +472,7 @@ index af562dfe07909..c81b2b05a85df 100644
#include "chrome/browser/tab_contents/web_contents_collection.h"
#include "chrome/browser/themes/theme_service_observer.h"
#include "chrome/browser/ui/bookmarks/bookmark_bar.h"
@@ -50,6 +51,10 @@
@@ -51,6 +52,10 @@
#include "ui/gfx/geometry/rect.h"
#include "ui/shell_dialogs/select_file_dialog.h"
@ -474,7 +483,7 @@ index af562dfe07909..c81b2b05a85df 100644
#if BUILDFLAG(IS_ANDROID)
#error This file should only be included on desktop.
#endif
@@ -367,6 +372,15 @@ class Browser : public TabStripModelObserver,
@@ -370,6 +375,15 @@ class Browser : public TabStripModelObserver,
// Document Picture in Picture options, specific to TYPE_PICTURE_IN_PICTURE.
std::optional<blink::mojom::PictureInPictureWindowOptions> pip_options;
@ -490,7 +499,7 @@ index af562dfe07909..c81b2b05a85df 100644
private:
friend class Browser;
friend class WindowSizerChromeOSTest;
@@ -448,6 +462,13 @@ class Browser : public TabStripModelObserver,
@@ -451,6 +465,13 @@ class Browser : public TabStripModelObserver,
update_ui_immediately_for_testing_ = true;
}
@ -504,7 +513,7 @@ index af562dfe07909..c81b2b05a85df 100644
// Accessors ////////////////////////////////////////////////////////////////
const CreateParams& create_params() const { return create_params_; }
@@ -541,6 +562,12 @@ class Browser : public TabStripModelObserver,
@@ -546,6 +567,12 @@ class Browser : public TabStripModelObserver,
base::WeakPtr<Browser> AsWeakPtr();
base::WeakPtr<const Browser> AsWeakPtr() const;
@ -517,7 +526,7 @@ index af562dfe07909..c81b2b05a85df 100644
// Get the FindBarController for this browser, creating it if it does not
// yet exist.
FindBarController* GetFindBarController();
@@ -947,10 +974,18 @@ class Browser : public TabStripModelObserver,
@@ -959,10 +986,18 @@ class Browser : public TabStripModelObserver,
void SetContentsBounds(content::WebContents* source,
const gfx::Rect& bounds) override;
void UpdateTargetURL(content::WebContents* source, const GURL& url) override;
@ -536,7 +545,7 @@ index af562dfe07909..c81b2b05a85df 100644
void BeforeUnloadFired(content::WebContents* source,
bool proceed,
bool* proceed_to_fire_unload) override;
@@ -1292,6 +1327,10 @@ class Browser : public TabStripModelObserver,
@@ -1297,6 +1332,10 @@ class Browser : public TabStripModelObserver,
// This Browser's window.
raw_ptr<BrowserWindow, DanglingUntriaged> window_;
@ -547,7 +556,7 @@ index af562dfe07909..c81b2b05a85df 100644
std::unique_ptr<TabStripModelDelegate> const tab_strip_model_delegate_;
std::unique_ptr<TabStripModel> const tab_strip_model_;
@@ -1358,6 +1397,8 @@ class Browser : public TabStripModelObserver,
@@ -1363,6 +1402,8 @@ class Browser : public TabStripModelObserver,
const std::string initial_workspace_;
bool initial_visible_on_all_workspaces_state_;
@ -557,7 +566,7 @@ index af562dfe07909..c81b2b05a85df 100644
UnloadController unload_controller_;
diff --git chrome/browser/ui/browser_navigator.cc chrome/browser/ui/browser_navigator.cc
index 1bf5227d7c252..250012b2eb5fb 100644
index ec2ca0cefeb4a..66b480f50f72d 100644
--- chrome/browser/ui/browser_navigator.cc
+++ chrome/browser/ui/browser_navigator.cc
@@ -313,6 +313,10 @@ std::pair<Browser*, int> GetBrowserAndTabForDisposition(
@ -586,7 +595,7 @@ index 1bf5227d7c252..250012b2eb5fb 100644
// tab helpers, so the entire set of tab helpers needs to be set up
// immediately.
diff --git chrome/browser/ui/browser_tabstrip.cc chrome/browser/ui/browser_tabstrip.cc
index ca462913858cd..4b4153ab9aa1a 100644
index e12f401ab7d11..59222cc9601ba 100644
--- chrome/browser/ui/browser_tabstrip.cc
+++ chrome/browser/ui/browser_tabstrip.cc
@@ -33,9 +33,13 @@ content::WebContents* AddAndReturnTabAt(

View File

@ -56,15 +56,15 @@ index a344dc5c74ce3..548e6218b0e82 100644
supervised_user::SupervisedUserSettingsService* supervised_service =
SupervisedUserSettingsServiceFactory::GetForKey(profile->GetProfileKey());
diff --git components/content_settings/renderer/content_settings_agent_impl.cc components/content_settings/renderer/content_settings_agent_impl.cc
index f988c812b4ad9..3d5637f3cbdf3 100644
index 0cc2bfa06245f..86655f6746459 100644
--- components/content_settings/renderer/content_settings_agent_impl.cc
+++ components/content_settings/renderer/content_settings_agent_impl.cc
@@ -148,7 +148,7 @@ ContentSetting GetContentSettingFromRules(
return rule.GetContentSetting();
}
}
- NOTREACHED();
+ // NOTREACHED();
- NOTREACHED_IN_MIGRATION();
+ // NOTREACHED_IN_MIGRATION();
return CONTENT_SETTING_DEFAULT;
}
} // namespace

View File

@ -1,8 +1,8 @@
diff --git chrome/browser/renderer_context_menu/render_view_context_menu.cc chrome/browser/renderer_context_menu/render_view_context_menu.cc
index b62e659a27d00..e76cc7c0a7813 100644
index b3908e6711f3e..58db1ed6e1e8a 100644
--- chrome/browser/renderer_context_menu/render_view_context_menu.cc
+++ chrome/browser/renderer_context_menu/render_view_context_menu.cc
@@ -357,6 +357,18 @@ base::OnceCallback<void(RenderViewContextMenu*)>* GetMenuShownCallback() {
@@ -356,6 +356,18 @@ base::OnceCallback<void(RenderViewContextMenu*)>* GetMenuShownCallback() {
return callback.get();
}
@ -21,9 +21,9 @@ index b62e659a27d00..e76cc7c0a7813 100644
enum class UmaEnumIdLookupType {
GeneralEnumId,
ContextSpecificEnumId,
@@ -618,6 +630,10 @@ int FindUMAEnumValueForCommand(int id, UmaEnumIdLookupType type) {
if (ContextMenuMatcher::IsExtensionsCustomCommandId(id))
@@ -619,6 +631,10 @@ int FindUMAEnumValueForCommand(int id, UmaEnumIdLookupType type) {
return 1;
}
+ // Match the MENU_ID_USER_FIRST to MENU_ID_USER_LAST range from cef_types.h.
+ if (id >= 26500 && id <= 28500)
@ -32,9 +32,9 @@ index b62e659a27d00..e76cc7c0a7813 100644
id = CollapseCommandsForUMA(id);
const auto& map = GetIdcToUmaMap(type);
auto it = map.find(id);
@@ -868,6 +884,14 @@ RenderViewContextMenu::RenderViewContextMenu(
pdf_ocr_submenu_model_ = std::make_unique<ui::SimpleMenuModel>(this);
#endif // BUILDFLAG(ENABLE_SCREEN_AI_SERVICE)
@@ -882,6 +898,14 @@ RenderViewContextMenu::RenderViewContextMenu(
: nullptr;
#endif // BUILDFLAG(IS_CHROMEOS_ASH)
+ auto* cb = GetMenuCreatedCallback();
+ if (!cb->is_null()) {
@ -47,9 +47,9 @@ index b62e659a27d00..e76cc7c0a7813 100644
observers_.AddObserver(&autofill_context_menu_manager_);
}
@@ -1343,6 +1367,12 @@ void RenderViewContextMenu::InitMenu() {
autofill::SuggestionHidingReason::kContextMenuOpened);
}
@@ -1350,6 +1374,12 @@ void RenderViewContextMenu::InitMenu() {
autofill_client->HideAutofillSuggestions(
autofill::SuggestionHidingReason::kContextMenuOpened);
}
+
+ if (first_observer_) {
@ -60,7 +60,7 @@ index b62e659a27d00..e76cc7c0a7813 100644
}
Profile* RenderViewContextMenu::GetProfile() const {
@@ -3564,6 +3594,26 @@ void RenderViewContextMenu::RegisterExecutePluginActionCallbackForTesting(
@@ -3596,6 +3626,26 @@ void RenderViewContextMenu::RegisterExecutePluginActionCallbackForTesting(
execute_plugin_action_callback_ = std::move(cb);
}
@ -88,10 +88,10 @@ index b62e659a27d00..e76cc7c0a7813 100644
RenderViewContextMenu::GetHandlersForLinkUrl() {
custom_handlers::ProtocolHandlerRegistry::ProtocolHandlerList handlers =
diff --git chrome/browser/renderer_context_menu/render_view_context_menu.h chrome/browser/renderer_context_menu/render_view_context_menu.h
index 6c59d4ccaf3d5..21c959aea9c21 100644
index 8f0e62fe84ff2..77bf0875db2b2 100644
--- chrome/browser/renderer_context_menu/render_view_context_menu.h
+++ chrome/browser/renderer_context_menu/render_view_context_menu.h
@@ -155,7 +155,21 @@ class RenderViewContextMenu
@@ -153,7 +153,21 @@ class RenderViewContextMenu
}
#endif
@ -113,7 +113,7 @@ index 6c59d4ccaf3d5..21c959aea9c21 100644
Profile* GetProfile() const;
// This may return nullptr (e.g. for WebUI dialogs). Virtual to allow tests to
@@ -464,6 +478,9 @@ class RenderViewContextMenu
@@ -475,6 +489,9 @@ class RenderViewContextMenu
// built.
bool is_protocol_submenu_valid_ = false;
@ -305,7 +305,7 @@ index 042428f77f4ad..e4efd98ca45d5 100644
raw_ptr<content::WebContents> web_contents_ = nullptr;
};
diff --git components/renderer_context_menu/render_view_context_menu_base.cc components/renderer_context_menu/render_view_context_menu_base.cc
index 8e45cecb17039..e40115e23ee82 100644
index c22b3a584bb54..542b838ba3a44 100644
--- components/renderer_context_menu/render_view_context_menu_base.cc
+++ components/renderer_context_menu/render_view_context_menu_base.cc
@@ -374,6 +374,17 @@ bool RenderViewContextMenuBase::IsCommandIdChecked(int id) const {

View File

@ -1,5 +1,5 @@
diff --git chrome/browser/devtools/chrome_devtools_manager_delegate.cc chrome/browser/devtools/chrome_devtools_manager_delegate.cc
index ee871fcaed0fd..96480a8bd5db7 100644
index 10fd31daf60fa..49b10da9625f0 100644
--- chrome/browser/devtools/chrome_devtools_manager_delegate.cc
+++ chrome/browser/devtools/chrome_devtools_manager_delegate.cc
@@ -13,6 +13,7 @@

View File

@ -1,5 +1,5 @@
diff --git chrome/browser/file_select_helper.cc chrome/browser/file_select_helper.cc
index 447a91b9ac380..0452f0a8b57cf 100644
index b6e26d1d2e082..90aec2642adfe 100644
--- chrome/browser/file_select_helper.cc
+++ chrome/browser/file_select_helper.cc
@@ -20,6 +20,7 @@
@ -188,7 +188,7 @@ index 49272553c7c53..5ba90c9a06ecf 100644
raw_ptr<content::WebContents, AcrossTasksDanglingUntriaged> source_contents_;
};
diff --git ui/shell_dialogs/execute_select_file_win.cc ui/shell_dialogs/execute_select_file_win.cc
index 9361287ac3411..59567b485bf99 100644
index 5ef377bcbd69f..a2b9cc0b9be48 100644
--- ui/shell_dialogs/execute_select_file_win.cc
+++ ui/shell_dialogs/execute_select_file_win.cc
@@ -360,9 +360,7 @@ bool ExecuteSelectSingleFile(HWND owner,
@ -240,10 +240,10 @@ index 9361287ac3411..59567b485bf99 100644
paths.push_back(std::move(path));
}
diff --git ui/shell_dialogs/select_file_dialog.cc ui/shell_dialogs/select_file_dialog.cc
index 68dd62159b686..e94831cd44a2d 100644
index 4a71b1d4535d9..722a9480681bd 100644
--- ui/shell_dialogs/select_file_dialog.cc
+++ ui/shell_dialogs/select_file_dialog.cc
@@ -73,8 +73,10 @@ void SelectFileDialog::SetFactory(
@@ -89,8 +89,10 @@ void SelectFileDialog::SetFactory(
// static
scoped_refptr<SelectFileDialog> SelectFileDialog::Create(
Listener* listener,
@ -257,7 +257,7 @@ index 68dd62159b686..e94831cd44a2d 100644
return CreateSelectFileDialog(listener, std::move(policy));
}
diff --git ui/shell_dialogs/select_file_dialog.h ui/shell_dialogs/select_file_dialog.h
index 9b12fae59c3cc..a80873f421c8d 100644
index e71c14e499c25..3bc1e44b4c856 100644
--- ui/shell_dialogs/select_file_dialog.h
+++ ui/shell_dialogs/select_file_dialog.h
@@ -102,7 +102,8 @@ class SHELL_DIALOGS_EXPORT SelectFileDialog
@ -270,8 +270,8 @@ index 9b12fae59c3cc..a80873f421c8d 100644
SelectFileDialog(const SelectFileDialog&) = delete;
SelectFileDialog& operator=(const SelectFileDialog&) = delete;
@@ -126,6 +127,10 @@ class SHELL_DIALOGS_EXPORT SelectFileDialog
// be used.
@@ -136,6 +137,10 @@ class SHELL_DIALOGS_EXPORT SelectFileDialog
// FileTypeExtensions instead of this and the above vector?
std::vector<std::u16string> extension_description_overrides;
+ // Original mime types for the specified extensions. Entries correspond to
@ -281,7 +281,7 @@ index 9b12fae59c3cc..a80873f421c8d 100644
// Specifies whether there will be a filter added for all files (i.e. *.*).
bool include_all_files = false;
@@ -199,6 +204,19 @@ class SHELL_DIALOGS_EXPORT SelectFileDialog
@@ -209,6 +214,19 @@ class SHELL_DIALOGS_EXPORT SelectFileDialog
const GURL* caller = nullptr);
bool HasMultipleFileTypeChoices();
@ -301,7 +301,7 @@ index 9b12fae59c3cc..a80873f421c8d 100644
protected:
friend class base::RefCountedThreadSafe<SelectFileDialog>;
@@ -224,6 +242,11 @@ class SHELL_DIALOGS_EXPORT SelectFileDialog
@@ -234,6 +252,11 @@ class SHELL_DIALOGS_EXPORT SelectFileDialog
// The listener to be notified of selection completion.
raw_ptr<Listener> listener_;
@ -313,7 +313,7 @@ index 9b12fae59c3cc..a80873f421c8d 100644
private:
// Tests if the file selection dialog can be displayed by
// testing if the AllowFileSelectionDialogs-Policy is
@@ -236,8 +259,6 @@ class SHELL_DIALOGS_EXPORT SelectFileDialog
@@ -246,8 +269,6 @@ class SHELL_DIALOGS_EXPORT SelectFileDialog
// Returns true if the dialog has multiple file type choices.
virtual bool HasMultipleFileTypeChoicesImpl() = 0;
@ -336,7 +336,7 @@ index c7acd9b05fbb8..3e95e4125fa24 100644
} // namespace ui
diff --git ui/shell_dialogs/select_file_dialog_mac.mm ui/shell_dialogs/select_file_dialog_mac.mm
index bf99047fa53cf..0efdb76233331 100644
index abf5baa269fa2..b5e88a82537c1 100644
--- ui/shell_dialogs/select_file_dialog_mac.mm
+++ ui/shell_dialogs/select_file_dialog_mac.mm
@@ -107,6 +107,10 @@ void SelectFileDialogImpl::SelectFileImpl(
@ -351,7 +351,7 @@ index bf99047fa53cf..0efdb76233331 100644
std::make_unique<remote_cocoa::SelectFileDialogBridge>(ns_window),
std::move(receiver));
diff --git ui/shell_dialogs/select_file_dialog_win.cc ui/shell_dialogs/select_file_dialog_win.cc
index e5d4311ba152c..16c86e544fe3a 100644
index 9200d30f8d58a..f4156db6a7a73 100644
--- ui/shell_dialogs/select_file_dialog_win.cc
+++ ui/shell_dialogs/select_file_dialog_win.cc
@@ -254,6 +254,8 @@ void SelectFileDialogImpl::SelectFileImpl(

View File

@ -12,16 +12,15 @@ index b169371e4d42f..509e4bda85b47 100644
// on the screen, we can't actually attach to it.
parent_window = nullptr;
diff --git components/constrained_window/constrained_window_views.cc components/constrained_window/constrained_window_views.cc
index a2ca2f52148fd..7689d43ec9e0b 100644
index 0ffc333329d4d..91b7567c123ac 100644
--- components/constrained_window/constrained_window_views.cc
+++ components/constrained_window/constrained_window_views.cc
@@ -101,9 +101,18 @@ class WidgetModalDialogHostObserverViews : public views::WidgetObserver,
@@ -101,10 +101,17 @@ class WidgetModalDialogHostObserverViews : public views::WidgetObserver,
gfx::Rect GetModalDialogBounds(views::Widget* widget,
web_modal::ModalDialogHost* dialog_host,
const gfx::Size& size) {
- views::Widget* const host_widget =
- views::Widget::GetWidgetForNativeView(dialog_host->GetHostView());
- CHECK(host_widget);
+ // |host_view| will be nullptr with CEF windowless rendering.
+ auto host_view = dialog_host->GetHostView();
+ views::Widget* host_widget =
@ -31,13 +30,13 @@ index a2ca2f52148fd..7689d43ec9e0b 100644
+ // size. This can happen on MacViews under the Cocoa browser where the window
+ // modal dialogs are displayed as sheets, and their position is managed by a
+ // ConstrainedWindowSheetController instance.
+ if (!host_widget) {
if (!host_widget) {
- return gfx::Rect();
+ return gfx::Rect(dialog_host->GetDialogPosition(size), size);
+ }
}
gfx::Point position = dialog_host->GetDialogPosition(size);
// Align the first row of pixels inside the border. This is the apparent top
@@ -111,43 +120,22 @@ gfx::Rect GetModalDialogBounds(views::Widget* widget,
@@ -113,43 +120,22 @@ gfx::Rect GetModalDialogBounds(views::Widget* widget,
position.set_y(position.y() -
widget->non_client_view()->frame_view()->GetInsets().top());
@ -95,7 +94,7 @@ index a2ca2f52148fd..7689d43ec9e0b 100644
}
void UpdateModalDialogPosition(views::Widget* widget,
@@ -158,15 +146,24 @@ void UpdateModalDialogPosition(views::Widget* widget,
@@ -160,15 +146,24 @@ void UpdateModalDialogPosition(views::Widget* widget,
return;
}
@ -122,7 +121,7 @@ index a2ca2f52148fd..7689d43ec9e0b 100644
return;
}
@@ -282,8 +279,13 @@ views::Widget* CreateBrowserModalDialogViews(views::DialogDelegate* dialog,
@@ -284,8 +279,13 @@ views::Widget* CreateBrowserModalDialogViews(views::DialogDelegate* dialog,
gfx::NativeView parent_view =
parent ? CurrentClient()->GetDialogHostView(parent) : nullptr;
@ -137,7 +136,7 @@ index a2ca2f52148fd..7689d43ec9e0b 100644
widget->SetNativeWindowProperty(
views::kWidgetIdentifierKey,
const_cast<void*>(kConstrainedWindowWidgetIdentifier));
@@ -299,8 +301,7 @@ views::Widget* CreateBrowserModalDialogViews(views::DialogDelegate* dialog,
@@ -301,8 +301,7 @@ views::Widget* CreateBrowserModalDialogViews(views::DialogDelegate* dialog,
if (!requires_positioning)
return widget;
@ -147,7 +146,7 @@ index a2ca2f52148fd..7689d43ec9e0b 100644
if (host) {
DCHECK_EQ(parent_view, host->GetHostView());
ModalDialogHostObserver* dialog_host_observer =
@@ -313,10 +314,17 @@ views::Widget* CreateBrowserModalDialogViews(views::DialogDelegate* dialog,
@@ -315,10 +314,17 @@ views::Widget* CreateBrowserModalDialogViews(views::DialogDelegate* dialog,
views::Widget* ShowBrowserModal(std::unique_ptr<ui::DialogModel> dialog_model,
gfx::NativeWindow parent) {
@ -210,10 +209,10 @@ index 51ed6bcf6b540..c6e1161140655 100644
virtual gfx::Point GetDialogPosition(const gfx::Size& size) = 0;
// Returns whether a dialog currently about to be shown should be activated.
diff --git ui/views/window/dialog_delegate.cc ui/views/window/dialog_delegate.cc
index 941699c28e286..3f6569b116e64 100644
index 18611879ee372..938dbba3e3a87 100644
--- ui/views/window/dialog_delegate.cc
+++ ui/views/window/dialog_delegate.cc
@@ -85,10 +85,12 @@ DialogDelegate::DialogDelegate() {
@@ -91,10 +91,12 @@ DialogDelegate::DialogDelegate() {
// static
Widget* DialogDelegate::CreateDialogWidget(WidgetDelegate* delegate,
gfx::NativeWindow context,
@ -228,15 +227,14 @@ index 941699c28e286..3f6569b116e64 100644
widget->Init(std::move(params));
return widget;
}
@@ -97,17 +99,19 @@ Widget* DialogDelegate::CreateDialogWidget(WidgetDelegate* delegate,
@@ -103,16 +105,18 @@ Widget* DialogDelegate::CreateDialogWidget(WidgetDelegate* delegate,
Widget* DialogDelegate::CreateDialogWidget(
std::unique_ptr<WidgetDelegate> delegate,
gfx::NativeWindow context,
- gfx::NativeView parent) {
- return CreateDialogWidget(delegate.release(), context, parent);
+ gfx::NativeView parent,
+ gfx::AcceleratedWidget parent_widget) {
DCHECK(delegate->owned_by_widget());
- return CreateDialogWidget(delegate.release(), context, parent);
+ return CreateDialogWidget(delegate.release(), context, parent, parent_widget);
}
@ -252,16 +250,17 @@ index 941699c28e286..3f6569b116e64 100644
#else
return true;
#endif
@@ -118,14 +122,15 @@ Widget::InitParams DialogDelegate::GetDialogWidgetInitParams(
@@ -123,7 +127,8 @@ Widget::InitParams DialogDelegate::GetDialogWidgetInitParams(
WidgetDelegate* delegate,
gfx::NativeWindow context,
gfx::NativeView parent,
- const gfx::Rect& bounds) {
+ const gfx::Rect& bounds,
+ gfx::AcceleratedWidget parent_widget) {
views::Widget::InitParams params;
views::Widget::InitParams params(
Widget::InitParams::NATIVE_WIDGET_OWNS_WIDGET);
params.delegate = delegate;
params.bounds = bounds;
@@ -131,7 +136,7 @@ Widget::InitParams DialogDelegate::GetDialogWidgetInitParams(
DialogDelegate* dialog = delegate->AsDialogDelegate();
if (dialog)
@ -270,7 +269,7 @@ index 941699c28e286..3f6569b116e64 100644
if (!dialog || dialog->use_custom_frame()) {
params.opacity = Widget::InitParams::WindowOpacity::kTranslucent;
@@ -138,6 +143,7 @@ Widget::InitParams DialogDelegate::GetDialogWidgetInitParams(
@@ -144,6 +149,7 @@ Widget::InitParams DialogDelegate::GetDialogWidgetInitParams(
}
params.context = context;
params.parent = parent;

View File

@ -1,8 +1,8 @@
diff --git chrome/browser/download/chrome_download_manager_delegate.cc chrome/browser/download/chrome_download_manager_delegate.cc
index bc10e7566bd71..3b513b0b00b34 100644
index 2628f1751cd14..cc2c330d8db5d 100644
--- chrome/browser/download/chrome_download_manager_delegate.cc
+++ chrome/browser/download/chrome_download_manager_delegate.cc
@@ -146,6 +146,10 @@
@@ -148,6 +148,10 @@
#include "chrome/browser/safe_browsing/download_protection/download_protection_util.h"
#endif
@ -13,7 +13,7 @@ index bc10e7566bd71..3b513b0b00b34 100644
using content::BrowserThread;
using content::DownloadManager;
using download::DownloadItem;
@@ -490,6 +494,11 @@ ChromeDownloadManagerDelegate::ChromeDownloadManagerDelegate(Profile* profile)
@@ -492,6 +496,11 @@ ChromeDownloadManagerDelegate::ChromeDownloadManagerDelegate(Profile* profile)
download_dialog_bridge_ = std::make_unique<DownloadDialogBridge>();
download_message_bridge_ = std::make_unique<DownloadMessageBridge>();
#endif
@ -25,7 +25,7 @@ index bc10e7566bd71..3b513b0b00b34 100644
}
ChromeDownloadManagerDelegate::~ChromeDownloadManagerDelegate() {
@@ -549,6 +558,9 @@ void ChromeDownloadManagerDelegate::Shutdown() {
@@ -551,6 +560,9 @@ void ChromeDownloadManagerDelegate::Shutdown() {
download_manager_->RemoveObserver(this);
download_manager_ = nullptr;
}
@ -35,7 +35,7 @@ index bc10e7566bd71..3b513b0b00b34 100644
}
void ChromeDownloadManagerDelegate::OnDownloadCanceledAtShutdown(
@@ -617,6 +629,12 @@ bool ChromeDownloadManagerDelegate::DetermineDownloadTarget(
@@ -619,6 +631,12 @@ bool ChromeDownloadManagerDelegate::DetermineDownloadTarget(
ReportPDFLoadStatus(PDFLoadStatus::kTriggeredNoGestureDriveByDownload);
}
@ -49,7 +49,7 @@ index bc10e7566bd71..3b513b0b00b34 100644
base::BindOnce(&ChromeDownloadManagerDelegate::OnDownloadTargetDetermined,
weak_ptr_factory_.GetWeakPtr(), download->GetId(),
diff --git chrome/browser/download/chrome_download_manager_delegate.h chrome/browser/download/chrome_download_manager_delegate.h
index e2cf12d2c8fee..376818e28798c 100644
index af7f1d5fac12b..1cb1d01464c11 100644
--- chrome/browser/download/chrome_download_manager_delegate.h
+++ chrome/browser/download/chrome_download_manager_delegate.h
@@ -19,6 +19,7 @@
@ -73,7 +73,7 @@ index e2cf12d2c8fee..376818e28798c 100644
// This is the Chrome side helper for the download system.
class ChromeDownloadManagerDelegate
: public content::DownloadManagerDelegate,
@@ -387,6 +394,10 @@ class ChromeDownloadManagerDelegate
@@ -389,6 +396,10 @@ class ChromeDownloadManagerDelegate
// Whether a file picker dialog is showing.
bool is_file_picker_showing_;

View File

@ -34,10 +34,10 @@ index 4007e26f780c3..5f92d74018f9e 100644
}
diff --git chrome/browser/extensions/api/tabs/tabs_api.cc chrome/browser/extensions/api/tabs/tabs_api.cc
index 3d0843c7d1a60..b07956d25797d 100644
index 73de5dd73a522..12005b67a6ee9 100644
--- chrome/browser/extensions/api/tabs/tabs_api.cc
+++ chrome/browser/extensions/api/tabs/tabs_api.cc
@@ -1550,7 +1550,7 @@ ExtensionFunction::ResponseAction TabsUpdateFunction::Run() {
@@ -1553,7 +1553,7 @@ ExtensionFunction::ResponseAction TabsUpdateFunction::Run() {
if (DevToolsWindow::IsDevToolsWindow(contents))
return RespondNow(Error(tabs_constants::kNotAllowedForDevToolsError));
@ -46,7 +46,7 @@ index 3d0843c7d1a60..b07956d25797d 100644
return RespondNow(Error(tabs_constants::kNoCurrentWindowError));
web_contents_ = contents;
@@ -1574,7 +1574,7 @@ ExtensionFunction::ResponseAction TabsUpdateFunction::Run() {
@@ -1577,7 +1577,7 @@ ExtensionFunction::ResponseAction TabsUpdateFunction::Run() {
return RespondNow(Error(tabs_constants::kTabStripNotEditableError));
}
@ -55,7 +55,7 @@ index 3d0843c7d1a60..b07956d25797d 100644
tab_strip->ActivateTabAt(tab_index);
DCHECK_EQ(contents, tab_strip->GetActiveWebContents());
}
@@ -1588,7 +1588,7 @@ ExtensionFunction::ResponseAction TabsUpdateFunction::Run() {
@@ -1591,7 +1591,7 @@ ExtensionFunction::ResponseAction TabsUpdateFunction::Run() {
}
bool highlighted = *params->update_properties.highlighted;
@ -64,7 +64,7 @@ index 3d0843c7d1a60..b07956d25797d 100644
tab_strip->ToggleSelectionAt(tab_index);
}
}
@@ -1601,7 +1601,7 @@ ExtensionFunction::ResponseAction TabsUpdateFunction::Run() {
@@ -1604,7 +1604,7 @@ ExtensionFunction::ResponseAction TabsUpdateFunction::Run() {
base::NumberToString(tab_id))));
}
@ -73,7 +73,7 @@ index 3d0843c7d1a60..b07956d25797d 100644
int opener_id = *params->update_properties.opener_tab_id;
WebContents* opener_contents = nullptr;
if (opener_id == tab_id) {
@@ -1636,11 +1636,11 @@ ExtensionFunction::ResponseAction TabsUpdateFunction::Run() {
@@ -1639,11 +1639,11 @@ ExtensionFunction::ResponseAction TabsUpdateFunction::Run() {
}
const bool contents_in_an_uneditable_saved_group =
@ -87,7 +87,7 @@ index 3d0843c7d1a60..b07956d25797d 100644
// Pinning will result in changes to the tabs index/group affiliation in
// some cases, Throw an error if a tab is attempting to be pinned.
if (contents_in_an_uneditable_saved_group) {
@@ -1671,8 +1671,9 @@ ExtensionFunction::ResponseAction TabsUpdateFunction::Run() {
@@ -1674,8 +1674,9 @@ ExtensionFunction::ResponseAction TabsUpdateFunction::Run() {
}
std::string updated_url = *params->update_properties.url;
@ -99,14 +99,14 @@ index 3d0843c7d1a60..b07956d25797d 100644
return RespondNow(Error(ErrorUtils::FormatErrorMessage(
tabs_constants::kURLsNotAllowedInIncognitoError, updated_url)));
}
@@ -1686,7 +1687,7 @@ ExtensionFunction::ResponseAction TabsUpdateFunction::Run() {
@@ -1689,7 +1690,7 @@ ExtensionFunction::ResponseAction TabsUpdateFunction::Run() {
return RespondNow(Error(std::move(error)));
}
- NotifyExtensionTelemetry(Profile::FromBrowserContext(browser_context()),
+ NotifyExtensionTelemetry(profile,
extension(), safe_browsing::TabsApiInfo::UPDATE,
current_url, updated_url);
current_url, updated_url, js_callstack());
}
diff --git chrome/browser/extensions/extension_tab_util.cc chrome/browser/extensions/extension_tab_util.cc
index 46154f4501a36..81adec54cee06 100644
@ -187,10 +187,10 @@ index 4ca4ecd147267..dc8a8d004a1d6 100644
// ones that need to call AttachTabHelpers; if you think you do, re-read the
// design document linked above, especially the section "Reusing tab helpers".
diff --git chrome/browser/ui/views/download/bubble/download_toolbar_button_view.cc chrome/browser/ui/views/download/bubble/download_toolbar_button_view.cc
index b667ccfe87ccf..65283ef921458 100644
index b9bca4946ef9f..41207ebb86045 100644
--- chrome/browser/ui/views/download/bubble/download_toolbar_button_view.cc
+++ chrome/browser/ui/views/download/bubble/download_toolbar_button_view.cc
@@ -841,6 +841,10 @@ void DownloadToolbarButtonView::ShowPendingDownloadStartedAnimation() {
@@ -830,6 +830,10 @@ void DownloadToolbarButtonView::ShowPendingDownloadStartedAnimation() {
if (!gfx::Animation::ShouldRenderRichAnimation()) {
return;
}

View File

@ -1,5 +1,5 @@
diff --git chrome/browser/ui/views/frame/browser_frame_mac.h chrome/browser/ui/views/frame/browser_frame_mac.h
index a5ee05ae5f5e9..97fd2e8da450e 100644
index decd0b51ddc3d..17fce2da6ad0e 100644
--- chrome/browser/ui/views/frame/browser_frame_mac.h
+++ chrome/browser/ui/views/frame/browser_frame_mac.h
@@ -11,6 +11,7 @@
@ -10,7 +10,7 @@ index a5ee05ae5f5e9..97fd2e8da450e 100644
class BrowserFrame;
class BrowserView;
@class BrowserWindowTouchBarController;
@@ -54,6 +55,21 @@ class BrowserFrameMac : public views::NativeWidgetMac,
@@ -53,6 +54,21 @@ class BrowserFrameMac : public views::NativeWidgetMac,
bool ShouldUseInitialVisibleOnAllWorkspaces() const override;
void AnnounceTextInInProcessWindow(const std::u16string& text) override;
@ -33,7 +33,7 @@ index a5ee05ae5f5e9..97fd2e8da450e 100644
~BrowserFrameMac() override;
diff --git chrome/browser/ui/views/frame/browser_frame_mac.mm chrome/browser/ui/views/frame/browser_frame_mac.mm
index 13300a3ec7e25..b8f61c5845779 100644
index 0d7f72e291a14..b0fb3eae5eab6 100644
--- chrome/browser/ui/views/frame/browser_frame_mac.mm
+++ chrome/browser/ui/views/frame/browser_frame_mac.mm
@@ -182,7 +182,14 @@ void BrowserFrameMac::OnWindowFullscreenTransitionComplete() {

View File

@ -1,5 +1,5 @@
diff --git chrome/browser/net/proxy_config_monitor.cc chrome/browser/net/proxy_config_monitor.cc
index c9281f7abfbde..670872e610d88 100644
index c2adfa2bd0f79..ccb076655002c 100644
--- chrome/browser/net/proxy_config_monitor.cc
+++ chrome/browser/net/proxy_config_monitor.cc
@@ -9,6 +9,7 @@

View File

@ -1,5 +1,5 @@
diff --git chrome/browser/background_fetch/background_fetch_permission_context.cc chrome/browser/background_fetch/background_fetch_permission_context.cc
index 429739d7b8dfe..726cc7d9e9ced 100644
index fbc2dccbeb46d..9eea3a3c5c64c 100644
--- chrome/browser/background_fetch/background_fetch_permission_context.cc
+++ chrome/browser/background_fetch/background_fetch_permission_context.cc
@@ -4,6 +4,7 @@
@ -24,7 +24,7 @@ index 429739d7b8dfe..726cc7d9e9ced 100644
g_browser_process->download_request_limiter();
DCHECK(limiter);
diff --git chrome/browser/background_sync/periodic_background_sync_permission_context.cc chrome/browser/background_sync/periodic_background_sync_permission_context.cc
index d63a055919747..49adba291f1bb 100644
index c45e337c0c746..948cbbc9e3d7a 100644
--- chrome/browser/background_sync/periodic_background_sync_permission_context.cc
+++ chrome/browser/background_sync/periodic_background_sync_permission_context.cc
@@ -6,6 +6,7 @@
@ -49,10 +49,10 @@ index d63a055919747..49adba291f1bb 100644
base::FeatureList::IsEnabled(
features::kPeriodicSyncPermissionForDefaultSearchEngine) &&
diff --git chrome/browser/permissions/chrome_permissions_client.cc chrome/browser/permissions/chrome_permissions_client.cc
index 6d07868a1100b..ac8fc5e70f045 100644
index 1123ef8c5aa52..51f42541b3d7b 100644
--- chrome/browser/permissions/chrome_permissions_client.cc
+++ chrome/browser/permissions/chrome_permissions_client.cc
@@ -14,6 +14,7 @@
@@ -15,6 +15,7 @@
#include "base/time/time.h"
#include "build/build_config.h"
#include "build/chromeos_buildflags.h"
@ -60,7 +60,7 @@ index 6d07868a1100b..ac8fc5e70f045 100644
#include "chrome/browser/ash/shimless_rma/chrome_shimless_rma_delegate.h"
#include "chrome/browser/bluetooth/bluetooth_chooser_context_factory.h"
#include "chrome/browser/browser_process.h"
@@ -198,6 +199,11 @@ ChromePermissionsClient::GetPermissionDecisionAutoBlocker(
@@ -199,6 +200,11 @@ ChromePermissionsClient::GetPermissionDecisionAutoBlocker(
double ChromePermissionsClient::GetSiteEngagementScore(
content::BrowserContext* browser_context,
const GURL& origin) {
@ -72,7 +72,7 @@ index 6d07868a1100b..ac8fc5e70f045 100644
return site_engagement::SiteEngagementService::Get(
Profile::FromBrowserContext(browser_context))
->GetScore(origin);
@@ -368,8 +374,14 @@ ChromePermissionsClient::CreatePermissionUiSelectors(
@@ -369,8 +375,14 @@ ChromePermissionsClient::CreatePermissionUiSelectors(
std::make_unique<ContextualNotificationPermissionUiSelector>());
selectors.emplace_back(std::make_unique<PrefBasedQuietPermissionUiSelector>(
Profile::FromBrowserContext(browser_context)));
@ -161,10 +161,10 @@ index fbce13c16ad10..0512b2f09937e 100644
std::unique_ptr<permissions::PermissionPrompt> CreatePermissionPrompt(
content::WebContents* web_contents,
diff --git chrome/browser/ui/views/permissions/permission_prompt_factory.cc chrome/browser/ui/views/permissions/permission_prompt_factory.cc
index 7bf3d2015afc8..8a58296f19c30 100644
index 7f976b5bc5c44..ee2faa5c297a7 100644
--- chrome/browser/ui/views/permissions/permission_prompt_factory.cc
+++ chrome/browser/ui/views/permissions/permission_prompt_factory.cc
@@ -217,11 +217,28 @@ std::unique_ptr<permissions::PermissionPrompt> CreateQuietPrompt(
@@ -222,11 +222,28 @@ std::unique_ptr<permissions::PermissionPrompt> CreateQuietPrompt(
}
}

View File

@ -105,7 +105,7 @@ index d8fda08453256..466718e824503 100644
}
diff --git chrome/browser/policy/chrome_browser_policy_connector.cc chrome/browser/policy/chrome_browser_policy_connector.cc
index 50f1b5313ce45..687e667e4b942 100644
index 138ae48ca13c1..6d4e45a234a4e 100644
--- chrome/browser/policy/chrome_browser_policy_connector.cc
+++ chrome/browser/policy/chrome_browser_policy_connector.cc
@@ -13,11 +13,14 @@

View File

@ -1,5 +1,5 @@
diff --git chrome/browser/printing/print_backend_service_manager.cc chrome/browser/printing/print_backend_service_manager.cc
index e3a6645add6e3..4dde23d0451ff 100644
index a79694f7bdcc2..ec42dd0dc5ba2 100644
--- chrome/browser/printing/print_backend_service_manager.cc
+++ chrome/browser/printing/print_backend_service_manager.cc
@@ -74,7 +74,15 @@ PrintBackendServiceManager* g_print_backend_service_manager_singleton = nullptr;
@ -17,5 +17,5 @@ index e3a6645add6e3..4dde23d0451ff 100644
+ }
+ return base::win::HandleToUint32(hwnd);
#else
NOTREACHED();
NOTREACHED_IN_MIGRATION();
return 0;

View File

@ -1,8 +1,8 @@
diff --git chrome/browser/profiles/off_the_record_profile_impl.cc chrome/browser/profiles/off_the_record_profile_impl.cc
index 52da35f06a7a9..5fb43c7c65d34 100644
index 941d4bf2d302d..7d41044d01d9b 100644
--- chrome/browser/profiles/off_the_record_profile_impl.cc
+++ chrome/browser/profiles/off_the_record_profile_impl.cc
@@ -669,7 +669,9 @@ std::unique_ptr<Profile> Profile::CreateOffTheRecordProfile(
@@ -660,7 +660,9 @@ std::unique_ptr<Profile> Profile::CreateOffTheRecordProfile(
#endif
if (!profile)
profile = std::make_unique<OffTheRecordProfileImpl>(parent, otr_profile_id);
@ -14,7 +14,7 @@ index 52da35f06a7a9..5fb43c7c65d34 100644
}
diff --git chrome/browser/profiles/profile.cc chrome/browser/profiles/profile.cc
index a9762d47c397d..482c0e4c8550f 100644
index cd4fd8104866c..5cf5853d6632b 100644
--- chrome/browser/profiles/profile.cc
+++ chrome/browser/profiles/profile.cc
@@ -91,6 +91,7 @@ base::LazyInstance<std::set<content::BrowserContext*>>::Leaky
@ -52,7 +52,7 @@ index a9762d47c397d..482c0e4c8550f 100644
Profile::OTRProfileID Profile::OTRProfileID::CreateUniqueForDevTools() {
return CreateUnique(kDevToolsOTRProfileIDPrefix);
diff --git chrome/browser/profiles/profile.h chrome/browser/profiles/profile.h
index 7ad5372c8a135..1112491861262 100644
index 02454f4e780b5..4641f33c26f5f 100644
--- chrome/browser/profiles/profile.h
+++ chrome/browser/profiles/profile.h
@@ -94,6 +94,10 @@ class Profile : public content::BrowserContext {
@ -66,16 +66,17 @@ index 7ad5372c8a135..1112491861262 100644
// Creates a unique OTR profile id to be used for DevTools browser contexts.
static OTRProfileID CreateUniqueForDevTools();
@@ -515,6 +519,8 @@ class Profile : public content::BrowserContext {
return instant_service_;
}
@@ -519,6 +523,9 @@ class Profile : public content::BrowserContext {
static Profile* FromJavaObject(const jni_zero::JavaRef<jobject>& obj);
jni_zero::ScopedJavaLocalRef<jobject> GetJavaObject() const;
#endif // BUILDFLAG(IS_ANDROID)
+
+ void NotifyOffTheRecordProfileCreated(Profile* off_the_record);
+
protected:
// Creates an OffTheRecordProfile which points to this Profile.
static std::unique_ptr<Profile> CreateOffTheRecordProfile(
@@ -526,7 +532,6 @@ class Profile : public content::BrowserContext {
@@ -530,7 +537,6 @@ class Profile : public content::BrowserContext {
static PrefStore* CreateExtensionPrefStore(Profile*,
bool incognito_pref_store);
@ -84,10 +85,10 @@ index 7ad5372c8a135..1112491861262 100644
// Returns whether the user has signed in this profile to an account.
diff --git chrome/browser/profiles/profile_impl.cc chrome/browser/profiles/profile_impl.cc
index fbe18f0773bda..1066b8d2b382a 100644
index 0909a332a46bf..163de8ef6a878 100644
--- chrome/browser/profiles/profile_impl.cc
+++ chrome/browser/profiles/profile_impl.cc
@@ -1040,7 +1040,9 @@ Profile* ProfileImpl::GetOffTheRecordProfile(const OTRProfileID& otr_profile_id,
@@ -1030,7 +1030,9 @@ Profile* ProfileImpl::GetOffTheRecordProfile(const OTRProfileID& otr_profile_id,
otr_profiles_[otr_profile_id] = std::move(otr_profile);
@ -99,10 +100,10 @@ index fbe18f0773bda..1066b8d2b382a 100644
return raw_otr_profile;
}
diff --git chrome/browser/profiles/profile_manager.cc chrome/browser/profiles/profile_manager.cc
index 6e991d99df8ff..00145aba0bd83 100644
index 35ed366d5e749..da51d2e0081f5 100644
--- chrome/browser/profiles/profile_manager.cc
+++ chrome/browser/profiles/profile_manager.cc
@@ -436,7 +436,7 @@ ProfileManager::ProfileManager(const base::FilePath& user_data_dir)
@@ -437,7 +437,7 @@ ProfileManager::ProfileManager(const base::FilePath& user_data_dir)
profile_manager_android_ = std::make_unique<ProfileManagerAndroid>(this);
#endif
@ -134,10 +135,10 @@ index 3d5fd0d5ca858..965ab69b3fe8f 100644
// Returns the directory where the first created profile is stored,
// relative to the user data directory currently in use.
diff --git chrome/browser/profiles/renderer_updater.cc chrome/browser/profiles/renderer_updater.cc
index 0d1d2e3661ff1..ba4b8cb233102 100644
index 1154f4f02cc16..4c9e5128cd177 100644
--- chrome/browser/profiles/renderer_updater.cc
+++ chrome/browser/profiles/renderer_updater.cc
@@ -9,6 +9,7 @@
@@ -10,6 +10,7 @@
#include "base/functional/bind.h"
#include "base/functional/callback.h"
#include "build/chromeos_buildflags.h"
@ -145,7 +146,7 @@ index 0d1d2e3661ff1..ba4b8cb233102 100644
#include "chrome/browser/content_settings/content_settings_manager_delegate.h"
#include "chrome/browser/content_settings/host_content_settings_map_factory.h"
#include "chrome/browser/profiles/profile.h"
@@ -45,6 +46,9 @@ RendererUpdater::RendererUpdater(Profile* profile)
@@ -46,6 +47,9 @@ RendererUpdater::RendererUpdater(Profile* profile)
#if BUILDFLAG(ENABLE_BOUND_SESSION_CREDENTIALS)
,
bound_session_cookie_refresh_service_(

View File

@ -1,8 +1,8 @@
diff --git chrome/browser/safe_browsing/BUILD.gn chrome/browser/safe_browsing/BUILD.gn
index 102625231e535..47d0d7574b2ee 100644
index 22fd2393c9c70..e033dbd0d6d10 100644
--- chrome/browser/safe_browsing/BUILD.gn
+++ chrome/browser/safe_browsing/BUILD.gn
@@ -33,6 +33,7 @@ static_library("safe_browsing") {
@@ -34,6 +34,7 @@ static_library("safe_browsing") {
"//components/enterprise:enterprise",
"//components/enterprise/buildflags",
"//components/enterprise/common:strings",

View File

@ -1,8 +1,8 @@
diff --git chrome/browser/ui/startup/startup_browser_creator.cc chrome/browser/ui/startup/startup_browser_creator.cc
index 86ab9563e08bc..182be3b6ec1dc 100644
index 22a2efe170757..9c8c6c24dfa78 100644
--- chrome/browser/ui/startup/startup_browser_creator.cc
+++ chrome/browser/ui/startup/startup_browser_creator.cc
@@ -604,6 +604,13 @@ std::optional<ash::KioskAppId> GetAppId(const base::CommandLine& command_line,
@@ -605,6 +605,13 @@ std::optional<ash::KioskAppId> GetAppId(const base::CommandLine& command_line,
}
#endif // BUILDFLAG(IS_CHROMEOS_ASH)
@ -16,7 +16,7 @@ index 86ab9563e08bc..182be3b6ec1dc 100644
} // namespace
StartupProfileMode StartupProfileModeFromReason(
@@ -1488,6 +1495,12 @@ void StartupBrowserCreator::ProcessCommandLineWithProfile(
@@ -1489,6 +1496,12 @@ void StartupBrowserCreator::ProcessCommandLineWithProfile(
{profile, mode}, last_opened_profiles);
}
@ -29,7 +29,7 @@ index 86ab9563e08bc..182be3b6ec1dc 100644
// static
void StartupBrowserCreator::ProcessCommandLineAlreadyRunning(
const base::CommandLine& command_line,
@@ -1497,6 +1510,11 @@ void StartupBrowserCreator::ProcessCommandLineAlreadyRunning(
@@ -1498,6 +1511,11 @@ void StartupBrowserCreator::ProcessCommandLineAlreadyRunning(
return;
}

View File

@ -1,5 +1,5 @@
diff --git chrome/browser/themes/theme_service.cc chrome/browser/themes/theme_service.cc
index dd41ca3cb8f35..6123e27acffa8 100644
index 354965a6332b3..6843e6d123cc8 100644
--- chrome/browser/themes/theme_service.cc
+++ chrome/browser/themes/theme_service.cc
@@ -30,6 +30,7 @@
@ -9,8 +9,8 @@ index dd41ca3cb8f35..6123e27acffa8 100644
+#include "cef/libcef/features/runtime.h"
#include "chrome/browser/extensions/extension_service.h"
#include "chrome/browser/extensions/theme_installed_infobar_delegate.h"
#include "chrome/browser/new_tab_page/chrome_colors/chrome_colors_service.h"
@@ -68,6 +69,10 @@
#include "chrome/browser/new_tab_page/chrome_colors/chrome_colors_util.h"
@@ -65,6 +66,10 @@
#include "ui/color/color_provider_manager.h"
#include "ui/native_theme/native_theme.h"
@ -21,7 +21,7 @@ index dd41ca3cb8f35..6123e27acffa8 100644
#if BUILDFLAG(ENABLE_EXTENSIONS)
#include "base/scoped_observation.h"
#include "extensions/browser/extension_registry_observer.h"
@@ -269,11 +274,19 @@ void ThemeService::Init() {
@@ -266,11 +271,19 @@ void ThemeService::Init() {
// OnExtensionServiceReady. Otherwise, the ThemeObserver won't be
// constructed in time to observe the corresponding events.
#if BUILDFLAG(ENABLE_EXTENSIONS)

View File

@ -1,5 +1,5 @@
diff --git chrome/common/features.gni chrome/common/features.gni
index fc2d817cdab5d..bb0fe5b982aae 100644
index bcc0da3ae5a96..87617098debd3 100644
--- chrome/common/features.gni
+++ chrome/common/features.gni
@@ -7,6 +7,7 @@ import("//build/config/chromeos/ui_mode.gni")
@ -19,7 +19,7 @@ index fc2d817cdab5d..bb0fe5b982aae 100644
# Platforms where Chrome x509 server certificate enterprise policies are
# supported. This must must match the supported_on/future_on list of the
@@ -94,11 +95,13 @@ declare_args() {
@@ -95,11 +96,13 @@ declare_args() {
# optimize_webui was moved to ui/base/ui_features.gni
}

View File

@ -64,10 +64,10 @@ index 00dd9a34cd3fb..89d4588bdbe4e 100644
const extensions::Extension* extension =
registry->enabled_extensions().GetByID(extension_id);
diff --git chrome/renderer/chrome_content_renderer_client.cc chrome/renderer/chrome_content_renderer_client.cc
index 60bc3751cb325..ebce071c74a8b 100644
index 120ec8af72623..012f7b602cf40 100644
--- chrome/renderer/chrome_content_renderer_client.cc
+++ chrome/renderer/chrome_content_renderer_client.cc
@@ -1006,6 +1006,7 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
@@ -996,6 +996,7 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
if ((status == chrome::mojom::PluginStatus::kUnauthorized ||
status == chrome::mojom::PluginStatus::kBlocked) &&
@ -75,7 +75,7 @@ index 60bc3751cb325..ebce071c74a8b 100644
content_settings_agent_delegate->IsPluginTemporarilyAllowed(
identifier)) {
status = chrome::mojom::PluginStatus::kAllowed;
@@ -1166,7 +1167,8 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
@@ -1156,7 +1157,8 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
render_frame->GetRemoteAssociatedInterfaces()->GetInterface(
plugin_auth_host.BindNewEndpointAndPassReceiver());
plugin_auth_host->BlockedUnauthorizedPlugin(group_name, identifier);
@ -85,7 +85,7 @@ index 60bc3751cb325..ebce071c74a8b 100644
break;
}
case chrome::mojom::PluginStatus::kBlocked: {
@@ -1175,7 +1177,8 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
@@ -1165,7 +1167,8 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
l10n_util::GetStringFUTF16(IDS_PLUGIN_BLOCKED, group_name));
placeholder->AllowLoading();
RenderThread::Get()->RecordAction(UserMetricsAction("Plugin_Blocked"));
@ -95,7 +95,7 @@ index 60bc3751cb325..ebce071c74a8b 100644
break;
}
case chrome::mojom::PluginStatus::kBlockedByPolicy: {
@@ -1185,7 +1188,8 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
@@ -1175,7 +1178,8 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
group_name));
RenderThread::Get()->RecordAction(
UserMetricsAction("Plugin_BlockedByPolicy"));
@ -106,7 +106,7 @@ index 60bc3751cb325..ebce071c74a8b 100644
}
}
diff --git content/browser/browser_plugin/browser_plugin_embedder.h content/browser/browser_plugin/browser_plugin_embedder.h
index 8b26a93f7527e..17890bf20e481 100644
index ea2891a279371..595e5b8eb2cb6 100644
--- content/browser/browser_plugin/browser_plugin_embedder.h
+++ content/browser/browser_plugin/browser_plugin_embedder.h
@@ -15,6 +15,7 @@
@ -115,9 +115,9 @@ index 8b26a93f7527e..17890bf20e481 100644
#include "base/memory/raw_ptr.h"
+#include "content/common/content_export.h"
namespace content {
@@ -26,7 +27,7 @@ struct NativeWebKeyboardEvent;
namespace input {
struct NativeWebKeyboardEvent;
@@ -29,7 +30,7 @@ class WebContentsImpl;
// TODO(wjmaclean): Get rid of "BrowserPlugin" in the name of this class.
// Perhaps "WebContentsEmbedderDelegate" would be better?

View File

@ -1,5 +1,5 @@
diff --git chrome/renderer/BUILD.gn chrome/renderer/BUILD.gn
index 857247dd93f75..fc2f196d450cd 100644
index 3108e12b92e7f..18cc9062a4cd0 100644
--- chrome/renderer/BUILD.gn
+++ chrome/renderer/BUILD.gn
@@ -5,6 +5,7 @@

View File

@ -1,5 +1,5 @@
diff --git chrome/app/chrome_main_delegate.cc chrome/app/chrome_main_delegate.cc
index d60a195d58a27..df74bb2c60264 100644
index 2805028bc810c..bdf6f2fb7b3a1 100644
--- chrome/app/chrome_main_delegate.cc
+++ chrome/app/chrome_main_delegate.cc
@@ -37,6 +37,7 @@
@ -10,7 +10,7 @@ index d60a195d58a27..df74bb2c60264 100644
#include "chrome/browser/buildflags.h"
#include "chrome/browser/chrome_content_browser_client.h"
#include "chrome/browser/chrome_resource_bundle_helper.h"
@@ -608,6 +609,9 @@ struct MainFunction {
@@ -610,6 +611,9 @@ struct MainFunction {
// Initializes the user data dir. Must be called before InitializeLocalState().
void InitializeUserDataDir(base::CommandLine* command_line) {
@ -20,7 +20,7 @@ index d60a195d58a27..df74bb2c60264 100644
#if BUILDFLAG(IS_CHROMEOS_LACROS)
// In debug builds of Lacros, we keep track of when the user data dir
// is initialized, to ensure the cryptohome is not accessed before login
@@ -845,6 +849,10 @@ ChromeMainDelegate::~ChromeMainDelegate() {
@@ -847,6 +851,10 @@ ChromeMainDelegate::~ChromeMainDelegate() {
ChromeMainDelegate::~ChromeMainDelegate() = default;
#endif // !BUILDFLAG(IS_ANDROID)
@ -31,7 +31,7 @@ index d60a195d58a27..df74bb2c60264 100644
std::optional<int> ChromeMainDelegate::PostEarlyInitialization(
InvokedIn invoked_in) {
DUMP_WILL_BE_CHECK(base::ThreadPoolInstance::Get());
@@ -870,7 +878,7 @@ std::optional<int> ChromeMainDelegate::PostEarlyInitialization(
@@ -872,7 +880,7 @@ std::optional<int> ChromeMainDelegate::PostEarlyInitialization(
// future session's metrics.
DeferBrowserMetrics(user_data_dir);
@ -40,7 +40,7 @@ index d60a195d58a27..df74bb2c60264 100644
// In the case the process is not the singleton process, the uninstall tasks
// need to be executed here. A window will be displayed asking to close all
// running instances.
@@ -1038,7 +1046,8 @@ std::optional<int> ChromeMainDelegate::PostEarlyInitialization(
@@ -1040,7 +1048,8 @@ std::optional<int> ChromeMainDelegate::PostEarlyInitialization(
// Initializes the resource bundle and determines the locale.
std::string actual_locale = LoadLocalState(
@ -50,7 +50,7 @@ index d60a195d58a27..df74bb2c60264 100644
chrome_feature_list_creator->SetApplicationLocale(actual_locale);
chrome_feature_list_creator->OverrideCachedUIStrings();
@@ -1057,7 +1066,8 @@ std::optional<int> ChromeMainDelegate::PostEarlyInitialization(
@@ -1059,7 +1068,8 @@ std::optional<int> ChromeMainDelegate::PostEarlyInitialization(
if (base::FeatureList::IsEnabled(
features::kWriteBasicSystemProfileToPersistentHistogramsFile)) {
@ -60,7 +60,7 @@ index d60a195d58a27..df74bb2c60264 100644
#if BUILDFLAG(IS_ANDROID)
record =
base::FeatureList::IsEnabled(chrome::android::kUmaBackgroundSessions);
@@ -1502,6 +1512,7 @@ void ChromeMainDelegate::PreSandboxStartup() {
@@ -1506,6 +1516,7 @@ void ChromeMainDelegate::PreSandboxStartup() {
std::string process_type =
command_line.GetSwitchValueASCII(switches::kProcessType);
@ -68,7 +68,7 @@ index d60a195d58a27..df74bb2c60264 100644
crash_reporter::InitializeCrashKeys();
#if BUILDFLAG(IS_POSIX)
@@ -1512,6 +1523,7 @@ void ChromeMainDelegate::PreSandboxStartup() {
@@ -1516,6 +1527,7 @@ void ChromeMainDelegate::PreSandboxStartup() {
InitMacCrashReporter(command_line, process_type);
SetUpInstallerPreferences(command_line);
#endif
@ -76,7 +76,7 @@ index d60a195d58a27..df74bb2c60264 100644
#if BUILDFLAG(IS_WIN)
child_process_logging::Init();
@@ -1692,7 +1704,8 @@ void ChromeMainDelegate::PreSandboxStartup() {
@@ -1696,7 +1708,8 @@ void ChromeMainDelegate::PreSandboxStartup() {
#else
const std::string loaded_locale =
ui::ResourceBundle::InitSharedInstanceWithLocale(
@ -86,7 +86,7 @@ index d60a195d58a27..df74bb2c60264 100644
base::FilePath resources_pack_path;
base::PathService::Get(chrome::FILE_RESOURCES_PACK, &resources_pack_path);
@@ -1722,6 +1735,7 @@ void ChromeMainDelegate::PreSandboxStartup() {
@@ -1726,6 +1739,7 @@ void ChromeMainDelegate::PreSandboxStartup() {
CHECK(!loaded_locale.empty()) << "Locale could not be found for " << locale;
}
@ -94,7 +94,7 @@ index d60a195d58a27..df74bb2c60264 100644
#if BUILDFLAG(IS_POSIX) && !BUILDFLAG(IS_MAC)
// Zygote needs to call InitCrashReporter() in RunZygote().
if (process_type != switches::kZygoteProcess) {
@@ -1757,6 +1771,7 @@ void ChromeMainDelegate::PreSandboxStartup() {
@@ -1761,6 +1775,7 @@ void ChromeMainDelegate::PreSandboxStartup() {
// After all the platform Breakpads have been initialized, store the command
// line for crash reporting.
crash_keys::SetCrashKeysFromCommandLine(command_line);
@ -102,7 +102,7 @@ index d60a195d58a27..df74bb2c60264 100644
#if BUILDFLAG(ENABLE_PDF)
MaybePatchGdiGetFontData();
@@ -1880,6 +1895,7 @@ void ChromeMainDelegate::ZygoteForked() {
@@ -1888,6 +1903,7 @@ void ChromeMainDelegate::ZygoteForked() {
SetUpProfilingShutdownHandler();
}
@ -110,7 +110,7 @@ index d60a195d58a27..df74bb2c60264 100644
// Needs to be called after we have chrome::DIR_USER_DATA. BrowserMain sets
// this up for the browser process in a different manner.
const base::CommandLine* command_line =
@@ -1892,6 +1908,7 @@ void ChromeMainDelegate::ZygoteForked() {
@@ -1900,6 +1916,7 @@ void ChromeMainDelegate::ZygoteForked() {
// Reset the command line for the newly spawned process.
crash_keys::SetCrashKeysFromCommandLine(*command_line);
@ -118,7 +118,7 @@ index d60a195d58a27..df74bb2c60264 100644
}
#endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)
@@ -1994,6 +2011,7 @@ void ChromeMainDelegate::InitializeMemorySystem() {
@@ -2002,6 +2019,7 @@ void ChromeMainDelegate::InitializeMemorySystem() {
: memory_system::DispatcherParameters::
AllocationTraceRecorderInclusion::kIgnore;
@ -126,7 +126,7 @@ index d60a195d58a27..df74bb2c60264 100644
memory_system::Initializer()
.SetGwpAsanParameters(gwp_asan_boost_sampling, process_type)
.SetProfilingClientParameters(chrome::GetChannel(),
@@ -2001,5 +2019,5 @@ void ChromeMainDelegate::InitializeMemorySystem() {
@@ -2009,5 +2027,5 @@ void ChromeMainDelegate::InitializeMemorySystem() {
.SetDispatcherParameters(memory_system::DispatcherParameters::
PoissonAllocationSamplerInclusion::kEnforce,
allocation_recorder_inclusion, process_type)
@ -174,7 +174,7 @@ index 3553377e96017..9f6edc70ef1d4 100644
#if BUILDFLAG(IS_CHROMEOS_LACROS)
std::unique_ptr<chromeos::LacrosService> lacros_service_;
diff --git chrome/browser/chrome_browser_main.cc chrome/browser/chrome_browser_main.cc
index d6c9d21a0d4d3..9e0673a150d40 100644
index f90f1b8fa54d9..3dc8a9fe49363 100644
--- chrome/browser/chrome_browser_main.cc
+++ chrome/browser/chrome_browser_main.cc
@@ -52,6 +52,7 @@
@ -194,7 +194,7 @@ index d6c9d21a0d4d3..9e0673a150d40 100644
// The uninstall command-line switch is handled by the origin process; see
// ChromeMainDelegate::PostEarlyInitialization(...). The other process won't
// be able to become the singleton process and will display a window asking
@@ -832,7 +833,7 @@ int ChromeBrowserMainParts::PreEarlyInitialization() {
@@ -833,7 +834,7 @@ int ChromeBrowserMainParts::PreEarlyInitialization() {
return content::RESULT_CODE_NORMAL_EXIT;
}
@ -203,7 +203,7 @@ index d6c9d21a0d4d3..9e0673a150d40 100644
// If we are running stale binaries then relaunch and exit immediately.
if (upgrade_util::IsRunningOldChrome()) {
if (!upgrade_util::RelaunchChromeBrowser(
@@ -845,7 +846,7 @@ int ChromeBrowserMainParts::PreEarlyInitialization() {
@@ -846,7 +847,7 @@ int ChromeBrowserMainParts::PreEarlyInitialization() {
// result in browser startup bailing.
return chrome::RESULT_CODE_NORMAL_EXIT_UPGRADE_RELAUNCHED;
}
@ -212,7 +212,7 @@ index d6c9d21a0d4d3..9e0673a150d40 100644
return load_local_state_result;
}
@@ -951,7 +952,7 @@ int ChromeBrowserMainParts::OnLocalStateLoaded(
@@ -952,7 +953,7 @@ int ChromeBrowserMainParts::OnLocalStateLoaded(
browser_process_->local_state());
platform_management_service->RefreshCache(base::NullCallback());
@ -221,7 +221,7 @@ index d6c9d21a0d4d3..9e0673a150d40 100644
if (first_run::IsChromeFirstRun()) {
bool stats_default;
if (GoogleUpdateSettings::GetCollectStatsConsentDefault(&stats_default)) {
@@ -964,7 +965,7 @@ int ChromeBrowserMainParts::OnLocalStateLoaded(
@@ -965,7 +966,7 @@ int ChromeBrowserMainParts::OnLocalStateLoaded(
: metrics::EnableMetricsDefault::OPT_IN);
}
}
@ -230,7 +230,7 @@ index d6c9d21a0d4d3..9e0673a150d40 100644
std::string locale =
startup_data_->chrome_feature_list_creator()->actual_locale();
@@ -997,6 +998,7 @@ int ChromeBrowserMainParts::ApplyFirstRunPrefs() {
@@ -998,6 +999,7 @@ int ChromeBrowserMainParts::ApplyFirstRunPrefs() {
#if !BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_CHROMEOS_ASH)
master_prefs_ = std::make_unique<first_run::MasterPrefs>();
@ -238,7 +238,7 @@ index d6c9d21a0d4d3..9e0673a150d40 100644
std::unique_ptr<installer::InitialPreferences> installer_initial_prefs =
startup_data_->chrome_feature_list_creator()->TakeInitialPrefs();
if (!installer_initial_prefs)
@@ -1030,6 +1032,7 @@ int ChromeBrowserMainParts::ApplyFirstRunPrefs() {
@@ -1031,6 +1033,7 @@ int ChromeBrowserMainParts::ApplyFirstRunPrefs() {
master_prefs_->confirm_to_quit);
}
#endif // BUILDFLAG(IS_MAC)
@ -246,7 +246,7 @@ index d6c9d21a0d4d3..9e0673a150d40 100644
#endif // !BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_CHROMEOS_ASH)
return content::RESULT_CODE_NORMAL_EXIT;
}
@@ -1091,6 +1094,7 @@ int ChromeBrowserMainParts::PreCreateThreadsImpl() {
@@ -1092,6 +1095,7 @@ int ChromeBrowserMainParts::PreCreateThreadsImpl() {
browser_process_->browser_policy_connector()->OnResourceBundleCreated();
@ -254,7 +254,7 @@ index d6c9d21a0d4d3..9e0673a150d40 100644
// Android does first run in Java instead of native.
// Chrome OS has its own out-of-box-experience code.
#if !BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_CHROMEOS_ASH)
@@ -1112,6 +1116,7 @@ int ChromeBrowserMainParts::PreCreateThreadsImpl() {
@@ -1113,6 +1117,7 @@ int ChromeBrowserMainParts::PreCreateThreadsImpl() {
#endif // BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)
}
#endif // !BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_CHROMEOS_ASH)
@ -262,7 +262,7 @@ index d6c9d21a0d4d3..9e0673a150d40 100644
#if BUILDFLAG(IS_MAC)
#if defined(ARCH_CPU_X86_64)
@@ -1470,6 +1475,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
@@ -1473,6 +1478,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
browser_process_->PreMainMessageLoopRun();
#if BUILDFLAG(IS_WIN)
@ -270,7 +270,7 @@ index d6c9d21a0d4d3..9e0673a150d40 100644
// If the command line specifies 'uninstall' then we need to work here
// unless we detect another chrome browser running.
if (base::CommandLine::ForCurrentProcess()->HasSwitch(switches::kUninstall)) {
@@ -1481,6 +1487,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
@@ -1484,6 +1490,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
return ChromeBrowserMainPartsWin::HandleIconsCommands(
*base::CommandLine::ForCurrentProcess());
}
@ -278,7 +278,7 @@ index d6c9d21a0d4d3..9e0673a150d40 100644
ui::SelectFileDialog::SetFactory(
std::make_unique<ChromeSelectFileDialogFactory>());
@@ -1506,6 +1513,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
@@ -1509,6 +1516,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
}
#endif // BUILDFLAG(CHROME_FOR_TESTING)
@ -286,7 +286,7 @@ index d6c9d21a0d4d3..9e0673a150d40 100644
if (base::CommandLine::ForCurrentProcess()->HasSwitch(
switches::kMakeDefaultBrowser)) {
bool is_managed = g_browser_process->local_state()->IsManagedPreference(
@@ -1519,18 +1527,22 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
@@ -1522,18 +1530,22 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
? static_cast<int>(content::RESULT_CODE_NORMAL_EXIT)
: static_cast<int>(chrome::RESULT_CODE_SHELL_INTEGRATION_FAILED);
}
@ -309,7 +309,7 @@ index d6c9d21a0d4d3..9e0673a150d40 100644
#if !BUILDFLAG(IS_ANDROID) && BUILDFLAG(ENABLE_DOWNGRADE_PROCESSING)
// Begin relaunch processing immediately if User Data migration is required
@@ -1569,7 +1581,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
@@ -1572,7 +1584,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
}
#endif // !BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_CHROMEOS)
@ -318,7 +318,7 @@ index d6c9d21a0d4d3..9e0673a150d40 100644
// Check if there is any machine level Chrome installed on the current
// machine. If yes and the current Chrome process is user level, we do not
// allow the user level Chrome to run. So we notify the user and uninstall
@@ -1578,7 +1590,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
@@ -1581,7 +1593,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
// obtained but before potentially creating the first run sentinel).
if (ChromeBrowserMainPartsWin::CheckMachineLevelInstall())
return chrome::RESULT_CODE_MACHINE_LEVEL_INSTALL_EXISTS;
@ -327,7 +327,7 @@ index d6c9d21a0d4d3..9e0673a150d40 100644
// Desktop construction occurs here, (required before profile creation).
PreProfileInit();
@@ -1621,12 +1633,14 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
@@ -1624,12 +1636,14 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
browser_process_->local_state());
}
@ -342,7 +342,7 @@ index d6c9d21a0d4d3..9e0673a150d40 100644
#if BUILDFLAG(IS_ANDROID)
page_info::SetPageInfoClient(new ChromePageInfoClient());
@@ -1653,6 +1667,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
@@ -1656,6 +1670,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
// Call `PostProfileInit()`and set it up for profiles created later.
profile_init_manager_ = std::make_unique<ProfileInitManager>(this, profile);
@ -350,7 +350,7 @@ index d6c9d21a0d4d3..9e0673a150d40 100644
#if !BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_CHROMEOS_ASH)
// Execute first run specific code after the PrefService has been initialized
// and preferences have been registered since some of the import code depends
@@ -1692,6 +1707,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
@@ -1695,6 +1710,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
*base::CommandLine::ForCurrentProcess());
}
#endif // BUILDFLAG(IS_WIN)
@ -358,7 +358,7 @@ index d6c9d21a0d4d3..9e0673a150d40 100644
// Configure modules that need access to resources.
net::NetModule::SetResourceProvider(ChromeNetResourceProvider);
@@ -1783,6 +1799,11 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
@@ -1786,6 +1802,11 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
g_browser_process->profile_manager()->GetLastOpenedProfiles();
}
#endif // BUILDFLAG(IS_CHROMEOS_ASH)
@ -370,7 +370,7 @@ index d6c9d21a0d4d3..9e0673a150d40 100644
// This step is costly.
if (browser_creator_->Start(*base::CommandLine::ForCurrentProcess(),
base::FilePath(), profile_info,
@@ -1815,11 +1836,14 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
@@ -1818,11 +1839,14 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
// Create the RunLoop for MainMessageLoopRun() to use and transfer
// ownership of the browser's lifetime to the BrowserProcess.
@ -386,10 +386,10 @@ index d6c9d21a0d4d3..9e0673a150d40 100644
#endif // !BUILDFLAG(IS_ANDROID)
diff --git chrome/browser/chrome_browser_main_mac.mm chrome/browser/chrome_browser_main_mac.mm
index 3c12614c4d7d2..1dc97ecf5a11e 100644
index 6b27cf7037fce..70fd49bb873ff 100644
--- chrome/browser/chrome_browser_main_mac.mm
+++ chrome/browser/chrome_browser_main_mac.mm
@@ -18,6 +18,7 @@
@@ -20,6 +20,7 @@
#include "base/path_service.h"
#include "base/strings/sys_string_conversions.h"
#include "build/branding_buildflags.h"
@ -397,7 +397,7 @@ index 3c12614c4d7d2..1dc97ecf5a11e 100644
#import "chrome/browser/app_controller_mac.h"
#include "chrome/browser/apps/app_shim/app_shim_listener.h"
#include "chrome/browser/browser_process.h"
@@ -106,6 +107,7 @@ void ChromeBrowserMainPartsMac::PreCreateMainMessageLoop() {
@@ -120,6 +121,7 @@ void ChromeBrowserMainPartsMac::PreCreateMainMessageLoop() {
}
#endif // !BUILDFLAG(CHROME_FOR_TESTING)
@ -405,7 +405,7 @@ index 3c12614c4d7d2..1dc97ecf5a11e 100644
// Create the app delegate by requesting the shared AppController.
CHECK_EQ(nil, NSApp.delegate);
AppController* app_controller = AppController.sharedController;
@@ -114,6 +116,7 @@ void ChromeBrowserMainPartsMac::PreCreateMainMessageLoop() {
@@ -128,6 +130,7 @@ void ChromeBrowserMainPartsMac::PreCreateMainMessageLoop() {
chrome::BuildMainMenu(NSApp, app_controller,
l10n_util::GetStringUTF16(IDS_PRODUCT_NAME), false);
[app_controller mainMenuCreated];
@ -413,7 +413,7 @@ index 3c12614c4d7d2..1dc97ecf5a11e 100644
ui::WarmScreenCapture();
@@ -154,5 +157,7 @@ void ChromeBrowserMainPartsMac::PostProfileInit(Profile* profile,
@@ -168,5 +171,7 @@ void ChromeBrowserMainPartsMac::PostProfileInit(Profile* profile,
}
void ChromeBrowserMainPartsMac::DidEndMainMessageLoop() {
@ -422,7 +422,7 @@ index 3c12614c4d7d2..1dc97ecf5a11e 100644
+#endif
}
diff --git chrome/browser/chrome_content_browser_client.cc chrome/browser/chrome_content_browser_client.cc
index 675a9ab64ea08..d0c160a14b2a7 100644
index d81a2b75f4c6c..4c29ef42b4576 100644
--- chrome/browser/chrome_content_browser_client.cc
+++ chrome/browser/chrome_content_browser_client.cc
@@ -46,6 +46,7 @@
@ -431,9 +431,9 @@ index 675a9ab64ea08..d0c160a14b2a7 100644
#include "build/config/chromebox_for_meetings/buildflags.h" // PLATFORM_CFM
+#include "cef/libcef/features/features.h"
#include "chrome/browser/after_startup_task_utils.h"
#include "chrome/browser/ai/ai_manager_impl.h"
#include "chrome/browser/app_mode/app_mode_utils.h"
#include "chrome/browser/bluetooth/chrome_bluetooth_delegate_impl_client.h"
@@ -1467,6 +1468,8 @@ ChromeContentBrowserClient::GetPopupNavigationDelegateFactoryForTesting() {
@@ -1486,6 +1487,8 @@ ChromeContentBrowserClient::GetPopupNavigationDelegateFactoryForTesting() {
}
ChromeContentBrowserClient::ChromeContentBrowserClient() {
@ -442,7 +442,7 @@ index 675a9ab64ea08..d0c160a14b2a7 100644
#if BUILDFLAG(ENABLE_PLUGINS)
extra_parts_.push_back(
std::make_unique<ChromeContentBrowserClientPluginsPart>());
@@ -1504,6 +1507,11 @@ ChromeContentBrowserClient::~ChromeContentBrowserClient() {
@@ -1523,6 +1526,11 @@ ChromeContentBrowserClient::~ChromeContentBrowserClient() {
}
}
@ -454,7 +454,7 @@ index 675a9ab64ea08..d0c160a14b2a7 100644
// static
void ChromeContentBrowserClient::RegisterLocalStatePrefs(
PrefRegistrySimple* registry) {
@@ -3707,28 +3715,25 @@ bool UpdatePreferredColorScheme(WebPreferences* web_prefs,
@@ -3744,28 +3752,25 @@ bool UpdatePreferredColorScheme(WebPreferences* web_prefs,
web_prefs->preferred_color_scheme;
}
#else
@ -500,7 +500,7 @@ index 675a9ab64ea08..d0c160a14b2a7 100644
#endif // BUILDFLAG(IS_ANDROID)
// Reauth WebUI doesn't support dark mode yet because it shares the dialog
@@ -4471,9 +4476,11 @@ void ChromeContentBrowserClient::BrowserURLHandlerCreated(
@@ -4506,9 +4511,11 @@ void ChromeContentBrowserClient::BrowserURLHandlerCreated(
&search::HandleNewTabURLReverseRewrite);
#endif // BUILDFLAG(IS_ANDROID)
@ -512,7 +512,7 @@ index 675a9ab64ea08..d0c160a14b2a7 100644
}
base::FilePath ChromeContentBrowserClient::GetDefaultDownloadDirectory() {
@@ -6592,7 +6599,7 @@ void ChromeContentBrowserClient::OnNetworkServiceCreated(
@@ -6627,7 +6634,7 @@ void ChromeContentBrowserClient::OnNetworkServiceCreated(
#endif
}
@ -521,7 +521,7 @@ index 675a9ab64ea08..d0c160a14b2a7 100644
content::BrowserContext* context,
bool in_memory,
const base::FilePath& relative_partition_path,
@@ -6610,6 +6617,8 @@ void ChromeContentBrowserClient::ConfigureNetworkContextParams(
@@ -6645,6 +6652,8 @@ void ChromeContentBrowserClient::ConfigureNetworkContextParams(
network_context_params->user_agent = GetUserAgentBasedOnPolicy(context);
network_context_params->accept_language = GetApplicationLocale();
}
@ -530,7 +530,7 @@ index 675a9ab64ea08..d0c160a14b2a7 100644
}
std::vector<base::FilePath>
@@ -7732,10 +7741,10 @@ void ChromeContentBrowserClient::OnKeepaliveRequestStarted(
@@ -7767,10 +7776,10 @@ void ChromeContentBrowserClient::OnKeepaliveRequestStarted(
const auto now = base::TimeTicks::Now();
const auto timeout = GetKeepaliveTimerTimeout(context);
keepalive_deadline_ = std::max(keepalive_deadline_, now + timeout);
@ -543,7 +543,7 @@ index 675a9ab64ea08..d0c160a14b2a7 100644
FROM_HERE, keepalive_deadline_ - now,
base::BindOnce(
&ChromeContentBrowserClient::OnKeepaliveTimerFired,
@@ -7754,7 +7763,8 @@ void ChromeContentBrowserClient::OnKeepaliveRequestFinished() {
@@ -7789,7 +7798,8 @@ void ChromeContentBrowserClient::OnKeepaliveRequestFinished() {
--num_keepalive_requests_;
if (num_keepalive_requests_ == 0) {
DVLOG(1) << "Stopping the keepalive timer";
@ -553,7 +553,7 @@ index 675a9ab64ea08..d0c160a14b2a7 100644
// This deletes the keep alive handle attached to the timer function and
// unblock the shutdown sequence.
}
@@ -7923,7 +7933,7 @@ void ChromeContentBrowserClient::OnKeepaliveTimerFired(
@@ -7968,7 +7978,7 @@ void ChromeContentBrowserClient::OnKeepaliveTimerFired(
const auto now = base::TimeTicks::Now();
const auto then = keepalive_deadline_;
if (now < then) {
@ -563,10 +563,10 @@ index 675a9ab64ea08..d0c160a14b2a7 100644
base::BindOnce(&ChromeContentBrowserClient::OnKeepaliveTimerFired,
weak_factory_.GetWeakPtr(),
diff --git chrome/browser/chrome_content_browser_client.h chrome/browser/chrome_content_browser_client.h
index 6c9208d7b7907..77f049cc7483c 100644
index 522c072575325..b63e9aacd1f0a 100644
--- chrome/browser/chrome_content_browser_client.h
+++ chrome/browser/chrome_content_browser_client.h
@@ -146,6 +146,8 @@ class ChromeContentBrowserClient : public content::ContentBrowserClient {
@@ -147,6 +147,8 @@ class ChromeContentBrowserClient : public content::ContentBrowserClient {
~ChromeContentBrowserClient() override;
@ -575,7 +575,7 @@ index 6c9208d7b7907..77f049cc7483c 100644
// TODO(crbug.com/41356866): This file is about calls from content/ out
// to chrome/ to get values or notify about events, but both of these
// functions are from chrome/ to chrome/ and don't involve content/ at all.
@@ -686,7 +688,7 @@ class ChromeContentBrowserClient : public content::ContentBrowserClient {
@@ -691,7 +693,7 @@ class ChromeContentBrowserClient : public content::ContentBrowserClient {
override;
void OnNetworkServiceCreated(
network::mojom::NetworkService* network_service) override;
@ -584,7 +584,7 @@ index 6c9208d7b7907..77f049cc7483c 100644
content::BrowserContext* context,
bool in_memory,
const base::FilePath& relative_partition_path,
@@ -1213,7 +1215,7 @@ class ChromeContentBrowserClient : public content::ContentBrowserClient {
@@ -1233,7 +1235,7 @@ class ChromeContentBrowserClient : public content::ContentBrowserClient {
#if !BUILDFLAG(IS_ANDROID)
uint64_t num_keepalive_requests_ = 0;
@ -594,7 +594,7 @@ index 6c9208d7b7907..77f049cc7483c 100644
#endif
diff --git chrome/browser/prefs/browser_prefs.cc chrome/browser/prefs/browser_prefs.cc
index 750d634f641b1..86220ec515c0c 100644
index 7c9cd6b688f88..f66aa28081c37 100644
--- chrome/browser/prefs/browser_prefs.cc
+++ chrome/browser/prefs/browser_prefs.cc
@@ -16,6 +16,7 @@
@ -605,7 +605,7 @@ index 750d634f641b1..86220ec515c0c 100644
#include "chrome/browser/about_flags.h"
#include "chrome/browser/accessibility/accessibility_labels_service.h"
#include "chrome/browser/accessibility/invert_bubble_prefs.h"
@@ -197,6 +198,10 @@
@@ -198,6 +199,10 @@
#include "chrome/browser/background/background_mode_manager.h"
#endif
@ -616,7 +616,7 @@ index 750d634f641b1..86220ec515c0c 100644
#if BUILDFLAG(ENABLE_EXTENSIONS)
#include "chrome/browser/accessibility/animation_policy_prefs.h"
#include "chrome/browser/apps/platform_apps/shortcut_manager.h"
@@ -1820,7 +1825,8 @@ void RegisterLocalState(PrefRegistrySimple* registry) {
@@ -1917,7 +1922,8 @@ void RegisterLocalState(PrefRegistrySimple* registry) {
#endif // BUILDFLAG(GOOGLE_CHROME_BRANDING)
#endif // BUILDFLAG(IS_WIN)
@ -626,7 +626,7 @@ index 750d634f641b1..86220ec515c0c 100644
downgrade::RegisterPrefs(registry);
#endif
@@ -1864,6 +1870,11 @@ void RegisterLocalState(PrefRegistrySimple* registry) {
@@ -1961,6 +1967,11 @@ void RegisterLocalState(PrefRegistrySimple* registry) {
// This is intentionally last.
RegisterLocalStatePrefsForMigration(registry);
@ -638,7 +638,7 @@ index 750d634f641b1..86220ec515c0c 100644
}
// Register prefs applicable to all profiles.
@@ -2317,6 +2328,10 @@ void RegisterUserProfilePrefs(user_prefs::PrefRegistrySyncable* registry,
@@ -2411,6 +2422,10 @@ void RegisterUserProfilePrefs(user_prefs::PrefRegistrySyncable* registry,
const std::string& locale) {
RegisterProfilePrefs(registry, locale);

View File

@ -1,8 +1,8 @@
diff --git chrome/browser/ui/browser_command_controller.cc chrome/browser/ui/browser_command_controller.cc
index 3b992709445b9..822de797dcb3e 100644
index e70c1340dd2ee..745b3982aa9ad 100644
--- chrome/browser/ui/browser_command_controller.cc
+++ chrome/browser/ui/browser_command_controller.cc
@@ -406,6 +406,7 @@ bool BrowserCommandController::ExecuteCommandWithDisposition(
@@ -411,6 +411,7 @@ bool BrowserCommandController::ExecuteCommandWithDisposition(
// choose to not implement CommandUpdaterDelegate inside this class and
// therefore command_updater_ doesn't have the delegate set).
if (!SupportsCommand(id) || !IsCommandEnabled(id)) {
@ -10,7 +10,7 @@ index 3b992709445b9..822de797dcb3e 100644
return false;
}
@@ -422,6 +423,13 @@ bool BrowserCommandController::ExecuteCommandWithDisposition(
@@ -427,6 +428,13 @@ bool BrowserCommandController::ExecuteCommandWithDisposition(
DCHECK(command_updater_.IsCommandEnabled(id))
<< "Invalid/disabled command " << id;
@ -24,7 +24,7 @@ index 3b992709445b9..822de797dcb3e 100644
// The order of commands in this switch statement must match the function
// declaration order in browser.h!
switch (id) {
@@ -1207,11 +1215,13 @@ void BrowserCommandController::TabRestoreServiceLoaded(
@@ -1215,11 +1223,13 @@ void BrowserCommandController::TabRestoreServiceLoaded(
// BrowserCommandController, private:
bool BrowserCommandController::IsShowingMainUI() {
@ -41,10 +41,23 @@ index 3b992709445b9..822de797dcb3e 100644
bool BrowserCommandController::IsWebAppOrCustomTab() const {
diff --git chrome/browser/ui/toolbar/app_menu_model.cc chrome/browser/ui/toolbar/app_menu_model.cc
index dca26d57b903d..3de463129b7ac 100644
index 2a1eb7cd0a644..b3e95b92b2951 100644
--- chrome/browser/ui/toolbar/app_menu_model.cc
+++ chrome/browser/ui/toolbar/app_menu_model.cc
@@ -739,6 +739,57 @@ SaveAndShareSubMenuModel::SaveAndShareSubMenuModel(
@@ -658,10 +658,12 @@ FindAndEditSubMenuModel::FindAndEditSubMenuModel(
ui::SimpleMenuModel::Delegate* delegate)
: SimpleMenuModel(delegate) {
AddItemWithStringIdAndVectorIcon(this, IDC_FIND, IDS_FIND, kSearchMenuIcon);
+ if (delegate->IsCommandIdVisible(IDC_EDIT_MENU)) {
AddSeparator(ui::NORMAL_SEPARATOR);
AddItemWithStringIdAndVectorIcon(this, IDC_CUT, IDS_CUT, kCutMenuIcon);
AddItemWithStringIdAndVectorIcon(this, IDC_COPY, IDS_COPY, kCopyMenuIcon);
AddItemWithStringIdAndVectorIcon(this, IDC_PASTE, IDS_PASTE, kPasteMenuIcon);
+ }
}
class SaveAndShareSubMenuModel : public ui::SimpleMenuModel {
@@ -736,6 +738,57 @@ SaveAndShareSubMenuModel::SaveAndShareSubMenuModel(
}
}
@ -102,7 +115,7 @@ index dca26d57b903d..3de463129b7ac 100644
} // namespace
////////////////////////////////////////////////////////////////////////////////
@@ -1583,7 +1634,7 @@ bool AppMenuModel::IsCommandIdChecked(int command_id) const {
@@ -1596,7 +1649,7 @@ bool AppMenuModel::IsCommandIdChecked(int command_id) const {
return false;
}
@ -111,7 +124,7 @@ index dca26d57b903d..3de463129b7ac 100644
GlobalError* error =
GlobalErrorServiceFactory::GetForProfile(browser_->profile())
->GetGlobalErrorByMenuItemCommandID(command_id);
@@ -1598,6 +1649,30 @@ bool AppMenuModel::IsCommandIdEnabled(int command_id) const {
@@ -1611,6 +1664,30 @@ bool AppMenuModel::IsCommandIdEnabled(int command_id) const {
}
}
@ -142,7 +155,7 @@ index dca26d57b903d..3de463129b7ac 100644
bool AppMenuModel::IsCommandIdAlerted(int command_id) const {
if (command_id == IDC_VIEW_PASSWORDS ||
command_id == IDC_SHOW_PASSWORD_MANAGER) {
@@ -1763,8 +1838,10 @@ void AppMenuModel::Build() {
@@ -1773,8 +1850,10 @@ void AppMenuModel::Build() {
IDS_CLEAR_BROWSING_DATA,
kTrashCanRefreshIcon);
@ -153,7 +166,7 @@ index dca26d57b903d..3de463129b7ac 100644
AddSeparator(ui::NORMAL_SEPARATOR);
AddItemWithStringIdAndVectorIcon(this, IDC_PRINT, IDS_PRINT, kPrintMenuIcon);
@@ -1883,6 +1960,11 @@ void AppMenuModel::Build() {
@@ -1896,6 +1975,11 @@ void AppMenuModel::Build() {
}
#endif // !BUILDFLAG(IS_CHROMEOS_ASH)
@ -166,10 +179,10 @@ index dca26d57b903d..3de463129b7ac 100644
}
diff --git chrome/browser/ui/toolbar/app_menu_model.h chrome/browser/ui/toolbar/app_menu_model.h
index 0824a0b655cde..507021a7c1b66 100644
index ada5cc02223d4..37da48f2e5412 100644
--- chrome/browser/ui/toolbar/app_menu_model.h
+++ chrome/browser/ui/toolbar/app_menu_model.h
@@ -225,6 +225,7 @@ class AppMenuModel : public ui::SimpleMenuModel,
@@ -232,6 +232,7 @@ class AppMenuModel : public ui::SimpleMenuModel,
void ExecuteCommand(int command_id, int event_flags) override;
bool IsCommandIdChecked(int command_id) const override;
bool IsCommandIdEnabled(int command_id) const override;
@ -177,7 +190,7 @@ index 0824a0b655cde..507021a7c1b66 100644
bool IsCommandIdAlerted(int command_id) const override;
bool IsElementIdAlerted(ui::ElementIdentifier element_id) const override;
bool GetAcceleratorForCommandId(int command_id,
@@ -265,6 +266,8 @@ class AppMenuModel : public ui::SimpleMenuModel,
@@ -272,6 +273,8 @@ class AppMenuModel : public ui::SimpleMenuModel,
void LogSafetyHubInteractionMetrics(safety_hub::SafetyHubModuleType sh_module,
int event_flags);
@ -187,10 +200,10 @@ index 0824a0b655cde..507021a7c1b66 100644
// Adds actionable global error menu items to the menu.
// Examples: Extension permissions and sign in errors.
diff --git chrome/browser/ui/views/find_bar_host.cc chrome/browser/ui/views/find_bar_host.cc
index 0ccfe39eb5696..c9424316b6d14 100644
index 86fad4ad36024..8ca6f3e0eb42f 100644
--- chrome/browser/ui/views/find_bar_host.cc
+++ chrome/browser/ui/views/find_bar_host.cc
@@ -581,6 +581,14 @@ gfx::Rect FindBarHost::GetDialogPosition(gfx::Rect avoid_overlapping_rect) {
@@ -583,6 +583,14 @@ gfx::Rect FindBarHost::GetDialogPosition(gfx::Rect avoid_overlapping_rect) {
// The BrowserView does Layout for the components that we care about
// positioning relative to, so we ask it to tell us where we should go.
gfx::Rect find_bar_bounds = browser_view_->GetFindBarBoundingBox();
@ -206,7 +219,7 @@ index 0ccfe39eb5696..c9424316b6d14 100644
return gfx::Rect();
}
diff --git chrome/browser/ui/views/frame/browser_frame.cc chrome/browser/ui/views/frame/browser_frame.cc
index 8dd3620ba2720..bb69a77f9551e 100644
index 19343898d78d9..9b974442606b4 100644
--- chrome/browser/ui/views/frame/browser_frame.cc
+++ chrome/browser/ui/views/frame/browser_frame.cc
@@ -114,15 +114,25 @@ ui::ColorProviderKey::SchemeVariant GetSchemeVariant(
@ -279,14 +292,14 @@ index 8dd3620ba2720..bb69a77f9551e 100644
}
content::KeyboardEventProcessingResult BrowserFrame::PreHandleKeyboardEvent(
const content::NativeWebKeyboardEvent& event) {
const input::NativeWebKeyboardEvent& event) {
+ if (!native_browser_frame_)
+ return content::KeyboardEventProcessingResult::NOT_HANDLED;
return native_browser_frame_->PreHandleKeyboardEvent(event);
}
bool BrowserFrame::HandleKeyboardEvent(
const content::NativeWebKeyboardEvent& event) {
const input::NativeWebKeyboardEvent& event) {
+ if (!native_browser_frame_)
+ return false;
return native_browser_frame_->HandleKeyboardEvent(event);
@ -331,7 +344,7 @@ index 8dd3620ba2720..bb69a77f9551e 100644
return browser_view_->browser()->profile()->IsIncognitoProfile();
}
diff --git chrome/browser/ui/views/frame/browser_frame.h chrome/browser/ui/views/frame/browser_frame.h
index 2e973c9e279b0..07d04a364d60c 100644
index 14a8a70d853f6..bf81594947886 100644
--- chrome/browser/ui/views/frame/browser_frame.h
+++ chrome/browser/ui/views/frame/browser_frame.h
@@ -58,6 +58,7 @@ enum class TabDragKind {
@ -384,11 +397,11 @@ index 2e973c9e279b0..07d04a364d60c 100644
// regenerated.
bool RegenerateFrameOnThemeChange(BrowserThemeChangeType theme_change_type);
diff --git chrome/browser/ui/views/frame/browser_view.cc chrome/browser/ui/views/frame/browser_view.cc
index 4b52ce3877855..7dae2a6b1b151 100644
index 1142fec7a138c..71e381f04adcc 100644
--- chrome/browser/ui/views/frame/browser_view.cc
+++ chrome/browser/ui/views/frame/browser_view.cc
@@ -353,11 +353,10 @@ using content::NativeWebKeyboardEvent;
using content::WebContents;
@@ -350,11 +350,10 @@ using content::WebContents;
using input::NativeWebKeyboardEvent;
using web_modal::WebContentsModalDialogHost;
-namespace {
@ -402,7 +415,7 @@ index 4b52ce3877855..7dae2a6b1b151 100644
#if BUILDFLAG(IS_CHROMEOS_ASH)
// UMA histograms that record animation smoothness for tab loading animation.
@@ -690,6 +689,14 @@ class BrowserViewLayoutDelegateImpl : public BrowserViewLayoutDelegate {
@@ -694,6 +693,14 @@ class BrowserViewLayoutDelegateImpl : public BrowserViewLayoutDelegate {
return browser_view_->frame()->GetTopInset() - browser_view_->y();
}
@ -417,7 +430,7 @@ index 4b52ce3877855..7dae2a6b1b151 100644
bool IsToolbarVisible() const override {
return browser_view_->IsToolbarVisible();
}
@@ -841,11 +848,21 @@ class BrowserView::AccessibilityModeObserver : public ui::AXModeObserver {
@@ -845,11 +852,21 @@ class BrowserView::AccessibilityModeObserver : public ui::AXModeObserver {
///////////////////////////////////////////////////////////////////////////////
// BrowserView, public:
@ -437,10 +450,10 @@ index 4b52ce3877855..7dae2a6b1b151 100644
+ DCHECK(!browser_);
+ browser_ = std::move(browser);
+
// Store the actions so that the access is available for other classes.
if (features::IsSidePanelPinningEnabled()) {
browser_->SetUserData(BrowserActions::UserDataKey(),
@@ -946,8 +963,15 @@ BrowserView::BrowserView(std::unique_ptr<Browser> browser)
SetShowIcon(
::ShouldShowWindowIcon(browser_.get(), AppUsesWindowControlsOverlay()));
@@ -944,8 +961,15 @@ BrowserView::BrowserView(std::unique_ptr<Browser> browser)
contents_container->SetLayoutManager(std::make_unique<ContentsLayoutManager>(
devtools_web_view_, contents_web_view_, watermark_view_));
@ -458,7 +471,7 @@ index 4b52ce3877855..7dae2a6b1b151 100644
contents_separator_ =
top_container_->AddChildView(std::make_unique<ContentsSeparator>());
@@ -1021,7 +1045,9 @@ BrowserView::~BrowserView() {
@@ -1019,7 +1043,9 @@ BrowserView::~BrowserView() {
// All the tabs should have been destroyed already. If we were closed by the
// OS with some tabs than the NativeBrowserFrame should have destroyed them.
@ -468,7 +481,7 @@ index 4b52ce3877855..7dae2a6b1b151 100644
// Stop the animation timer explicitly here to avoid running it in a nested
// message loop, which may run by Browser destructor.
@@ -1030,17 +1056,18 @@ BrowserView::~BrowserView() {
@@ -1028,17 +1054,18 @@ BrowserView::~BrowserView() {
// Immersive mode may need to reparent views before they are removed/deleted.
immersive_mode_controller_.reset();
@ -491,7 +504,7 @@ index 4b52ce3877855..7dae2a6b1b151 100644
// The TabStrip attaches a listener to the model. Make sure we shut down the
// TabStrip first so that it can cleanly remove the listener.
@@ -1064,7 +1091,9 @@ BrowserView::~BrowserView() {
@@ -1062,7 +1089,9 @@ BrowserView::~BrowserView() {
// `SidePanelUI::RemoveSidePanelUIForBrowser()` deletes the
// SidePanelCoordinator.
@ -501,7 +514,7 @@ index 4b52ce3877855..7dae2a6b1b151 100644
}
// static
@@ -1625,6 +1654,13 @@ gfx::Point BrowserView::GetThemeOffsetFromBrowserView() const {
@@ -1618,6 +1647,13 @@ gfx::Point BrowserView::GetThemeOffsetFromBrowserView() const {
ThemeProperties::kFrameHeightAboveTabs - browser_view_origin.y());
}
@ -515,7 +528,7 @@ index 4b52ce3877855..7dae2a6b1b151 100644
// static:
BrowserView::DevToolsDockedPlacement BrowserView::GetDevToolsDockedPlacement(
const gfx::Rect& contents_webview_bounds,
@@ -2029,9 +2065,14 @@ void BrowserView::OnExclusiveAccessUserInput() {
@@ -2021,9 +2057,14 @@ void BrowserView::OnExclusiveAccessUserInput() {
bool BrowserView::ShouldHideUIForFullscreen() const {
// Immersive mode needs UI for the slide-down top panel.
@ -531,7 +544,7 @@ index 4b52ce3877855..7dae2a6b1b151 100644
return frame_->GetFrameView()->ShouldHideTopUIForFullscreen();
}
@@ -3173,7 +3214,8 @@ DownloadShelf* BrowserView::GetDownloadShelf() {
@@ -3185,7 +3226,8 @@ DownloadShelf* BrowserView::GetDownloadShelf() {
}
DownloadBubbleUIController* BrowserView::GetDownloadBubbleUIController() {
@ -541,7 +554,7 @@ index 4b52ce3877855..7dae2a6b1b151 100644
if (auto* download_button = toolbar_button_provider_->GetDownloadButton())
return download_button->bubble_controller();
return nullptr;
@@ -3728,7 +3770,8 @@ void BrowserView::ReparentTopContainerForEndOfImmersive() {
@@ -3740,7 +3782,8 @@ void BrowserView::ReparentTopContainerForEndOfImmersive() {
if (top_container()->parent() == this)
return;
@ -551,7 +564,7 @@ index 4b52ce3877855..7dae2a6b1b151 100644
top_container()->DestroyLayer();
AddChildViewAt(top_container(), 0);
EnsureFocusOrder();
@@ -4210,11 +4253,38 @@ void BrowserView::GetAccessiblePanes(std::vector<views::View*>* panes) {
@@ -4223,11 +4266,38 @@ void BrowserView::GetAccessiblePanes(std::vector<views::View*>* panes) {
bool BrowserView::ShouldDescendIntoChildForEventHandling(
gfx::NativeView child,
const gfx::Point& location) {
@ -592,7 +605,7 @@ index 4b52ce3877855..7dae2a6b1b151 100644
// Draggable regions are defined relative to the web contents.
gfx::Point point_in_contents_web_view_coords(location);
views::View::ConvertPointToTarget(GetWidget()->GetRootView(),
@@ -4223,7 +4293,7 @@ bool BrowserView::ShouldDescendIntoChildForEventHandling(
@@ -4236,7 +4306,7 @@ bool BrowserView::ShouldDescendIntoChildForEventHandling(
// Draggable regions should be ignored for clicks into any browser view's
// owned widgets, for example alerts, permission prompts or find bar.
@ -601,7 +614,7 @@ index 4b52ce3877855..7dae2a6b1b151 100644
point_in_contents_web_view_coords.x(),
point_in_contents_web_view_coords.y()) ||
WidgetOwnedByAnchorContainsPoint(point_in_contents_web_view_coords);
@@ -4334,8 +4404,10 @@ void BrowserView::Layout(PassKey) {
@@ -4347,8 +4417,10 @@ void BrowserView::Layout(PassKey) {
// TODO(jamescook): Why was this in the middle of layout code?
toolbar_->location_bar()->omnibox_view()->SetFocusBehavior(
@ -614,7 +627,7 @@ index 4b52ce3877855..7dae2a6b1b151 100644
// Some of the situations when the BrowserView is laid out are:
// - Enter/exit immersive fullscreen mode.
@@ -4401,6 +4473,11 @@ void BrowserView::AddedToWidget() {
@@ -4414,6 +4486,11 @@ void BrowserView::AddedToWidget() {
SetThemeProfileForWindow(GetNativeWindow(), browser_->profile());
#endif
@ -626,7 +639,7 @@ index 4b52ce3877855..7dae2a6b1b151 100644
toolbar_->Init();
// TODO(pbos): Investigate whether the side panels should be creatable when
@@ -4448,13 +4525,9 @@ void BrowserView::AddedToWidget() {
@@ -4455,13 +4532,9 @@ void BrowserView::AddedToWidget() {
EnsureFocusOrder();
@ -642,7 +655,7 @@ index 4b52ce3877855..7dae2a6b1b151 100644
using_native_frame_ = frame_->ShouldUseNativeFrame();
MaybeInitializeWebUITabStrip();
@@ -4828,7 +4901,8 @@ void BrowserView::ProcessFullscreen(bool fullscreen,
@@ -4821,7 +4894,8 @@ void BrowserView::ProcessFullscreen(bool fullscreen,
// Undo our anti-jankiness hacks and force a re-layout.
in_process_fullscreen_ = false;
ToolbarSizeChanged(false);
@ -652,7 +665,7 @@ index 4b52ce3877855..7dae2a6b1b151 100644
}
void BrowserView::RequestFullscreen(bool fullscreen, int64_t display_id) {
@@ -5312,6 +5386,8 @@ Profile* BrowserView::GetProfile() {
@@ -5294,6 +5368,8 @@ Profile* BrowserView::GetProfile() {
}
void BrowserView::UpdateUIForTabFullscreen() {
@ -661,7 +674,7 @@ index 4b52ce3877855..7dae2a6b1b151 100644
frame()->GetFrameView()->UpdateFullscreenTopUI();
}
@@ -5334,6 +5410,8 @@ void BrowserView::HideDownloadShelf() {
@@ -5316,6 +5392,8 @@ void BrowserView::HideDownloadShelf() {
}
bool BrowserView::CanUserExitFullscreen() const {
@ -671,10 +684,10 @@ index 4b52ce3877855..7dae2a6b1b151 100644
}
diff --git chrome/browser/ui/views/frame/browser_view.h chrome/browser/ui/views/frame/browser_view.h
index e7337adf73caf..6130a2eb8fb5c 100644
index 0e1ac9a2fd806..0b6f9370737f0 100644
--- chrome/browser/ui/views/frame/browser_view.h
+++ chrome/browser/ui/views/frame/browser_view.h
@@ -143,11 +143,16 @@ class BrowserView : public BrowserWindow,
@@ -142,11 +142,16 @@ class BrowserView : public BrowserWindow,
METADATA_HEADER(BrowserView, views::ClientView)
public:
@ -691,9 +704,9 @@ index e7337adf73caf..6130a2eb8fb5c 100644
void set_frame(BrowserFrame* frame) {
frame_ = frame;
paint_as_active_subscription_ =
@@ -850,6 +855,10 @@ class BrowserView : public BrowserWindow,
// TopContainerBackground::PaintThemeCustomImage for details.
gfx::Point GetThemeOffsetFromBrowserView() const;
@@ -862,6 +867,10 @@ class BrowserView : public BrowserWindow,
base::WeakPtr<content::WebContents> expected_web_contents,
const enterprise_data_protection::UrlSettings& settings);
+ // Called during Toolbar destruction to remove dependent objects that have
+ // dangling references.
@ -702,7 +715,7 @@ index e7337adf73caf..6130a2eb8fb5c 100644
protected:
// Enumerates where the devtools are docked relative to the browser's main
// web contents.
@@ -873,6 +882,8 @@ class BrowserView : public BrowserWindow,
@@ -885,6 +894,8 @@ class BrowserView : public BrowserWindow,
const gfx::Rect& contents_webview_bounds,
const gfx::Rect& local_webview_container_bounds);
@ -712,7 +725,7 @@ index e7337adf73caf..6130a2eb8fb5c 100644
// Do not friend BrowserViewLayout. Use the BrowserViewLayoutDelegate
// interface to keep these two classes decoupled and testable.
diff --git chrome/browser/ui/views/frame/browser_view_layout.cc chrome/browser/ui/views/frame/browser_view_layout.cc
index a7f0ff7ce857e..0ee1c61503204 100644
index 96b489221fb3a..b372f67cd5c92 100644
--- chrome/browser/ui/views/frame/browser_view_layout.cc
+++ chrome/browser/ui/views/frame/browser_view_layout.cc
@@ -48,6 +48,10 @@
@ -755,8 +768,8 @@ index a7f0ff7ce857e..0ee1c61503204 100644
return gfx::Size(content_area.width(), content_area.bottom() - top);
}
@@ -131,6 +139,13 @@ class BrowserViewLayout::WebContentsModalDialogHostViews
return GetHostWidget()->GetNativeView();
@@ -132,6 +140,13 @@ class BrowserViewLayout::WebContentsModalDialogHostViews
return host_widget ? host_widget->GetNativeView() : nullptr;
}
+ int GetDialogTopY() const {
@ -769,7 +782,7 @@ index a7f0ff7ce857e..0ee1c61503204 100644
// Add/remove observer.
void AddObserver(ModalDialogHostObserver* observer) override {
observer_list_.AddObserver(observer);
@@ -441,6 +456,8 @@ void BrowserViewLayout::Layout(views::View* browser_view) {
@@ -442,6 +457,8 @@ void BrowserViewLayout::Layout(views::View* browser_view) {
if (exclusive_access_bubble)
exclusive_access_bubble->RepositionIfVisible();
@ -778,7 +791,7 @@ index a7f0ff7ce857e..0ee1c61503204 100644
// Adjust any hosted dialogs if the browser's dialog hosting bounds changed.
const gfx::Rect dialog_bounds(dialog_host_->GetDialogPosition(gfx::Size()),
dialog_host_->GetMaximumDialogSize());
@@ -454,6 +471,7 @@ void BrowserViewLayout::Layout(views::View* browser_view) {
@@ -455,6 +472,7 @@ void BrowserViewLayout::Layout(views::View* browser_view) {
latest_dialog_bounds_in_screen_ = dialog_bounds_in_screen;
dialog_host_->NotifyPositionRequiresUpdate();
}
@ -786,7 +799,7 @@ index a7f0ff7ce857e..0ee1c61503204 100644
}
gfx::Size BrowserViewLayout::GetPreferredSize(
@@ -589,6 +607,13 @@ int BrowserViewLayout::LayoutWebUITabStrip(int top) {
@@ -590,6 +608,13 @@ int BrowserViewLayout::LayoutWebUITabStrip(int top) {
int BrowserViewLayout::LayoutToolbar(int top) {
TRACE_EVENT0("ui", "BrowserViewLayout::LayoutToolbar");
@ -830,12 +843,12 @@ index 71445bfab1824..c77750ea2a820 100644
ContentsWebView::~ContentsWebView() {
diff --git chrome/browser/ui/views/frame/picture_in_picture_browser_frame_view.cc chrome/browser/ui/views/frame/picture_in_picture_browser_frame_view.cc
index 636be129ccfd6..dbb19d94c1ef9 100644
index 9858a9660ccee..a0cc25fb4fca4 100644
--- chrome/browser/ui/views/frame/picture_in_picture_browser_frame_view.cc
+++ chrome/browser/ui/views/frame/picture_in_picture_browser_frame_view.cc
@@ -604,6 +604,11 @@ PictureInPictureBrowserFrameView::PictureInPictureBrowserFrameView(
frame->GetNativeWindow()->SetEventTargeter(
std::make_unique<chromeos::InteriorResizeHandleTargeter>());
@@ -606,6 +606,11 @@ PictureInPictureBrowserFrameView::PictureInPictureBrowserFrameView(
return window->GetProperty(chromeos::kWindowStateTypeKey);
})));
#endif
+
+ if (!browser_view->browser()->SupportsWindowFeature(
@ -845,7 +858,7 @@ index 636be129ccfd6..dbb19d94c1ef9 100644
}
PictureInPictureBrowserFrameView::~PictureInPictureBrowserFrameView() {
@@ -731,18 +736,42 @@ gfx::Rect PictureInPictureBrowserFrameView::GetWindowBoundsForClientBounds(
@@ -733,18 +738,42 @@ gfx::Rect PictureInPictureBrowserFrameView::GetWindowBoundsForClientBounds(
int PictureInPictureBrowserFrameView::NonClientHitTest(
const gfx::Point& point) {
@ -896,7 +909,7 @@ index 636be129ccfd6..dbb19d94c1ef9 100644
// Allow dragging and resizing the window.
int window_component = GetHTComponentForFrame(
@@ -811,7 +840,8 @@ void PictureInPictureBrowserFrameView::Layout(PassKey) {
@@ -813,7 +842,8 @@ void PictureInPictureBrowserFrameView::Layout(PassKey) {
gfx::Rect content_area = GetLocalBounds();
content_area.Inset(FrameBorderInsets());
gfx::Rect top_bar = content_area;
@ -906,7 +919,7 @@ index 636be129ccfd6..dbb19d94c1ef9 100644
top_bar_container_view_->SetBoundsRect(top_bar);
#if !BUILDFLAG(IS_ANDROID)
if (auto_pip_setting_overlay_) {
@@ -1298,7 +1328,8 @@ gfx::Insets PictureInPictureBrowserFrameView::ResizeBorderInsets() const {
@@ -1300,7 +1330,8 @@ gfx::Insets PictureInPictureBrowserFrameView::ResizeBorderInsets() const {
}
int PictureInPictureBrowserFrameView::GetTopAreaHeight() const {
@ -931,7 +944,7 @@ index b862ceac7225d..9575440a77d67 100644
LocationBarView* location_bar_view = browser_view_->GetLocationBarView();
CHECK(location_bar_view);
diff --git chrome/browser/ui/views/page_action/page_action_icon_controller.cc chrome/browser/ui/views/page_action/page_action_icon_controller.cc
index ad0147f9b8fe8..80aea21bb605a 100644
index 04639b0a2f603..f4cfc16f6b4de 100644
--- chrome/browser/ui/views/page_action/page_action_icon_controller.cc
+++ chrome/browser/ui/views/page_action/page_action_icon_controller.cc
@@ -96,6 +96,12 @@ void PageActionIconController::Init(const PageActionIconParams& params,
@ -948,10 +961,10 @@ index ad0147f9b8fe8..80aea21bb605a 100644
case PageActionIconType::kPaymentsOfferNotification:
add_page_action_icon(
diff --git chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc
index 880d83324cfa6..a6a80cd0b3def 100644
index 9ba58b49d613e..90749dcd2d945 100644
--- chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc
+++ chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc
@@ -554,29 +554,41 @@ gfx::Range BrowserTabStripController::ListTabsInGroup(
@@ -605,29 +605,41 @@ gfx::Range BrowserTabStripController::ListTabsInGroup(
}
bool BrowserTabStripController::IsFrameCondensed() const {
@ -994,10 +1007,10 @@ index 880d83324cfa6..a6a80cd0b3def 100644
}
diff --git chrome/browser/ui/views/toolbar/toolbar_view.cc chrome/browser/ui/views/toolbar/toolbar_view.cc
index e02fe5d5e6290..9e893b2ff1727 100644
index 05ae08a41e203..1d99112e56e14 100644
--- chrome/browser/ui/views/toolbar/toolbar_view.cc
+++ chrome/browser/ui/views/toolbar/toolbar_view.cc
@@ -192,7 +192,7 @@ class TabstripLikeBackground : public views::Background {
@@ -190,7 +190,7 @@ class TabstripLikeBackground : public views::Background {
void Paint(gfx::Canvas* canvas, views::View* view) const override {
bool painted = TopContainerBackground::PaintThemeCustomImage(canvas, view,
browser_view_);
@ -1006,7 +1019,7 @@ index e02fe5d5e6290..9e893b2ff1727 100644
SkColor frame_color =
browser_view_->frame()->GetFrameView()->GetFrameColor(
BrowserFrameActiveState::kUseCurrent);
@@ -222,12 +222,13 @@ END_METADATA
@@ -220,12 +220,13 @@ END_METADATA
////////////////////////////////////////////////////////////////////////////////
// ToolbarView, public:
@ -1022,7 +1035,7 @@ index e02fe5d5e6290..9e893b2ff1727 100644
SetID(VIEW_ID_TOOLBAR);
container_view_ = AddChildView(std::make_unique<ContainerView>());
@@ -251,9 +252,24 @@ ToolbarView::~ToolbarView() {
@@ -249,9 +250,24 @@ ToolbarView::~ToolbarView() {
for (const auto& view_and_command : GetViewCommandMap())
chrome::RemoveCommandObserver(browser_, view_and_command.second, this);
@ -1047,7 +1060,7 @@ index e02fe5d5e6290..9e893b2ff1727 100644
#if defined(USE_AURA)
// Avoid generating too many occlusion tracking calculation events before this
// function returns. The occlusion status will be computed only once once this
@@ -278,12 +294,12 @@ void ToolbarView::Init() {
@@ -274,12 +290,12 @@ void ToolbarView::Init() {
auto location_bar = std::make_unique<LocationBarView>(
browser_, browser_->profile(), browser_->command_controller(), this,
@ -1062,8 +1075,8 @@ index e02fe5d5e6290..9e893b2ff1727 100644
download_button =
std::make_unique<DownloadToolbarButtonView>(browser_view_);
}
@@ -365,8 +381,10 @@ void ToolbarView::Init() {
}
@@ -359,8 +375,10 @@ void ToolbarView::Init() {
toolbar_divider = std::make_unique<views::View>();
}
std::unique_ptr<media_router::CastToolbarButton> cast;
- if (media_router::MediaRouterEnabled(browser_->profile()))
@ -1074,7 +1087,7 @@ index e02fe5d5e6290..9e893b2ff1727 100644
std::unique_ptr<MediaToolbarButtonView> media_button;
if (base::FeatureList::IsEnabled(media::kGlobalMediaControls)) {
@@ -376,7 +394,8 @@ void ToolbarView::Init() {
@@ -370,7 +388,8 @@ void ToolbarView::Init() {
std::unique_ptr<send_tab_to_self::SendTabToSelfToolbarIconView>
send_tab_to_self_button;
@ -1084,29 +1097,21 @@ index e02fe5d5e6290..9e893b2ff1727 100644
send_tab_to_self_button =
std::make_unique<send_tab_to_self::SendTabToSelfToolbarIconView>(
browser_view_);
@@ -461,7 +480,7 @@ void ToolbarView::Init() {
send_tab_to_self_button_ =
container_view_->AddChildView(std::move(send_tab_to_self_button));
@@ -796,7 +815,8 @@ void ToolbarView::Layout(PassKey) {
- if (!features::IsSidePanelPinningEnabled()) {
+ if (!features::IsSidePanelPinningEnabled() && BUTTON_VISIBLE(kSidePanel)) {
if (companion::IsCompanionFeatureEnabled()) {
side_panel_container_ = container_view_->AddChildView(
std::make_unique<SidePanelToolbarContainer>(browser_view_));
@@ -828,7 +847,7 @@ void ToolbarView::Layout(PassKey) {
if (display_mode_ == DisplayMode::NORMAL) {
LayoutCommon();
- if (features::IsChromeRefresh2023()) {
+ if (features::IsChromeRefresh2023() && !browser_->toolbar_overridden()) {
UpdateClipPath();
}
- UpdateClipPath();
+ if (!browser_->toolbar_overridden())
+ UpdateClipPath();
}
// Use two-pass solution to avoid the overflow button interfering with toolbar
diff --git chrome/browser/ui/views/toolbar/toolbar_view.h chrome/browser/ui/views/toolbar/toolbar_view.h
index 2437b17ffab96..24ac297165db1 100644
index 78079d1c56460..0585cfd0de16b 100644
--- chrome/browser/ui/views/toolbar/toolbar_view.h
+++ chrome/browser/ui/views/toolbar/toolbar_view.h
@@ -94,7 +94,8 @@ class ToolbarView : public views::AccessiblePaneView,
@@ -92,7 +92,8 @@ class ToolbarView : public views::AccessiblePaneView,
// needs to be displayed.
};
@ -1116,16 +1121,3 @@ index 2437b17ffab96..24ac297165db1 100644
ToolbarView(const ToolbarView&) = delete;
ToolbarView& operator=(const ToolbarView&) = delete;
~ToolbarView() override;
diff --git chrome/browser/ui/web_applications/web_app_menu_model.cc chrome/browser/ui/web_applications/web_app_menu_model.cc
index 09eb9dbce62f6..93e6dde56ca16 100644
--- chrome/browser/ui/web_applications/web_app_menu_model.cc
+++ chrome/browser/ui/web_applications/web_app_menu_model.cc
@@ -216,7 +216,7 @@ void WebAppMenuModel::Build() {
}
if (media_router::MediaRouterEnabled(browser()->profile()))
AddItemWithStringId(IDC_ROUTE_MEDIA, IDS_MEDIA_ROUTER_MENU_ITEM_TITLE);
- if (!features::IsChromeRefresh2023()) {
+ if (!features::IsChromeRefresh2023() && IsCommandIdVisible(IDC_EDIT_MENU)) {
AddSeparator(ui::LOWER_SEPARATOR);
CreateCutCopyPasteMenu();
}

View File

@ -1,8 +1,8 @@
diff --git content/browser/devtools/devtools_http_handler.cc content/browser/devtools/devtools_http_handler.cc
index 2068552edfba8..6ef07a0a5b7fa 100644
index a24477b920c5f..4a62dddd15ec7 100644
--- content/browser/devtools/devtools_http_handler.cc
+++ content/browser/devtools/devtools_http_handler.cc
@@ -591,7 +591,7 @@ void DevToolsHttpHandler::OnJsonRequest(
@@ -596,7 +596,7 @@ void DevToolsHttpHandler::OnJsonRequest(
base::Value::Dict version;
version.Set("Protocol-Version", DevToolsAgentHost::GetProtocolVersion());
version.Set("WebKit-Version", GetWebKitVersion());
@ -12,10 +12,10 @@ index 2068552edfba8..6ef07a0a5b7fa 100644
version.Set("V8-Version", V8_VERSION_STRING);
std::string host = info.GetHeaderValue("host");
diff --git content/browser/loader/navigation_url_loader_impl.cc content/browser/loader/navigation_url_loader_impl.cc
index eef1951861e8b..4800ef3400623 100644
index 6ff681f94dcba..82b93e6d3052a 100644
--- content/browser/loader/navigation_url_loader_impl.cc
+++ content/browser/loader/navigation_url_loader_impl.cc
@@ -850,7 +850,7 @@ NavigationURLLoaderImpl::CreateNonNetworkLoaderFactory(
@@ -854,7 +854,7 @@ NavigationURLLoaderImpl::CreateNonNetworkLoaderFactory(
mojo::PendingRemote<network::mojom::URLLoaderFactory>
terminal_external_protocol;
bool handled = GetContentClient()->browser()->HandleExternalProtocol(
@ -24,7 +24,7 @@ index eef1951861e8b..4800ef3400623 100644
frame_tree_node->frame_tree_node_id(), navigation_ui_data,
request_info.is_primary_main_frame,
frame_tree_node->IsInFencedFrameTree(), request_info.sandbox_flags,
@@ -862,6 +862,21 @@ NavigationURLLoaderImpl::CreateNonNetworkLoaderFactory(
@@ -866,6 +866,21 @@ NavigationURLLoaderImpl::CreateNonNetworkLoaderFactory(
*request_info.initiator_document_token)
: nullptr,
&terminal_external_protocol);
@ -47,10 +47,10 @@ index eef1951861e8b..4800ef3400623 100644
return std::make_pair(
/*is_cacheable=*/false,
diff --git content/public/browser/content_browser_client.cc content/public/browser/content_browser_client.cc
index 62fed61bd87f1..7a4631e9fb6b7 100644
index 8df62dd712ad5..b191ea472448a 100644
--- content/public/browser/content_browser_client.cc
+++ content/public/browser/content_browser_client.cc
@@ -1100,7 +1100,7 @@ ContentBrowserClient::CreateURLLoaderHandlerForServiceWorkerNavigationPreload(
@@ -1104,7 +1104,7 @@ ContentBrowserClient::CreateURLLoaderHandlerForServiceWorkerNavigationPreload(
void ContentBrowserClient::OnNetworkServiceCreated(
network::mojom::NetworkService* network_service) {}
@ -59,7 +59,7 @@ index 62fed61bd87f1..7a4631e9fb6b7 100644
BrowserContext* context,
bool in_memory,
const base::FilePath& relative_partition_path,
@@ -1109,6 +1109,7 @@ void ContentBrowserClient::ConfigureNetworkContextParams(
@@ -1113,6 +1113,7 @@ void ContentBrowserClient::ConfigureNetworkContextParams(
cert_verifier_creation_params) {
network_context_params->user_agent = GetUserAgentBasedOnPolicy(context);
network_context_params->accept_language = "en-us,en";
@ -68,10 +68,10 @@ index 62fed61bd87f1..7a4631e9fb6b7 100644
std::vector<base::FilePath>
diff --git content/public/browser/content_browser_client.h content/public/browser/content_browser_client.h
index 406607bd32563..e32e445aa8923 100644
index 8f457dd1d2afb..6df18f193039e 100644
--- content/public/browser/content_browser_client.h
+++ content/public/browser/content_browser_client.h
@@ -2079,7 +2079,7 @@ class CONTENT_EXPORT ContentBrowserClient {
@@ -2094,7 +2094,7 @@ class CONTENT_EXPORT ContentBrowserClient {
//
// If |relative_partition_path| is the empty string, it means this needs to
// create the default NetworkContext for the BrowserContext.
@ -80,7 +80,7 @@ index 406607bd32563..e32e445aa8923 100644
BrowserContext* context,
bool in_memory,
const base::FilePath& relative_partition_path,
@@ -2300,6 +2300,21 @@ class CONTENT_EXPORT ContentBrowserClient {
@@ -2307,6 +2307,21 @@ class CONTENT_EXPORT ContentBrowserClient {
RenderFrameHost* initiator_document,
mojo::PendingRemote<network::mojom::URLLoaderFactory>* out_factory);
@ -102,7 +102,7 @@ index 406607bd32563..e32e445aa8923 100644
// Creates an OverlayWindow to be used for video or Picture-in-Picture.
// This window will house the content shown when in Picture-in-Picture mode.
// This will return a new OverlayWindow.
@@ -2357,6 +2372,10 @@ class CONTENT_EXPORT ContentBrowserClient {
@@ -2364,6 +2379,10 @@ class CONTENT_EXPORT ContentBrowserClient {
// Used as part of the user agent string.
virtual std::string GetProduct();
@ -114,7 +114,7 @@ index 406607bd32563..e32e445aa8923 100644
// on blink::features::kUserAgentReduction. Content may cache this value.
virtual std::string GetUserAgent();
diff --git content/public/renderer/content_renderer_client.h content/public/renderer/content_renderer_client.h
index a062418a22ec9..9b97b77a1f916 100644
index 7a9334a6cb0c7..031f5eb442331 100644
--- content/public/renderer/content_renderer_client.h
+++ content/public/renderer/content_renderer_client.h
@@ -108,6 +108,9 @@ class CONTENT_EXPORT ContentRendererClient {
@ -127,7 +127,7 @@ index a062418a22ec9..9b97b77a1f916 100644
// Notifies that a new RenderFrame has been created.
virtual void RenderFrameCreated(RenderFrame* render_frame) {}
@@ -337,6 +340,10 @@ class CONTENT_EXPORT ContentRendererClient {
@@ -339,6 +342,10 @@ class CONTENT_EXPORT ContentRendererClient {
// This method may invalidate the frame.
virtual void RunScriptsAtDocumentIdle(RenderFrame* render_frame) {}
@ -139,10 +139,10 @@ index a062418a22ec9..9b97b77a1f916 100644
// started.
virtual void SetRuntimeFeaturesDefaultsBeforeBlinkInitialization() {}
diff --git content/renderer/render_thread_impl.cc content/renderer/render_thread_impl.cc
index da4a8410a6c5d..41cb281d271dd 100644
index c977c0ed18151..fa6241f2c761d 100644
--- content/renderer/render_thread_impl.cc
+++ content/renderer/render_thread_impl.cc
@@ -549,6 +549,8 @@ void RenderThreadImpl::Init() {
@@ -556,6 +556,8 @@ void RenderThreadImpl::Init() {
GetContentClient()->renderer()->CreateURLLoaderThrottleProvider(
blink::URLLoaderThrottleProviderType::kFrame);
@ -152,10 +152,10 @@ index da4a8410a6c5d..41cb281d271dd 100644
base::BindRepeating(&RenderThreadImpl::OnRendererInterfaceReceiver,
base::Unretained(this)));
diff --git content/renderer/renderer_blink_platform_impl.cc content/renderer/renderer_blink_platform_impl.cc
index c053926291ea4..6edf384e53cd8 100644
index 32f322e1ef607..f4aabab498e88 100644
--- content/renderer/renderer_blink_platform_impl.cc
+++ content/renderer/renderer_blink_platform_impl.cc
@@ -989,6 +989,15 @@ SkBitmap* RendererBlinkPlatformImpl::GetSadPageBitmap() {
@@ -1000,6 +1000,15 @@ SkBitmap* RendererBlinkPlatformImpl::GetSadPageBitmap() {
//------------------------------------------------------------------------------
@ -172,10 +172,10 @@ index c053926291ea4..6edf384e53cd8 100644
RendererBlinkPlatformImpl::CreateWebV8ValueConverter() {
return std::make_unique<V8ValueConverterImpl>();
diff --git content/renderer/renderer_blink_platform_impl.h content/renderer/renderer_blink_platform_impl.h
index d5ab3967f21cc..b6494070f6840 100644
index 8a8faf056bee0..03edc844d5d6e 100644
--- content/renderer/renderer_blink_platform_impl.h
+++ content/renderer/renderer_blink_platform_impl.h
@@ -236,6 +236,9 @@ class CONTENT_EXPORT RendererBlinkPlatformImpl : public BlinkPlatformImpl {
@@ -238,6 +238,9 @@ class CONTENT_EXPORT RendererBlinkPlatformImpl : public BlinkPlatformImpl {
InertAndMinimumIntervalOfUserLevelMemoryPressureSignal() override;
#endif // BUILDFLAG(IS_ANDROID)
@ -186,10 +186,10 @@ index d5ab3967f21cc..b6494070f6840 100644
// plus eTLD+1, such as https://google.com), or to a more specific origin.
void SetIsLockedToSite();
diff --git content/shell/browser/shell_content_browser_client.cc content/shell/browser/shell_content_browser_client.cc
index d8a569dde0012..d3e755f66e4ec 100644
index feb037de8a1ad..77d6079e85912 100644
--- content/shell/browser/shell_content_browser_client.cc
+++ content/shell/browser/shell_content_browser_client.cc
@@ -749,7 +749,7 @@ void ShellContentBrowserClient::OnNetworkServiceCreated(
@@ -736,7 +736,7 @@ void ShellContentBrowserClient::OnNetworkServiceCreated(
#endif
}
@ -198,7 +198,7 @@ index d8a569dde0012..d3e755f66e4ec 100644
BrowserContext* context,
bool in_memory,
const base::FilePath& relative_partition_path,
@@ -758,6 +758,7 @@ void ShellContentBrowserClient::ConfigureNetworkContextParams(
@@ -745,6 +745,7 @@ void ShellContentBrowserClient::ConfigureNetworkContextParams(
cert_verifier_creation_params) {
ConfigureNetworkContextParamsForShell(context, network_context_params,
cert_verifier_creation_params);
@ -207,10 +207,10 @@ index d8a569dde0012..d3e755f66e4ec 100644
std::vector<base::FilePath>
diff --git content/shell/browser/shell_content_browser_client.h content/shell/browser/shell_content_browser_client.h
index 810c7adb1e2b9..1827d957ed012 100644
index 281435690f2b9..6d3cc5b627bb3 100644
--- content/shell/browser/shell_content_browser_client.h
+++ content/shell/browser/shell_content_browser_client.h
@@ -151,7 +151,7 @@ class ShellContentBrowserClient : public ContentBrowserClient {
@@ -148,7 +148,7 @@ class ShellContentBrowserClient : public ContentBrowserClient {
GetGeolocationSystemPermissionManager() override;
void OnNetworkServiceCreated(
network::mojom::NetworkService* network_service) override;
@ -220,7 +220,7 @@ index 810c7adb1e2b9..1827d957ed012 100644
bool in_memory,
const base::FilePath& relative_partition_path,
diff --git headless/lib/browser/headless_content_browser_client.cc headless/lib/browser/headless_content_browser_client.cc
index e4be49f9cccf8..6132a90e5ee93 100644
index 77cf03ca44be9..43928ef67393b 100644
--- headless/lib/browser/headless_content_browser_client.cc
+++ headless/lib/browser/headless_content_browser_client.cc
@@ -301,7 +301,7 @@ bool HeadlessContentBrowserClient::IsSharedStorageSelectURLAllowed(
@ -241,7 +241,7 @@ index e4be49f9cccf8..6132a90e5ee93 100644
std::string HeadlessContentBrowserClient::GetProduct() {
diff --git headless/lib/browser/headless_content_browser_client.h headless/lib/browser/headless_content_browser_client.h
index 90cc52b93e737..882f385844d59 100644
index eae1297164eb0..abab2091ace5f 100644
--- headless/lib/browser/headless_content_browser_client.h
+++ headless/lib/browser/headless_content_browser_client.h
@@ -85,7 +85,7 @@ class HeadlessContentBrowserClient : public content::ContentBrowserClient {

View File

@ -103,10 +103,10 @@ index 96c28a7ce3183..3d60ab170e9a5 100644
}
diff --git content/app/content_main_runner_impl.cc content/app/content_main_runner_impl.cc
index 5e4c1f8d6c872..6df7bdba1cff7 100644
index 78b9930f1ca5c..1d93552c3da25 100644
--- content/app/content_main_runner_impl.cc
+++ content/app/content_main_runner_impl.cc
@@ -47,6 +47,7 @@
@@ -52,6 +52,7 @@
#include "base/task/thread_pool/thread_pool_instance.h"
#include "base/threading/hang_watcher.h"
#include "base/threading/platform_thread.h"
@ -114,7 +114,7 @@ index 5e4c1f8d6c872..6df7bdba1cff7 100644
#include "base/time/time.h"
#include "base/trace_event/trace_event.h"
#include "build/build_config.h"
@@ -1349,6 +1350,11 @@ void ContentMainRunnerImpl::Shutdown() {
@@ -1342,6 +1343,11 @@ void ContentMainRunnerImpl::Shutdown() {
is_shutdown_ = true;
}

View File

@ -1,8 +1,8 @@
diff --git content/browser/renderer_host/render_process_host_impl.cc content/browser/renderer_host/render_process_host_impl.cc
index 83defaaaad55d..76486ceed16e5 100644
index 32454297cb12b..1f0b5d5d6a5e4 100644
--- content/browser/renderer_host/render_process_host_impl.cc
+++ content/browser/renderer_host/render_process_host_impl.cc
@@ -1628,7 +1628,8 @@ bool RenderProcessHostImpl::Init() {
@@ -1639,7 +1639,8 @@ bool RenderProcessHostImpl::Init() {
// initialized because in tests the factory may never have been initialized.
if (!GetBrowserContext()->IsOffTheRecord() &&
!base::CommandLine::ForCurrentProcess()->HasSwitch(

View File

@ -357,16 +357,15 @@ index 171095381e8ac..13407a7809844 100644
annotations, arguments, false, false));
} else {
diff --git components/crash/core/app/crashpad_mac.mm components/crash/core/app/crashpad_mac.mm
index eb5bcfe0234c3..8963b26806922 100644
index 42fe73aefe44f..575ce6732ae43 100644
--- components/crash/core/app/crashpad_mac.mm
+++ components/crash/core/app/crashpad_mac.mm
@@ -17,11 +17,14 @@
@@ -17,10 +17,13 @@
#include "base/apple/foundation_util.h"
#include "base/check.h"
#include "base/files/file_path.h"
+#include "base/path_service.h"
#include "base/strings/string_number_conversions.h"
#include "base/strings/string_piece.h"
#include "base/strings/sys_string_conversions.h"
#include "build/branding_buildflags.h"
#include "components/crash/core/app/crash_reporter_client.h"
@ -375,7 +374,7 @@ index eb5bcfe0234c3..8963b26806922 100644
#include "third_party/crashpad/crashpad/client/crash_report_database.h"
#include "third_party/crashpad/crashpad/client/crashpad_client.h"
#include "third_party/crashpad/crashpad/client/crashpad_info.h"
@@ -39,15 +42,25 @@ std::map<std::string, std::string> GetProcessSimpleAnnotations() {
@@ -38,15 +41,25 @@ std::map<std::string, std::string> GetProcessSimpleAnnotations() {
std::map<std::string, std::string> process_annotations;
@autoreleasepool {
NSBundle* outer_bundle = base::apple::OuterBundle();
@ -407,7 +406,7 @@ index eb5bcfe0234c3..8963b26806922 100644
#if BUILDFLAG(GOOGLE_CHROME_BRANDING)
// Empty means stable.
@@ -78,12 +91,20 @@ std::map<std::string, std::string> GetProcessSimpleAnnotations() {
@@ -77,12 +90,20 @@ std::map<std::string, std::string> GetProcessSimpleAnnotations() {
}
}
@ -433,7 +432,7 @@ index eb5bcfe0234c3..8963b26806922 100644
} // @autoreleasepool
return process_annotations;
}();
@@ -143,10 +164,10 @@ bool PlatformCrashpadInitialization(
@@ -142,10 +163,10 @@ bool PlatformCrashpadInitialization(
if (initial_client) {
@autoreleasepool {
@ -448,7 +447,7 @@ index eb5bcfe0234c3..8963b26806922 100644
// Is there a way to recover if this fails?
CrashReporterClient* crash_reporter_client = GetCrashReporterClient();
@@ -175,6 +196,12 @@ bool PlatformCrashpadInitialization(
@@ -174,6 +195,12 @@ bool PlatformCrashpadInitialization(
"--reset-own-crash-exception-port-to-system-default");
}

View File

@ -1,5 +1,5 @@
diff --git third_party/crashpad/crashpad/client/prune_crash_reports.cc third_party/crashpad/crashpad/client/prune_crash_reports.cc
index 077694f541d57..928a520485414 100644
index 59b96461bbbbb..b3781cd1c42d9 100644
--- third_party/crashpad/crashpad/client/prune_crash_reports.cc
+++ third_party/crashpad/crashpad/client/prune_crash_reports.cc
@@ -75,13 +75,19 @@ size_t PruneCrashReportDatabase(CrashReportDatabase* database,
@ -40,7 +40,7 @@ index b362e0aadbadd..1588232a6e4d4 100644
virtual ~PruneCondition() {}
diff --git third_party/crashpad/crashpad/client/settings.cc third_party/crashpad/crashpad/client/settings.cc
index 5e4119e2175c7..e66600089be04 100644
index 420fbfc958168..eef5955d6f5a8 100644
--- third_party/crashpad/crashpad/client/settings.cc
+++ third_party/crashpad/crashpad/client/settings.cc
@@ -117,7 +117,7 @@ void ScopedLockedFileHandleTraits::Free(FileHandle handle) {
@ -184,7 +184,7 @@ index a2d6f7fb482a7..a5b6ae04f897b 100644
if (crashpad_is_win) {
diff --git third_party/crashpad/crashpad/handler/crash_report_upload_thread.cc third_party/crashpad/crashpad/handler/crash_report_upload_thread.cc
index 5bd2889eda975..bf3ff4bfcf5c8 100644
index c224871a1de23..3186b9a45428d 100644
--- third_party/crashpad/crashpad/handler/crash_report_upload_thread.cc
+++ third_party/crashpad/crashpad/handler/crash_report_upload_thread.cc
@@ -297,6 +297,8 @@ CrashReportUploadThread::UploadResult CrashReportUploadThread::UploadReport(

View File

@ -1,5 +1,5 @@
diff --git components/embedder_support/user_agent_utils.cc components/embedder_support/user_agent_utils.cc
index fe76e8806f05f..30b184844a5b5 100644
index 0d9ed98759c4b..48ed045b691a1 100644
--- components/embedder_support/user_agent_utils.cc
+++ components/embedder_support/user_agent_utils.cc
@@ -18,6 +18,7 @@

View File

@ -64,7 +64,7 @@ index b9b147c8c11df..1e3acf4e679ae 100644
std::unique_ptr<StreamContainer> stream_container(
new StreamContainer(tab_id, embedded, handler_url, extension_id,
diff --git extensions/browser/extension_host.cc extensions/browser/extension_host.cc
index 2bf778dd0c85d..c75d693c6487b 100644
index 55b798350ae8d..e4f7f261efcb3 100644
--- extensions/browser/extension_host.cc
+++ extensions/browser/extension_host.cc
@@ -142,12 +142,13 @@ ExtensionHost::ExtensionHost(const Extension* extension,
@ -238,7 +238,7 @@ index 8b515b7b8c353..f8e4106ac26d4 100644
// once each time the extensions system is loaded per browser_context. The
// implementation may wish to use the BrowserContext to record the current
diff --git extensions/browser/process_manager.cc extensions/browser/process_manager.cc
index c9793db28037b..e5f017bf2f2f8 100644
index 8e512cd3c826e..0cfda0e69be23 100644
--- extensions/browser/process_manager.cc
+++ extensions/browser/process_manager.cc
@@ -353,9 +353,17 @@ bool ProcessManager::CreateBackgroundHost(const Extension* extension,
@ -261,7 +261,7 @@ index c9793db28037b..e5f017bf2f2f8 100644
base::BindOnce(&ProcessManager::HandleCloseExtensionHost,
weak_ptr_factory_.GetWeakPtr()));
diff --git extensions/common/extensions_client.cc extensions/common/extensions_client.cc
index 5142f341b8392..0589a1f1466f5 100644
index c313f6f98cabc..d49f624cce881 100644
--- extensions/common/extensions_client.cc
+++ extensions/common/extensions_client.cc
@@ -8,6 +8,7 @@
@ -269,9 +269,9 @@ index 5142f341b8392..0589a1f1466f5 100644
#include "base/check.h"
#include "base/notreached.h"
+#include "cef/libcef/features/features.h"
#include "extensions/common/extension_icon_set.h"
#include "extensions/common/extensions_api_provider.h"
#include "extensions/common/features/feature_provider.h"
#include "extensions/common/features/json_feature_provider_source.h"
@@ -25,7 +26,10 @@ ExtensionsClient* g_client = nullptr;
} // namespace

View File

@ -1,8 +1,8 @@
diff --git .gn .gn
index e6f5cbc9c49f9..f64ed7ae77ea1 100644
index 44a11ec90ec9b..4c35b35a97f28 100644
--- .gn
+++ .gn
@@ -155,6 +155,8 @@ exec_script_whitelist =
@@ -158,6 +158,8 @@ exec_script_whitelist =
"//chrome/android/webapk/shell_apk/prepare_upload_dir/BUILD.gn",
"//chrome/version.gni",
@ -12,7 +12,7 @@ index e6f5cbc9c49f9..f64ed7ae77ea1 100644
# https://crbug.com/474506.
"//clank/java/BUILD.gn",
diff --git BUILD.gn BUILD.gn
index 3ede70d5d17be..764ce45183919 100644
index 2902e374bb1a2..875924ff22c23 100644
--- BUILD.gn
+++ BUILD.gn
@@ -20,6 +20,7 @@ import("//build/config/sanitizers/sanitizers.gni")
@ -20,10 +20,10 @@ index 3ede70d5d17be..764ce45183919 100644
import("//build/gn_logs.gni")
import("//build/util/generate_wrapper.gni")
+import("//cef/libcef/features/features.gni")
import("//chrome/enterprise_companion/buildflags.gni")
import("//components/enterprise/buildflags/buildflags.gni")
import("//components/nacl/features.gni")
import("//device/vr/buildflags/buildflags.gni")
@@ -275,6 +276,10 @@ group("gn_all") {
@@ -280,6 +281,10 @@ group("gn_all") {
deps += root_extra_deps
@ -76,20 +76,20 @@ index 1da479dd5eebc..ff9c7e467997c 100644
- visual_studio_runtime_dirs = []
}
diff --git chrome/chrome_paks.gni chrome/chrome_paks.gni
index 87e4b167b6a55..6dafb9ac4ed94 100644
index e75651677c098..9288caaf195e1 100644
--- chrome/chrome_paks.gni
+++ chrome/chrome_paks.gni
@@ -5,6 +5,7 @@
import("//ash/ambient/resources/resources.gni")
@@ -6,6 +6,7 @@ import("//ash/ambient/resources/resources.gni")
import("//build/config/chrome_build.gni")
import("//build/config/chromeos/ui_mode.gni")
import("//build/config/locales.gni")
+import("//cef/libcef/features/features.gni")
import("//chrome/browser/buildflags.gni")
import("//chrome/common/features.gni")
import("//components/compose/features.gni")
@@ -82,6 +83,10 @@ template("chrome_repack_percent") {
"//ui/chromeos/resources",
]
@@ -89,6 +90,10 @@ template("chrome_repack_percent") {
]
}
}
+ if (enable_cef) {
+ sources += [ "$root_gen_dir/cef/cef_resources.pak" ]

View File

@ -1,8 +1,8 @@
diff --git tools/gritsettings/resource_ids.spec tools/gritsettings/resource_ids.spec
index f3ca54d7277ac..16a52e64f3078 100644
index 2450f2cece033..73c3bf885cf06 100644
--- tools/gritsettings/resource_ids.spec
+++ tools/gritsettings/resource_ids.spec
@@ -1312,6 +1312,15 @@
@@ -1341,6 +1341,15 @@
# END "everything else" section.
# Everything but chrome/, components/, content/, and ios/

View File

@ -48,7 +48,7 @@ index 23d0611fdb2b5..81fd1055e926e 100644
}
diff --git ui/gtk/native_theme_gtk.cc ui/gtk/native_theme_gtk.cc
index d69b17b004120..5175ea3a785a3 100644
index 0b765216c727f..d2c1e21e19b98 100644
--- ui/gtk/native_theme_gtk.cc
+++ ui/gtk/native_theme_gtk.cc
@@ -164,9 +164,11 @@ void NativeThemeGtk::OnThemeChanged(GtkSettings* settings,
@ -107,7 +107,7 @@ index fc32dfb0de44f..44ca8103247b1 100644
explicit NativeTheme(
bool should_only_use_dark_colors,
diff --git ui/native_theme/native_theme_mac.mm ui/native_theme/native_theme_mac.mm
index 9ca3120cfe3ac..c29c17330a7e5 100644
index a2dbe84d61e09..aff4aad15e069 100644
--- ui/native_theme/native_theme_mac.mm
+++ ui/native_theme/native_theme_mac.mm
@@ -586,11 +586,15 @@ void NativeThemeMac::PaintSelectedMenuItem(
@ -129,10 +129,10 @@ index 9ca3120cfe3ac..c29c17330a7e5 100644
theme->NotifyOnNativeThemeUpdated();
}];
diff --git ui/native_theme/native_theme_win.cc ui/native_theme/native_theme_win.cc
index 547872076d126..14d0e817f3243 100644
index b5bdcf72d8b33..e3f04dda5c1a6 100644
--- ui/native_theme/native_theme_win.cc
+++ ui/native_theme/native_theme_win.cc
@@ -673,14 +673,17 @@ bool NativeThemeWin::ShouldUseDarkColors() const {
@@ -675,14 +675,17 @@ bool NativeThemeWin::ShouldUseDarkColors() const {
// Windows high contrast modes are entirely different themes,
// so let them take priority over dark mode.
// ...unless --force-dark-mode was specified in which case caveat emptor.
@ -152,7 +152,7 @@ index 547872076d126..14d0e817f3243 100644
return NativeTheme::CalculatePreferredColorScheme();
// According to the spec, the preferred color scheme for web content is 'dark'
@@ -1671,8 +1674,9 @@ void NativeThemeWin::RegisterColorFilteringRegkeyObserver() {
@@ -1673,8 +1676,9 @@ void NativeThemeWin::RegisterColorFilteringRegkeyObserver() {
}
void NativeThemeWin::UpdateDarkModeStatus() {

View File

@ -1,5 +1,5 @@
diff --git chrome/common/media/component_widevine_cdm_hint_file_linux.cc chrome/common/media/component_widevine_cdm_hint_file_linux.cc
index 60033bb10af50..afb0d23c07a34 100644
index 1084e82141790..ebd1b051d81b9 100644
--- chrome/common/media/component_widevine_cdm_hint_file_linux.cc
+++ chrome/common/media/component_widevine_cdm_hint_file_linux.cc
@@ -18,6 +18,7 @@
@ -8,9 +8,9 @@ index 60033bb10af50..afb0d23c07a34 100644
#include "chrome/common/chrome_paths.h"
+#include "third_party/widevine/cdm/widevine_cdm_common.h"
namespace {
@@ -25,12 +26,31 @@ namespace {
#if BUILDFLAG(IS_CHROMEOS_LACROS)
#include "base/command_line.h"
@@ -32,6 +33,26 @@ namespace {
const char kPath[] = "Path";
const char kLastBundledVersion[] = "LastBundledVersion";
@ -37,16 +37,19 @@ index 60033bb10af50..afb0d23c07a34 100644
// Returns the hint file contents as a Value::Dict. Returned result may be an
// empty dictionary if the hint file does not exist or is formatted incorrectly.
base::Value::Dict GetHintFileContents() {
base::FilePath hint_file_path;
@@ -58,8 +79,7 @@ base::Value::Dict GetHintFileContents() {
hint_file_path = command_line->GetSwitchValuePath(
switches::kCrosWidevineComponentUpdatedHintFile);
#else
- CHECK(base::PathService::Get(chrome::FILE_COMPONENT_WIDEVINE_CDM_HINT,
- &hint_file_path));
+ CHECK(GetHintFilePath(&hint_file_path));
#endif // BUILDFLAG(IS_CHROMEOS_LACROS)
DVLOG(1) << __func__ << " checking " << hint_file_path;
if (!base::PathExists(hint_file_path)) {
@@ -65,8 +85,7 @@ bool UpdateWidevineCdmHintFile(const base::FilePath& cdm_base_path,
DCHECK(!cdm_base_path.empty());
@@ -98,8 +118,7 @@ bool UpdateWidevineCdmHintFile(const base::FilePath& cdm_base_path,
NOTREACHED_NORETURN() << "Lacros should not be updating the hint file.";
#else
base::FilePath hint_file_path;
- CHECK(base::PathService::Get(chrome::FILE_COMPONENT_WIDEVINE_CDM_HINT,
- &hint_file_path));

View File

@ -1,5 +1,5 @@
diff --git ui/gtk/gtk_ui.cc ui/gtk/gtk_ui.cc
index 7b81a752ffad2..24297039e23d4 100644
index d6b7bf6496c25..2bae4e2a4e9e1 100644
--- ui/gtk/gtk_ui.cc
+++ ui/gtk/gtk_ui.cc
@@ -26,6 +26,7 @@

View File

@ -1,5 +1,5 @@
diff --git printing/printing_context_linux.cc printing/printing_context_linux.cc
index 03302777935ba..4e53392605c37 100644
index d1ab2a72e0d11..c6be9f1ba1793 100644
--- printing/printing_context_linux.cc
+++ printing/printing_context_linux.cc
@@ -69,11 +69,11 @@ mojom::ResultCode PrintingContextLinux::UseDefaultSettings() {

View File

@ -0,0 +1,17 @@
diff --git third_party/tflite/features.gni third_party/tflite/features.gni
index 2466577542552..d94d80cda02d6 100644
--- third_party/tflite/features.gni
+++ third_party/tflite/features.gni
@@ -7,9 +7,9 @@ import("//build/config/chrome_build.gni")
declare_args() {
# This enables building TFLite with XNNPACK. Currently only available for
# Linux, macOS and Windows arm64/x64/x86 targets and ChromeOS non-ARM targets.
- build_tflite_with_xnnpack =
- is_win || is_mac || is_linux ||
- (is_chromeos && target_cpu != "arm64" && target_cpu != "arm")
+ build_tflite_with_xnnpack = (is_win || is_mac || is_linux ||
+ (is_chromeos && current_cpu != "arm64" && current_cpu != "arm")) &&
+ (current_cpu == "arm64" || current_cpu == "x64" || current_cpu == "x86")
# Turns on TFLITE_WITH_RUY, using ruy as the gemm backend instead of gemmlowp.
build_tflite_with_ruy = true

View File

@ -1,8 +1,8 @@
diff --git ui/events/keycodes/keyboard_code_conversion_mac.mm ui/events/keycodes/keyboard_code_conversion_mac.mm
index c66e866757cd1..3cd7a654f4883 100644
index adaf106d6fcbc..d6e90550db41d 100644
--- ui/events/keycodes/keyboard_code_conversion_mac.mm
+++ ui/events/keycodes/keyboard_code_conversion_mac.mm
@@ -930,7 +930,7 @@ DomKey DomKeyFromNSEvent(NSEvent* event) {
@@ -895,7 +895,7 @@ DomKey DomKeyFromNSEvent(NSEvent* event) {
return DomKeyFromKeyCode(event.keyCode);
}
default:

View File

@ -1,8 +1,8 @@
diff --git chrome/browser/ui/views/profiles/profile_menu_view_base.cc chrome/browser/ui/views/profiles/profile_menu_view_base.cc
index b87138e45c207..4542996484462 100644
index 70da374af533f..5d1804eab6831 100644
--- chrome/browser/ui/views/profiles/profile_menu_view_base.cc
+++ chrome/browser/ui/views/profiles/profile_menu_view_base.cc
@@ -1167,8 +1167,8 @@ int ProfileMenuViewBase::GetMaxHeight() const {
@@ -1089,8 +1089,8 @@ int ProfileMenuViewBase::GetMaxHeight() const {
->GetDisplayNearestPoint(anchor_rect.CenterPoint())
.work_area();
int available_space = screen_space.bottom() - anchor_rect.bottom();

View File

@ -1,8 +1,8 @@
diff --git content/app_shim_remote_cocoa/render_widget_host_view_cocoa.mm content/app_shim_remote_cocoa/render_widget_host_view_cocoa.mm
index 1cb6eb60ef419..b0bdc60cebc0d 100644
index a14c65728ec51..2c40d6074f8b8 100644
--- content/app_shim_remote_cocoa/render_widget_host_view_cocoa.mm
+++ content/app_shim_remote_cocoa/render_widget_host_view_cocoa.mm
@@ -166,6 +166,13 @@ void ExtractUnderlines(NSAttributedString* string,
@@ -171,6 +171,13 @@ void ExtractUnderlines(NSAttributedString* string,
// RenderWidgetHostViewCocoa ---------------------------------------------------
@ -16,7 +16,7 @@ index 1cb6eb60ef419..b0bdc60cebc0d 100644
// Private methods:
@interface RenderWidgetHostViewCocoa ()
@@ -762,6 +769,15 @@ void ExtractUnderlines(NSAttributedString* string,
@@ -767,6 +774,15 @@ void ExtractUnderlines(NSAttributedString* string,
}
- (BOOL)acceptsFirstMouse:(NSEvent*)theEvent {

View File

@ -1,5 +1,5 @@
diff --git base/message_loop/message_pump_win.cc base/message_loop/message_pump_win.cc
index 5a48d5b098d86..95ebca554932f 100644
index e55f8f0d40a79..6ffc10930a5cc 100644
--- base/message_loop/message_pump_win.cc
+++ base/message_loop/message_pump_win.cc
@@ -2,6 +2,7 @@

View File

@ -1,8 +1,8 @@
diff --git base/message_loop/message_pump_apple.mm base/message_loop/message_pump_apple.mm
index 570a7583512b0..9a38033880604 100644
index e7fe3f71d8710..3a145fc9282ee 100644
--- base/message_loop/message_pump_apple.mm
+++ base/message_loop/message_pump_apple.mm
@@ -764,7 +764,8 @@ void MessagePumpUIApplication::Detach() {
@@ -761,7 +761,8 @@ void MessagePumpUIApplication::Detach() {
#else
ScopedPumpMessagesInPrivateModes::ScopedPumpMessagesInPrivateModes() {
@ -12,7 +12,7 @@ index 570a7583512b0..9a38033880604 100644
DCHECK_EQ(kNSApplicationModalSafeModeMask, g_app_pump->GetModeMask());
// Pumping events in private runloop modes is known to interact badly with
// app modal windows like NSAlert.
@@ -775,7 +776,8 @@ ScopedPumpMessagesInPrivateModes::ScopedPumpMessagesInPrivateModes() {
@@ -772,7 +773,8 @@ ScopedPumpMessagesInPrivateModes::ScopedPumpMessagesInPrivateModes() {
}
ScopedPumpMessagesInPrivateModes::~ScopedPumpMessagesInPrivateModes() {

View File

@ -1,5 +1,5 @@
diff --git components/metrics/persistent_system_profile.cc components/metrics/persistent_system_profile.cc
index 768c933cd13c6..78d86b97e64bf 100644
index a04737dc52b0c..c7e9caa809f8a 100644
--- components/metrics/persistent_system_profile.cc
+++ components/metrics/persistent_system_profile.cc
@@ -395,6 +395,10 @@ bool PersistentSystemProfile::GetSystemProfile(

View File

@ -12,7 +12,7 @@ index 0cc1db9645f04..ab2ae8c744278 100644
virtual ~WebContentsView() = default;
diff --git extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest.cc extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest.cc
index 8a77da73784c8..9ca31537809a3 100644
index fad08e33e16e4..571b52332a198 100644
--- extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest.cc
+++ extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest.cc
@@ -204,6 +204,8 @@ void MimeHandlerViewGuest::CreateWebContents(

View File

@ -10,10 +10,10 @@ index 0e563dbb253ca..891b2bbc3785c 100644
+// This load will not send any cookies. For CEF usage.
+LOAD_FLAG(DO_NOT_SEND_COOKIES, 1 << 20)
diff --git net/url_request/url_request_http_job.cc net/url_request/url_request_http_job.cc
index be520e63b503c..74f842d07499c 100644
index 0a05208583e4e..0a2f2e1c39fba 100644
--- net/url_request/url_request_http_job.cc
+++ net/url_request/url_request_http_job.cc
@@ -1905,7 +1905,8 @@ bool URLRequestHttpJob::ShouldAddCookieHeader() const {
@@ -1980,7 +1980,8 @@ bool URLRequestHttpJob::ShouldAddCookieHeader() const {
// Read cookies whenever allow_credentials() is true, even if the PrivacyMode
// is being overridden by NetworkDelegate and will eventually block them, as
// blocked cookies still need to be logged in that case.
@ -24,7 +24,7 @@ index be520e63b503c..74f842d07499c 100644
bool URLRequestHttpJob::ShouldRecordPartitionedCookieUsage() const {
diff --git services/network/public/cpp/resource_request.cc services/network/public/cpp/resource_request.cc
index 3d4cc0dbf277e..eddba6b5a8471 100644
index b220ca953b1db..c9057833fe15b 100644
--- services/network/public/cpp/resource_request.cc
+++ services/network/public/cpp/resource_request.cc
@@ -329,7 +329,8 @@ bool ResourceRequest::EqualsForTesting(const ResourceRequest& request) const {

View File

@ -1,8 +1,8 @@
diff --git net/test/embedded_test_server/embedded_test_server.cc net/test/embedded_test_server/embedded_test_server.cc
index a3ec8894015a8..eec36b0183bce 100644
index fcd55c845d90f..9ba1f2bcdf850 100644
--- net/test/embedded_test_server/embedded_test_server.cc
+++ net/test/embedded_test_server/embedded_test_server.cc
@@ -1041,7 +1041,7 @@ bool EmbeddedTestServer::PostTaskToIOThreadAndWait(base::OnceClosure closure) {
@@ -1046,7 +1046,7 @@ bool EmbeddedTestServer::PostTaskToIOThreadAndWait(base::OnceClosure closure) {
if (!base::CurrentThread::Get())
temporary_loop = std::make_unique<base::SingleThreadTaskExecutor>();
@ -11,7 +11,7 @@ index a3ec8894015a8..eec36b0183bce 100644
if (!io_thread_->task_runner()->PostTaskAndReply(
FROM_HERE, std::move(closure), run_loop.QuitClosure())) {
return false;
@@ -1068,7 +1068,7 @@ bool EmbeddedTestServer::PostTaskToIOThreadAndWaitWithResult(
@@ -1073,7 +1073,7 @@ bool EmbeddedTestServer::PostTaskToIOThreadAndWaitWithResult(
if (!base::CurrentThread::Get())
temporary_loop = std::make_unique<base::SingleThreadTaskExecutor>();

View File

@ -1,5 +1,5 @@
diff --git net/url_request/url_request_job.cc net/url_request/url_request_job.cc
index e221b9dce73ec..ab566481896ba 100644
index a3d565a410685..82e6ca8a4ca1e 100644
--- net/url_request/url_request_job.cc
+++ net/url_request/url_request_job.cc
@@ -34,6 +34,7 @@
@ -27,7 +27,7 @@ index e221b9dce73ec..ab566481896ba 100644
} // namespace
// Each SourceStreams own the previous SourceStream in the chain, but the
@@ -334,8 +345,7 @@ GURL URLRequestJob::ComputeReferrerForPolicy(
@@ -338,8 +349,7 @@ GURL URLRequestJob::ComputeReferrerForPolicy(
}
bool secure_referrer_but_insecure_destination =

View File

@ -1,8 +1,39 @@
diff --git components/input/fling_scheduler_base.h components/input/fling_scheduler_base.h
index 76057b3e50f78..d3b63a3b07805 100644
--- components/input/fling_scheduler_base.h
+++ components/input/fling_scheduler_base.h
@@ -5,14 +5,26 @@
#ifndef COMPONENTS_INPUT_FLING_SCHEDULER_BASE_H_
#define COMPONENTS_INPUT_FLING_SCHEDULER_BASE_H_
+#include "base/memory/raw_ptr.h"
#include "components/input/fling_controller.h"
+namespace ui {
+class Compositor;
+}
+
namespace input {
class FlingSchedulerBase : public FlingControllerSchedulerClient {
public:
virtual void ProgressFlingOnBeginFrameIfneeded(
base::TimeTicks current_time) = 0;
+
+ void SetCompositor(ui::Compositor* compositor) {
+ compositor_ = compositor;
+ }
+
+ protected:
+ raw_ptr<ui::Compositor> compositor_ = nullptr;
};
} // namespace input
diff --git content/browser/renderer_host/input/fling_scheduler.cc content/browser/renderer_host/input/fling_scheduler.cc
index 431df5d50debe..0fcc9ea8fbb1a 100644
index 57ef85cbfdfdf..758af3beffde6 100644
--- content/browser/renderer_host/input/fling_scheduler.cc
+++ content/browser/renderer_host/input/fling_scheduler.cc
@@ -68,6 +68,9 @@ void FlingScheduler::ProgressFlingOnBeginFrameIfneeded(
@@ -98,6 +98,9 @@ void FlingScheduler::ProgressFlingOnBeginFrameIfneeded(
}
ui::Compositor* FlingScheduler::GetCompositor() {
@ -13,10 +44,10 @@ index 431df5d50debe..0fcc9ea8fbb1a 100644
return nullptr;
}
diff --git content/browser/renderer_host/render_widget_host_impl.cc content/browser/renderer_host/render_widget_host_impl.cc
index 7fba410705048..7ce1d8a5eeb7f 100644
index 7f2fdc026d61b..9d719020f971f 100644
--- content/browser/renderer_host/render_widget_host_impl.cc
+++ content/browser/renderer_host/render_widget_host_impl.cc
@@ -3292,6 +3292,11 @@ void RenderWidgetHostImpl::OnInvalidInputEventSource() {
@@ -3277,6 +3277,11 @@ void RenderWidgetHostImpl::OnInvalidInputEventSource() {
GetProcess(), bad_message::INPUT_ROUTER_INVALID_EVENT_SOURCE);
}
@ -29,10 +60,10 @@ index 7fba410705048..7ce1d8a5eeb7f 100644
const WebInputEvent& event) {
if ((base::FeatureList::IsEnabled(
diff --git content/browser/renderer_host/render_widget_host_impl.h content/browser/renderer_host/render_widget_host_impl.h
index dee4fb6b79285..fd3eaef2b6972 100644
index 3f0048bea5698..24936dc2b3154 100644
--- content/browser/renderer_host/render_widget_host_impl.h
+++ content/browser/renderer_host/render_widget_host_impl.h
@@ -811,6 +811,7 @@ class CONTENT_EXPORT RenderWidgetHostImpl
@@ -827,6 +827,7 @@ class CONTENT_EXPORT RenderWidgetHostImpl
void ProgressFlingIfNeeded(base::TimeTicks current_time);
void StopFling();
@ -40,46 +71,15 @@ index dee4fb6b79285..fd3eaef2b6972 100644
RenderWidgetHostViewBase* GetRenderWidgetHostViewBase();
diff --git content/common/input/fling_scheduler_base.h content/common/input/fling_scheduler_base.h
index e8ee63f3abc2e..765ea358e093a 100644
--- content/common/input/fling_scheduler_base.h
+++ content/common/input/fling_scheduler_base.h
@@ -5,14 +5,26 @@
#ifndef CONTENT_COMMON_INPUT_FLING_SCHEDULER_BASE_H_
#define CONTENT_COMMON_INPUT_FLING_SCHEDULER_BASE_H_
+#include "base/memory/raw_ptr.h"
#include "content/common/input/fling_controller.h"
+namespace ui {
+class Compositor;
+}
+
namespace content {
class FlingSchedulerBase : public FlingControllerSchedulerClient {
public:
virtual void ProgressFlingOnBeginFrameIfneeded(
base::TimeTicks current_time) = 0;
+
+ void SetCompositor(ui::Compositor* compositor) {
+ compositor_ = compositor;
+ }
+
+protected:
+ raw_ptr<ui::Compositor> compositor_ = nullptr;
};
} // namespace content
diff --git content/common/input/render_input_router.h content/common/input/render_input_router.h
index cab10100a369d..d8f3be04bfeba 100644
index 6b6267448dcac..e166401709885 100644
--- content/common/input/render_input_router.h
+++ content/common/input/render_input_router.h
@@ -61,6 +61,7 @@ class CONTENT_EXPORT RenderInputRouter : public InputRouterImplClient {
@@ -62,6 +62,7 @@ class CONTENT_EXPORT RenderInputRouter : public InputRouterImplClient,
InputRouter* input_router() { return input_router_.get(); }
RenderInputRouterDelegate* delegate() { return delegate_; }
+ FlingSchedulerBase* fling_scheduler() { return fling_scheduler_.get(); }
+ input::FlingSchedulerBase* fling_scheduler() { return fling_scheduler_.get(); }
void SetForceEnableZoom(bool);
void SetDeviceScaleFactor(float device_scale_factor);

View File

@ -1,5 +1,5 @@
diff --git gpu/ipc/service/gpu_memory_buffer_factory_dxgi.cc gpu/ipc/service/gpu_memory_buffer_factory_dxgi.cc
index 58df3e9ad67b2..759f27c07efe9 100644
index 9cac49288f3b1..3ee5ff8714824 100644
--- gpu/ipc/service/gpu_memory_buffer_factory_dxgi.cc
+++ gpu/ipc/service/gpu_memory_buffer_factory_dxgi.cc
@@ -180,7 +180,8 @@ gfx::GpuMemoryBufferHandle GpuMemoryBufferFactoryDXGI::CreateGpuMemoryBuffer(
@ -24,10 +24,10 @@ index 58df3e9ad67b2..759f27c07efe9 100644
Microsoft::WRL::ComPtr<ID3D11Texture2D> d3d11_texture;
diff --git media/video/renderable_gpu_memory_buffer_video_frame_pool.cc media/video/renderable_gpu_memory_buffer_video_frame_pool.cc
index 1d352951f9592..c346ebf506aa0 100644
index fb079f3ad91c5..74658c47bf04f 100644
--- media/video/renderable_gpu_memory_buffer_video_frame_pool.cc
+++ media/video/renderable_gpu_memory_buffer_video_frame_pool.cc
@@ -198,7 +198,7 @@ gfx::Size GetBufferSizeInPixelsForVideoPixelFormat(
@@ -197,7 +197,7 @@ gfx::Size GetBufferSizeInPixelsForVideoPixelFormat(
bool FrameResources::Initialize() {
auto* context = pool_->GetContext();
@ -36,7 +36,7 @@ index 1d352951f9592..c346ebf506aa0 100644
#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_CHROMEOS)
gfx::BufferUsage::SCANOUT_VEA_CPU_READ
#else
@@ -212,13 +212,30 @@ bool FrameResources::Initialize() {
@@ -211,13 +211,30 @@ bool FrameResources::Initialize() {
const gfx::Size buffer_size_in_pixels =
GetBufferSizeInPixelsForVideoPixelFormat(format_, coded_size_);

View File

@ -1,5 +1,5 @@
diff --git chrome/browser/printing/print_preview_dialog_controller.cc chrome/browser/printing/print_preview_dialog_controller.cc
index 54efe456fd86e..a685c4e0722cc 100644
index c312526970cf7..330b8f38616ae 100644
--- chrome/browser/printing/print_preview_dialog_controller.cc
+++ chrome/browser/printing/print_preview_dialog_controller.cc
@@ -16,6 +16,7 @@
@ -27,7 +27,7 @@ index 5d1658999d5bb..d1b7b7288c946 100644
$i18n{cancel}
</cr-button>
diff --git chrome/browser/ui/webui/constrained_web_dialog_ui.cc chrome/browser/ui/webui/constrained_web_dialog_ui.cc
index c85248ab0d0a0..1595d2aa62bce 100644
index 44ef8eb632c99..5b10ce9a9caad 100644
--- chrome/browser/ui/webui/constrained_web_dialog_ui.cc
+++ chrome/browser/ui/webui/constrained_web_dialog_ui.cc
@@ -13,6 +13,7 @@
@ -53,7 +53,7 @@ index c85248ab0d0a0..1595d2aa62bce 100644
}
diff --git chrome/browser/ui/webui/print_preview/print_preview_ui.cc chrome/browser/ui/webui/print_preview/print_preview_ui.cc
index 8aea19c0090dc..79f48310eeb1b 100644
index 5f1daafe9c815..20511d2af7af4 100644
--- chrome/browser/ui/webui/print_preview/print_preview_ui.cc
+++ chrome/browser/ui/webui/print_preview/print_preview_ui.cc
@@ -25,6 +25,7 @@
@ -64,7 +64,7 @@ index 8aea19c0090dc..79f48310eeb1b 100644
#include "chrome/browser/browser_process.h"
#include "chrome/browser/enterprise/browser_management/management_service_factory.h"
#include "chrome/browser/pdf/pdf_extension_util.h"
@@ -109,6 +110,15 @@ const char16_t kBasicPrintShortcut[] = u"(\u2325\u2318P)";
@@ -109,6 +110,15 @@ const char16_t kBasicPrintShortcut[] = u"(⌥⌘P)";
const char16_t kBasicPrintShortcut[] = u"(Ctrl+Shift+P)";
#endif

View File

@ -1,5 +1,5 @@
diff --git net/base/directory_lister.cc net/base/directory_lister.cc
index ae3a99f31e2ec..213cc33f2cc8e 100644
index 9a9787aae0233..467cbef7f6c34 100644
--- net/base/directory_lister.cc
+++ net/base/directory_lister.cc
@@ -200,7 +200,7 @@ void DirectoryLister::OnListFile(const DirectoryListerData& data) {

View File

@ -1,8 +1,8 @@
diff --git content/browser/renderer_host/render_view_host_impl.cc content/browser/renderer_host/render_view_host_impl.cc
index d39f6f582109e..42f72e96f0128 100644
index e3955cead61e4..72fc8ed8cac7e 100644
--- content/browser/renderer_host/render_view_host_impl.cc
+++ content/browser/renderer_host/render_view_host_impl.cc
@@ -710,6 +710,8 @@ bool RenderViewHostImpl::IsRenderViewLive() const {
@@ -727,6 +727,8 @@ bool RenderViewHostImpl::IsRenderViewLive() const {
}
void RenderViewHostImpl::SetBackgroundOpaque(bool opaque) {

View File

@ -1,5 +1,5 @@
diff --git ui/base/resource/resource_bundle.cc ui/base/resource/resource_bundle.cc
index 02b98136ad3bd..52dd10da2dfa2 100644
index a0aa0b111a123..09a8e2fdc2d2c 100644
--- ui/base/resource/resource_bundle.cc
+++ ui/base/resource/resource_bundle.cc
@@ -944,6 +944,12 @@ ResourceBundle::ResourceBundle(Delegate* delegate)

View File

@ -1,8 +1,8 @@
diff --git content/browser/renderer_host/render_frame_host_impl.cc content/browser/renderer_host/render_frame_host_impl.cc
index 3821695f6561f..3cd78bf565086 100644
index 9c8b401d00136..f1b9050b55bc3 100644
--- content/browser/renderer_host/render_frame_host_impl.cc
+++ content/browser/renderer_host/render_frame_host_impl.cc
@@ -10854,6 +10854,7 @@ void RenderFrameHostImpl::CommitNavigation(
@@ -10880,6 +10880,7 @@ void RenderFrameHostImpl::CommitNavigation(
auto browser_calc_origin_to_commit =
navigation_request->GetOriginToCommitWithDebugInfo();
if (!process_lock.is_error_page() && !is_mhtml_subframe &&

View File

@ -1,8 +1,8 @@
diff --git build/toolchain/win/setup_toolchain.py build/toolchain/win/setup_toolchain.py
index 521c24398ef9f..8392f18169a32 100644
index 927fce24fcdc6..834c84eae805e 100644
--- build/toolchain/win/setup_toolchain.py
+++ build/toolchain/win/setup_toolchain.py
@@ -167,13 +167,17 @@ def _LoadToolchainEnv(cpu, toolchain_root, sdk_dir, target_store):
@@ -166,13 +166,17 @@ def _LoadToolchainEnv(cpu, toolchain_root, sdk_dir, target_store):
del os.environ['LIB']
if 'LIBPATH' in os.environ:
del os.environ['LIBPATH']

View File

@ -1,5 +1,5 @@
diff --git content/browser/renderer_host/render_widget_host_view_aura.cc content/browser/renderer_host/render_widget_host_view_aura.cc
index df08c0e0fc675..1a2af7a635e75 100644
index a2e0720681d6f..5534dce563fcb 100644
--- content/browser/renderer_host/render_widget_host_view_aura.cc
+++ content/browser/renderer_host/render_widget_host_view_aura.cc
@@ -6,6 +6,7 @@
@ -18,7 +18,7 @@ index df08c0e0fc675..1a2af7a635e75 100644
#include "content/public/common/page_visibility_state.h"
#include "services/service_manager/public/cpp/interface_provider.h"
#include "third_party/blink/public/common/input/web_input_event.h"
@@ -738,10 +740,12 @@ gfx::Rect RenderWidgetHostViewAura::GetViewBounds() {
@@ -744,10 +746,12 @@ gfx::Rect RenderWidgetHostViewAura::GetViewBounds() {
void RenderWidgetHostViewAura::UpdateBackgroundColor() {
CHECK(GetBackgroundColor());
@ -35,7 +35,7 @@ index df08c0e0fc675..1a2af7a635e75 100644
}
#if BUILDFLAG(IS_WIN)
@@ -2371,6 +2375,16 @@ void RenderWidgetHostViewAura::CreateAuraWindow(aura::client::WindowType type) {
@@ -2364,6 +2368,16 @@ void RenderWidgetHostViewAura::CreateAuraWindow(aura::client::WindowType type) {
window_->layer()->SetColor(GetBackgroundColor() ? *GetBackgroundColor()
: SK_ColorWHITE);
UpdateFrameSinkIdRegistration();

View File

@ -1,8 +1,8 @@
diff --git ui/display/screen.cc ui/display/screen.cc
index 22747ebcf31c0..8fba5da85a656 100644
index 3090a05e91f31..7fac1b23ffb62 100644
--- ui/display/screen.cc
+++ ui/display/screen.cc
@@ -107,13 +107,13 @@ base::TimeDelta Screen::CalculateIdleTime() const {
@@ -108,13 +108,13 @@ base::TimeDelta Screen::CalculateIdleTime() const {
gfx::Rect Screen::ScreenToDIPRectInWindow(gfx::NativeWindow window,
const gfx::Rect& screen_rect) const {
float scale = GetDisplayNearestWindow(window).device_scale_factor();
@ -19,10 +19,10 @@ index 22747ebcf31c0..8fba5da85a656 100644
bool Screen::GetDisplayWithDisplayId(int64_t display_id,
diff --git ui/display/win/screen_win.cc ui/display/win/screen_win.cc
index 3a9a310328aa3..d4c4a9947c1d9 100644
index 2027612f9207a..6f0ebb0801e60 100644
--- ui/display/win/screen_win.cc
+++ ui/display/win/screen_win.cc
@@ -544,7 +544,7 @@ gfx::Rect ScreenWin::ScreenToDIPRect(HWND hwnd, const gfx::Rect& pixel_bounds) {
@@ -601,7 +601,7 @@ gfx::Rect ScreenWin::ScreenToDIPRect(HWND hwnd, const gfx::Rect& pixel_bounds) {
gfx::PointF(pixel_bounds.origin()), screen_win_display));
const float scale_factor =
1.0f / screen_win_display.display().device_scale_factor();
@ -31,7 +31,7 @@ index 3a9a310328aa3..d4c4a9947c1d9 100644
}
// static
@@ -559,7 +559,7 @@ gfx::Rect ScreenWin::DIPToScreenRect(HWND hwnd, const gfx::Rect& dip_bounds) {
@@ -616,7 +616,7 @@ gfx::Rect ScreenWin::DIPToScreenRect(HWND hwnd, const gfx::Rect& dip_bounds) {
const gfx::Point origin =
display::win::DIPToScreenPoint(dip_bounds.origin(), screen_win_display);
const float scale_factor = screen_win_display.display().device_scale_factor();

View File

@ -1,5 +1,5 @@
diff --git chrome/browser/enterprise/connectors/analysis/content_analysis_delegate.cc chrome/browser/enterprise/connectors/analysis/content_analysis_delegate.cc
index 65bc8909d771f..a18907dd1e7ec 100644
index 504a8473a7511..6c6aa2d9c4541 100644
--- chrome/browser/enterprise/connectors/analysis/content_analysis_delegate.cc
+++ chrome/browser/enterprise/connectors/analysis/content_analysis_delegate.cc
@@ -23,6 +23,7 @@
@ -10,7 +10,7 @@ index 65bc8909d771f..a18907dd1e7ec 100644
#include "chrome/browser/browser_process.h"
#include "chrome/browser/enterprise/connectors/analysis/analysis_settings.h"
#include "chrome/browser/enterprise/connectors/analysis/content_analysis_dialog.h"
@@ -357,6 +358,11 @@ bool ContentAnalysisDelegate::IsEnabled(Profile* profile,
@@ -367,6 +368,11 @@ bool ContentAnalysisDelegate::IsEnabled(Profile* profile,
GURL url,
Data* data,
AnalysisConnector connector) {
@ -40,7 +40,7 @@ index a3c34a9922d2e..38c982442bc80 100644
base::RepeatingCallback<content::BrowserContext*()> browser_context_getter =
base::BindRepeating(
diff --git chrome/browser/net/profile_network_context_service.cc chrome/browser/net/profile_network_context_service.cc
index 627fc56f4f7cf..86d5f8027fd26 100644
index 6a0d1c78df0df..b38785be13813 100644
--- chrome/browser/net/profile_network_context_service.cc
+++ chrome/browser/net/profile_network_context_service.cc
@@ -25,6 +25,7 @@
@ -51,7 +51,7 @@ index 627fc56f4f7cf..86d5f8027fd26 100644
#include "chrome/browser/browser_features.h"
#include "chrome/browser/browser_process.h"
#include "chrome/browser/content_settings/cookie_settings_factory.h"
@@ -239,9 +240,16 @@ void UpdateCookieSettings(Profile* profile, ContentSettingsType type) {
@@ -241,9 +242,16 @@ void UpdateCookieSettings(Profile* profile, ContentSettingsType type) {
// occurs in this class is unsynchronized, so it would be racy to rely on
// this update finishing before calling the context's callback.) This
// unfortunately triggers a double-update here.
@ -71,7 +71,7 @@ index 627fc56f4f7cf..86d5f8027fd26 100644
settings = fedcm_context->GetSharingPermissionGrantsAsContentSettings();
}
} else {
@@ -801,9 +809,16 @@ ProfileNetworkContextService::CreateCookieManagerParams(
@@ -819,9 +827,16 @@ ProfileNetworkContextService::CreateCookieManagerParams(
continue;
}
if (type == ContentSettingsType::FEDERATED_IDENTITY_SHARING) {
@ -91,7 +91,7 @@ index 627fc56f4f7cf..86d5f8027fd26 100644
out->content_settings[type] =
fedcm_context->GetSharingPermissionGrantsAsContentSettings();
} else {
@@ -1039,9 +1054,32 @@ void ProfileNetworkContextService::ConfigureNetworkContextParamsInternal(
@@ -1054,9 +1069,32 @@ void ProfileNetworkContextService::ConfigureNetworkContextParamsInternal(
network_context_params->cookie_manager_params =
CreateCookieManagerParams(profile_, *cookie_settings_);
@ -125,7 +125,7 @@ index 627fc56f4f7cf..86d5f8027fd26 100644
PrefService* local_state = g_browser_process->local_state();
// Configure the HTTP cache path and size.
base::FilePath base_cache_path;
@@ -1050,15 +1088,14 @@ void ProfileNetworkContextService::ConfigureNetworkContextParamsInternal(
@@ -1065,15 +1103,14 @@ void ProfileNetworkContextService::ConfigureNetworkContextParamsInternal(
local_state->GetFilePath(prefs::kDiskCacheDir);
if (!disk_cache_dir.empty())
base_cache_path = disk_cache_dir.Append(base_cache_path.BaseName());
@ -145,7 +145,7 @@ index 627fc56f4f7cf..86d5f8027fd26 100644
network_context_params->file_paths->data_directory =
path.Append(chrome::kNetworkDataDirname);
network_context_params->file_paths->unsandboxed_data_path = path;
@@ -1229,6 +1266,9 @@ void ProfileNetworkContextService::ConfigureNetworkContextParamsInternal(
@@ -1264,6 +1301,9 @@ void ProfileNetworkContextService::ConfigureNetworkContextParamsInternal(
network_context_params->first_party_sets_access_delegate_params =
network::mojom::FirstPartySetsAccessDelegateParams::New();
network_context_params->first_party_sets_access_delegate_params->enabled =
@ -178,10 +178,10 @@ index 58750a47240e5..2894f323c26bb 100644
GetInstance()->GetServiceForBrowserContext(profile, true));
}
diff --git net/cookies/cookie_monster.cc net/cookies/cookie_monster.cc
index 80af544e4175c..5b1edea7a43cb 100644
index 8e1134654e2b1..d0f578b5f9976 100644
--- net/cookies/cookie_monster.cc
+++ net/cookies/cookie_monster.cc
@@ -630,6 +630,25 @@ void CookieMonster::SetCookieableSchemes(
@@ -635,6 +635,25 @@ void CookieMonster::SetCookieableSchemes(
MaybeRunCookieCallback(std::move(callback), true);
}
@ -208,7 +208,7 @@ index 80af544e4175c..5b1edea7a43cb 100644
void CookieMonster::SetPersistSessionCookies(bool persist_session_cookies) {
DCHECK_CALLED_ON_VALID_THREAD(thread_checker_);
diff --git net/cookies/cookie_monster.h net/cookies/cookie_monster.h
index b4cb9c4c343a5..976f2134eb055 100644
index bea9a3b81a538..78fbab874c436 100644
--- net/cookies/cookie_monster.h
+++ net/cookies/cookie_monster.h
@@ -210,6 +210,8 @@ class NET_EXPORT CookieMonster : public CookieStore {
@ -237,10 +237,10 @@ index 3f0be99e0e145..0462ebbe9bedc 100644
// reset to null.
const CookieAccessDelegate* cookie_access_delegate() const {
diff --git services/network/cookie_manager.cc services/network/cookie_manager.cc
index 60cd3989fe135..d65e76f5b8b75 100644
index 613f34e4bc536..35096fc6f5f19 100644
--- services/network/cookie_manager.cc
+++ services/network/cookie_manager.cc
@@ -313,14 +313,9 @@ void CookieManager::AllowFileSchemeCookies(
@@ -340,14 +340,9 @@ void CookieManager::AllowFileSchemeCookies(
AllowFileSchemeCookiesCallback callback) {
OnSettingsWillChange();
@ -259,10 +259,10 @@ index 60cd3989fe135..d65e76f5b8b75 100644
void CookieManager::SetForceKeepSessionState() {
diff --git services/network/network_context.cc services/network/network_context.cc
index aa94a653ee3fb..2c105860f5682 100644
index 42d451bfe43e1..1a1cf67b38d27 100644
--- services/network/network_context.cc
+++ services/network/network_context.cc
@@ -2434,16 +2434,20 @@ URLRequestContextOwner NetworkContext::MakeURLRequestContext(
@@ -2495,16 +2495,20 @@ URLRequestContextOwner NetworkContext::MakeURLRequestContext(
network_service_->network_quality_estimator());
}
@ -291,7 +291,7 @@ index aa94a653ee3fb..2c105860f5682 100644
base::FeatureList::IsEnabled(features::kFledgePst)) {
trust_token_store_ = std::make_unique<PendingTrustTokenStore>();
diff --git services/network/public/mojom/network_context.mojom services/network/public/mojom/network_context.mojom
index 10109d4ac851f..23b6f7ff418b9 100644
index 5597a97f13cc0..c8524b7d971f0 100644
--- services/network/public/mojom/network_context.mojom
+++ services/network/public/mojom/network_context.mojom
@@ -359,6 +359,9 @@ struct NetworkContextParams {

View File

@ -1,8 +1,8 @@
diff --git content/browser/storage_partition_impl.cc content/browser/storage_partition_impl.cc
index 56f70fef0b2fb..4d2a75eebd102 100644
index 8b04f2afe863e..effc59857dfd4 100644
--- content/browser/storage_partition_impl.cc
+++ content/browser/storage_partition_impl.cc
@@ -3326,8 +3326,12 @@ void StoragePartitionImpl::GetQuotaSettings(
@@ -3353,8 +3353,12 @@ void StoragePartitionImpl::GetQuotaSettings(
return;
}
@ -16,7 +16,7 @@ index 56f70fef0b2fb..4d2a75eebd102 100644
storage::GetDefaultDeviceInfoHelper(), std::move(callback));
}
@@ -3337,9 +3341,12 @@ void StoragePartitionImpl::InitNetworkContext() {
@@ -3364,9 +3368,12 @@ void StoragePartitionImpl::InitNetworkContext() {
cert_verifier::mojom::CertVerifierCreationParamsPtr
cert_verifier_creation_params =
cert_verifier::mojom::CertVerifierCreationParams::New();

View File

@ -58,7 +58,7 @@ index e82cdd66a2d5c..1816b2fe54ff5 100644
// static
diff --git storage/browser/database/database_tracker.cc storage/browser/database/database_tracker.cc
index 872bf7d1671bb..b87bb299316f2 100644
index 3d98c6095ef27..a84c84d580d84 100644
--- storage/browser/database/database_tracker.cc
+++ storage/browser/database/database_tracker.cc
@@ -559,7 +559,7 @@ bool DatabaseTracker::LazyInit() {

View File

@ -1,8 +1,8 @@
diff --git base/trace_event/builtin_categories.h base/trace_event/builtin_categories.h
index 4c1a949117a07..1d659b729f2a9 100644
index a3da4353d4ea5..ddb6479e4286a 100644
--- base/trace_event/builtin_categories.h
+++ base/trace_event/builtin_categories.h
@@ -70,6 +70,8 @@
@@ -71,6 +71,8 @@
X("cc") \
X("cc.debug") \
X("cdp.perf") \

View File

@ -1,8 +1,8 @@
diff --git chrome/browser/ui/views/toolbar/app_menu.cc chrome/browser/ui/views/toolbar/app_menu.cc
index b95f9c9a2b856..602dc0588b4a5 100644
index 7986c86012518..fa75795aa6c30 100644
--- chrome/browser/ui/views/toolbar/app_menu.cc
+++ chrome/browser/ui/views/toolbar/app_menu.cc
@@ -1032,7 +1032,9 @@ void AppMenu::RunMenu(views::MenuButtonController* host) {
@@ -1025,7 +1025,9 @@ void AppMenu::RunMenu(views::MenuButtonController* host) {
host->button()->GetWidget(), host,
host->button()->GetAnchorBoundsInScreen(),
views::MenuAnchorPosition::kTopRight, ui::MENU_SOURCE_NONE,
@ -58,7 +58,7 @@ index fb795f76d3616..6e36a4c1e29da 100644
virtual void MenuWillShow() {}
diff --git ui/gfx/render_text.cc ui/gfx/render_text.cc
index fa63b2ad55957..0b224818db3d9 100644
index 7437fc1dbf24c..fe19f3e046b1a 100644
--- ui/gfx/render_text.cc
+++ ui/gfx/render_text.cc
@@ -696,6 +696,14 @@ void RenderText::SetWhitespaceElision(std::optional<bool> whitespace_elision) {
@ -134,10 +134,10 @@ index c579f65dce9f0..a04e0d1f66aaa 100644
friend class test::InkDropHostTestApi;
diff --git ui/views/controls/button/label_button.cc ui/views/controls/button/label_button.cc
index 265d1bc554133..d3cb82ed3ecec 100644
index 04d4aca2784dc..b3ce5e1f2174c 100644
--- ui/views/controls/button/label_button.cc
+++ ui/views/controls/button/label_button.cc
@@ -617,6 +617,12 @@ void LabelButton::OnThemeChanged() {
@@ -596,6 +596,12 @@ void LabelButton::OnThemeChanged() {
SchedulePaint();
}
@ -151,10 +151,10 @@ index 265d1bc554133..d3cb82ed3ecec 100644
Button::StateChanged(old_state);
ResetLabelEnabledColor();
diff --git ui/views/controls/button/label_button.h ui/views/controls/button/label_button.h
index 3c862290eab9c..0e85970c08486 100644
index aaa15dcd8c72b..7d5fe7306a37c 100644
--- ui/views/controls/button/label_button.h
+++ ui/views/controls/button/label_button.h
@@ -188,6 +188,9 @@ class VIEWS_EXPORT LabelButton : public Button,
@@ -187,6 +187,9 @@ class VIEWS_EXPORT LabelButton : public Button,
// widget, and the parent of the containing widget.
ButtonState GetVisualState() const;
@ -165,10 +165,10 @@ index 3c862290eab9c..0e85970c08486 100644
LabelButtonImageContainer* image_container() {
return image_container_.get();
diff --git ui/views/controls/label.cc ui/views/controls/label.cc
index 2c773355d2961..9ccba5a459bd5 100644
index 33e534c7eb6d0..3ed887e0dae41 100644
--- ui/views/controls/label.cc
+++ ui/views/controls/label.cc
@@ -51,12 +51,29 @@ enum LabelPropertyKey {
@@ -57,12 +57,29 @@ enum LabelPropertyKey {
kLabelLineHeight,
kLabelObscured,
kLabelAllowCharacterBreak,
@ -198,7 +198,7 @@ index 2c773355d2961..9ccba5a459bd5 100644
} // namespace
namespace views {
@@ -485,6 +502,15 @@ void Label::SetElideBehavior(gfx::ElideBehavior elide_behavior) {
@@ -492,6 +509,15 @@ void Label::SetElideBehavior(gfx::ElideBehavior elide_behavior) {
OnPropertyChanged(&elide_behavior_, kPropertyEffectsPreferredSizeChanged);
}
@ -214,7 +214,7 @@ index 2c773355d2961..9ccba5a459bd5 100644
std::u16string Label::GetTooltipText() const {
return tooltip_text_;
}
@@ -789,6 +815,16 @@ std::unique_ptr<gfx::RenderText> Label::CreateRenderText() const {
@@ -796,6 +822,16 @@ std::unique_ptr<gfx::RenderText> Label::CreateRenderText() const {
render_text->SelectRange(stored_selection_range_);
}
@ -255,7 +255,7 @@ index 40d9a89b66369..0c7245665d31b 100644
std::unique_ptr<SelectionController> selection_controller_;
diff --git ui/views/controls/menu/menu_controller.cc ui/views/controls/menu/menu_controller.cc
index a3d188fdde094..afcb6fda0cabe 100644
index ef6a903caf5a9..c329a7684bfca 100644
--- ui/views/controls/menu/menu_controller.cc
+++ ui/views/controls/menu/menu_controller.cc
@@ -578,7 +578,8 @@ void MenuController::Run(Widget* parent,
@ -276,7 +276,7 @@ index a3d188fdde094..afcb6fda0cabe 100644
// Only create a MenuPreTargetHandler for non-nested menus. Nested menus
// will use the existing one.
@@ -2246,6 +2248,7 @@ void MenuController::OpenMenuImpl(MenuItemView* item, bool show) {
@@ -2247,6 +2249,7 @@ void MenuController::OpenMenuImpl(MenuItemView* item, bool show) {
params.do_capture = do_capture;
params.native_view_for_gestures = native_view_for_gestures_;
params.owned_window_anchor = anchor;
@ -284,7 +284,7 @@ index a3d188fdde094..afcb6fda0cabe 100644
if (item->GetParentMenuItem()) {
params.context = item->GetWidget();
// (crbug.com/1414232) The item to be open is a submenu. Make sure
@@ -2930,8 +2933,13 @@ MenuItemView* MenuController::FindInitialSelectableMenuItem(
@@ -2931,8 +2934,13 @@ MenuItemView* MenuController::FindInitialSelectableMenuItem(
void MenuController::OpenSubmenuChangeSelectionIfCan() {
MenuItemView* item = pending_state_.item;
@ -299,7 +299,7 @@ index a3d188fdde094..afcb6fda0cabe 100644
// Show the sub-menu.
SetSelection(item, SELECTION_OPEN_SUBMENU | SELECTION_UPDATE_IMMEDIATELY);
@@ -2951,8 +2959,10 @@ void MenuController::OpenSubmenuChangeSelectionIfCan() {
@@ -2952,8 +2960,10 @@ void MenuController::OpenSubmenuChangeSelectionIfCan() {
void MenuController::CloseSubmenu() {
MenuItemView* item = state_.item;
DCHECK(item);
@ -312,10 +312,10 @@ index a3d188fdde094..afcb6fda0cabe 100644
SetSelection(item, SELECTION_UPDATE_IMMEDIATELY);
else if (item->GetParentMenuItem()->GetParentMenuItem())
diff --git ui/views/controls/menu/menu_controller.h ui/views/controls/menu/menu_controller.h
index a051195134920..ef2a1dacb163c 100644
index 4c25ffcf9ab92..df270df5c024e 100644
--- ui/views/controls/menu/menu_controller.h
+++ ui/views/controls/menu/menu_controller.h
@@ -139,7 +139,9 @@ class VIEWS_EXPORT MenuController
@@ -137,7 +137,9 @@ class VIEWS_EXPORT MenuController final : public gfx::AnimationDelegate,
MenuAnchorPosition position,
bool context_menu,
bool is_nested_drag,
@ -326,7 +326,7 @@ index a051195134920..ef2a1dacb163c 100644
bool for_drop() const { return for_drop_; }
@@ -736,6 +738,8 @@ class VIEWS_EXPORT MenuController
@@ -738,6 +740,8 @@ class VIEWS_EXPORT MenuController final : public gfx::AnimationDelegate,
// RunType::SEND_GESTURE_EVENTS_TO_OWNER is set.
gfx::NativeView native_view_for_gestures_ = gfx::NativeView();
@ -375,10 +375,10 @@ index 0623d151ddd3e..243e8c573e474 100644
virtual int GetMaxWidthForMenu(MenuItemView* menu);
diff --git ui/views/controls/menu/menu_host.cc ui/views/controls/menu/menu_host.cc
index b42556c290207..c5c1aedb9df58 100644
index c7c9deb69dbba..0edd342c9a713 100644
--- ui/views/controls/menu/menu_host.cc
+++ ui/views/controls/menu/menu_host.cc
@@ -144,6 +144,8 @@ void MenuHost::InitMenuHost(const InitParams& init_params) {
@@ -145,6 +145,8 @@ void MenuHost::InitMenuHost(const InitParams& init_params) {
: gfx::NativeWindow();
params.bounds = init_params.bounds;
@ -387,7 +387,7 @@ index b42556c290207..c5c1aedb9df58 100644
#if defined(USE_AURA)
params.init_properties_container.SetProperty(aura::client::kOwnedWindowAnchor,
init_params.owned_window_anchor);
@@ -151,7 +153,8 @@ void MenuHost::InitMenuHost(const InitParams& init_params) {
@@ -152,7 +154,8 @@ void MenuHost::InitMenuHost(const InitParams& init_params) {
// If MenuHost has no parent widget, it needs to be marked
// Activatable, so that calling Show in ShowMenuHost will
// get keyboard focus.
@ -411,10 +411,10 @@ index fc1d5fccc3845..c065cafcd537c 100644
explicit MenuHost(SubmenuView* submenu);
diff --git ui/views/controls/menu/menu_item_view.cc ui/views/controls/menu/menu_item_view.cc
index 7bc2882ee70ad..ee71d64dce415 100644
index 6377bb1fe7a6c..9f20510d92c80 100644
--- ui/views/controls/menu/menu_item_view.cc
+++ ui/views/controls/menu/menu_item_view.cc
@@ -1079,6 +1079,15 @@ void MenuItemView::PaintBackground(gfx::Canvas* canvas,
@@ -1076,6 +1076,15 @@ void MenuItemView::PaintBackground(gfx::Canvas* canvas,
spilling_rect.set_y(spilling_rect.y() - corner_radius_);
spilling_rect.set_height(spilling_rect.height() + corner_radius_);
canvas->DrawRoundRect(spilling_rect, corner_radius_, flags);
@ -430,7 +430,7 @@ index 7bc2882ee70ad..ee71d64dce415 100644
} else if (paint_as_selected) {
gfx::Rect item_bounds = GetLocalBounds();
if (type_ == Type::kActionableSubMenu) {
@@ -1143,6 +1152,13 @@ void MenuItemView::PaintMinorIconAndText(gfx::Canvas* canvas, SkColor color) {
@@ -1140,6 +1149,13 @@ void MenuItemView::PaintMinorIconAndText(gfx::Canvas* canvas, SkColor color) {
}
SkColor MenuItemView::GetTextColor(bool minor, bool paint_as_selected) const {
@ -445,7 +445,7 @@ index 7bc2882ee70ad..ee71d64dce415 100644
// use the default color.
if (!paint_as_selected && foreground_color_id_.has_value()) {
diff --git ui/views/controls/menu/menu_model_adapter.cc ui/views/controls/menu/menu_model_adapter.cc
index 4babab46bc156..3de7f0891eeaf 100644
index d6a9c662edb9b..7bba7ca1cae5f 100644
--- ui/views/controls/menu/menu_model_adapter.cc
+++ ui/views/controls/menu/menu_model_adapter.cc
@@ -4,6 +4,7 @@
@ -456,7 +456,7 @@ index 4babab46bc156..3de7f0891eeaf 100644
#include <list>
#include <memory>
#include <utility>
@@ -237,6 +238,76 @@ bool MenuModelAdapter::IsItemChecked(int id) const {
@@ -236,6 +237,75 @@ bool MenuModelAdapter::IsItemChecked(int id) const {
return model->IsItemCheckedAt(index);
}
@ -474,7 +474,6 @@ index 4babab46bc156..3de7f0891eeaf 100644
+ }
+
+ NOTREACHED();
+ return nullptr;
+}
+
+void MenuModelAdapter::OnUnhandledOpenSubmenu(MenuItemView* menu,
@ -791,7 +790,7 @@ index dcf4b60ad92c2..64fa80edefc1b 100644
#if !BUILDFLAG(IS_CHROMEOS_LACROS)
if (root_location != root_current_location &&
diff --git ui/views/view.h ui/views/view.h
index 4024ec9778c21..d4eeb4c2922e1 100644
index 1a8ad95eed953..a1fa62ac5dcc4 100644
--- ui/views/view.h
+++ ui/views/view.h
@@ -25,6 +25,7 @@

View File

@ -1,8 +1,8 @@
diff --git ui/views/controls/textfield/textfield.cc ui/views/controls/textfield/textfield.cc
index c8a4f5805248c..a9f693b357fb9 100644
index f53fd1e03bdb2..5572b3d2cccc4 100644
--- ui/views/controls/textfield/textfield.cc
+++ ui/views/controls/textfield/textfield.cc
@@ -2973,6 +2973,10 @@ void Textfield::OnCursorBlinkTimerFired() {
@@ -2990,6 +2990,10 @@ void Textfield::OnCursorBlinkTimerFired() {
void Textfield::OnEnabledChanged() {
if (GetInputMethod())
GetInputMethod()->OnTextInputTypeChanged(this);

View File

@ -1,8 +1,8 @@
diff --git chrome/browser/extensions/api/sessions/sessions_api.cc chrome/browser/extensions/api/sessions/sessions_api.cc
index 23722ce395352..e7e7d70dd312c 100644
index 0efd00ba92039..7dc86733bcde3 100644
--- chrome/browser/extensions/api/sessions/sessions_api.cc
+++ chrome/browser/extensions/api/sessions/sessions_api.cc
@@ -333,6 +333,7 @@ SessionsGetDevicesFunction::CreateWindowModel(
@@ -334,6 +334,7 @@ SessionsGetDevicesFunction::CreateWindowModel(
state = api::windows::WindowState::kNormal;
break;
case ui::SHOW_STATE_MINIMIZED:
@ -23,7 +23,7 @@ index cef40af382b1e..a2cf4691edc37 100644
case ui::SHOW_STATE_END:
return ui::SHOW_STATE_NORMAL;
diff --git components/sessions/core/session_service_commands.cc components/sessions/core/session_service_commands.cc
index 124bf0bf470e5..30845be4a6a88 100644
index 618e95c4e4b10..028612a57382e 100644
--- components/sessions/core/session_service_commands.cc
+++ components/sessions/core/session_service_commands.cc
@@ -165,9 +165,10 @@ enum PersistedWindowShowState {
@ -49,7 +49,7 @@ index 124bf0bf470e5..30845be4a6a88 100644
case ui::SHOW_STATE_MAXIMIZED:
return PERSISTED_SHOW_STATE_MAXIMIZED;
diff --git components/sessions/core/tab_restore_service_impl.cc components/sessions/core/tab_restore_service_impl.cc
index 552bf87379e34..b37e04b676de7 100644
index 791fc1874851e..db58beed440f8 100644
--- components/sessions/core/tab_restore_service_impl.cc
+++ components/sessions/core/tab_restore_service_impl.cc
@@ -197,6 +197,7 @@ int SerializeWindowShowState(ui::WindowShowState show_state) {
@ -61,10 +61,10 @@ index 552bf87379e34..b37e04b676de7 100644
case ui::SHOW_STATE_MAXIMIZED:
return kSerializedShowStateMaximized;
diff --git content/browser/renderer_host/render_widget_host_view_base.cc content/browser/renderer_host/render_widget_host_view_base.cc
index 60d2748ffebf8..cb16f27ee8d5f 100644
index c9b1737f91452..7231c79be3bdc 100644
--- content/browser/renderer_host/render_widget_host_view_base.cc
+++ content/browser/renderer_host/render_widget_host_view_base.cc
@@ -674,6 +674,14 @@ float RenderWidgetHostViewBase::GetScaleOverrideForCapture() const {
@@ -677,6 +677,14 @@ float RenderWidgetHostViewBase::GetScaleOverrideForCapture() const {
return scale_override_for_capture_;
}
@ -80,7 +80,7 @@ index 60d2748ffebf8..cb16f27ee8d5f 100644
if (!GetMouseWheelPhaseHandler())
return;
diff --git content/browser/renderer_host/render_widget_host_view_base.h content/browser/renderer_host/render_widget_host_view_base.h
index 36ed537b555aa..2cf5fe3b03f0d 100644
index 1a7932a580836..7ceb1b03ce36c 100644
--- content/browser/renderer_host/render_widget_host_view_base.h
+++ content/browser/renderer_host/render_widget_host_view_base.h
@@ -72,6 +72,7 @@ class CursorManager;
@ -91,7 +91,7 @@ index 36ed537b555aa..2cf5fe3b03f0d 100644
class RenderWidgetHostViewInputObserver;
class ScopedViewTransitionResources;
class TextInputManager;
@@ -194,6 +195,9 @@ class CONTENT_EXPORT RenderWidgetHostViewBase
@@ -195,6 +196,9 @@ class CONTENT_EXPORT RenderWidgetHostViewBase
float GetDeviceScaleFactor() const final;
bool IsPointerLocked() override;
@ -101,7 +101,7 @@ index 36ed537b555aa..2cf5fe3b03f0d 100644
// Identical to `CopyFromSurface()`, except that this method issues the
// `viz::CopyOutputRequest` against the exact `viz::Surface` currently
// embedded by this View, while `CopyFromSurface()` may return a copy of any
@@ -255,6 +259,10 @@ class CONTENT_EXPORT RenderWidgetHostViewBase
@@ -256,6 +260,10 @@ class CONTENT_EXPORT RenderWidgetHostViewBase
// Called when screen information or native widget bounds change.
virtual void UpdateScreenInfo();
@ -112,7 +112,7 @@ index 36ed537b555aa..2cf5fe3b03f0d 100644
// Called by the TextInputManager to notify the view about being removed from
// the list of registered views, i.e., TextInputManager is no longer tracking
// TextInputState from this view. The RWHV should reset |text_input_manager_|
@@ -383,6 +391,12 @@ class CONTENT_EXPORT RenderWidgetHostViewBase
@@ -384,6 +392,12 @@ class CONTENT_EXPORT RenderWidgetHostViewBase
const gfx::Rect& bounds,
const gfx::Rect& anchor_rect) = 0;
@ -125,7 +125,7 @@ index 36ed537b555aa..2cf5fe3b03f0d 100644
// Indicates whether the page has finished loading.
virtual void SetIsLoading(bool is_loading) = 0;
@@ -645,6 +659,10 @@ class CONTENT_EXPORT RenderWidgetHostViewBase
@@ -649,6 +663,10 @@ class CONTENT_EXPORT RenderWidgetHostViewBase
// to all displays.
gfx::Size system_cursor_size_;
@ -136,7 +136,7 @@ index 36ed537b555aa..2cf5fe3b03f0d 100644
private:
FRIEND_TEST_ALL_PREFIXES(
BrowserSideFlingBrowserTest,
@@ -666,10 +684,6 @@ class CONTENT_EXPORT RenderWidgetHostViewBase
@@ -670,10 +688,6 @@ class CONTENT_EXPORT RenderWidgetHostViewBase
void SynchronizeVisualProperties();
@ -148,7 +148,7 @@ index 36ed537b555aa..2cf5fe3b03f0d 100644
// renderer process changes. This method is called before notifying
// RenderWidgetHostImpl in order to allow the view to allocate a new
diff --git content/browser/renderer_host/render_widget_host_view_event_handler.cc content/browser/renderer_host/render_widget_host_view_event_handler.cc
index d1df19bfcb6c9..c55b89a119046 100644
index dc28ddd51c86b..4ecdf11c67d1f 100644
--- content/browser/renderer_host/render_widget_host_view_event_handler.cc
+++ content/browser/renderer_host/render_widget_host_view_event_handler.cc
@@ -52,6 +52,10 @@ namespace {
@ -215,10 +215,10 @@ index b4ff7c11d8e3c..b21417f89e6e1 100644
// Set the view's active state (i.e., tint state of controls).
virtual void SetActive(bool active) = 0;
diff --git ui/aura/native_window_occlusion_tracker_win.cc ui/aura/native_window_occlusion_tracker_win.cc
index 0893f87550cc9..2a52012e5059d 100644
index e9bb4ee5bccee..e6172b1a8d53f 100644
--- ui/aura/native_window_occlusion_tracker_win.cc
+++ ui/aura/native_window_occlusion_tracker_win.cc
@@ -101,6 +101,13 @@ void NativeWindowOcclusionTrackerWin::Enable(Window* window) {
@@ -102,6 +102,13 @@ void NativeWindowOcclusionTrackerWin::Enable(Window* window) {
// when it's no longer true that all windows are minimized, and when the
// window is destroyed.
HWND root_window_hwnd = window->GetHost()->GetAcceleratedWidget();
@ -233,7 +233,7 @@ index 0893f87550cc9..2a52012e5059d 100644
// Remember this mapping from hwnd to Window*.
hwnd_root_window_map_[root_window_hwnd] = window;
diff --git ui/base/mojom/ui_base_types_mojom_traits.h ui/base/mojom/ui_base_types_mojom_traits.h
index 1d79fc2dc34cc..ce5bf0ebf531f 100644
index b2a480b1717d1..306a4e3b1abc4 100644
--- ui/base/mojom/ui_base_types_mojom_traits.h
+++ ui/base/mojom/ui_base_types_mojom_traits.h
@@ -172,6 +172,7 @@ struct EnumTraits<ui::mojom::WindowShowState, ui::WindowShowState> {
@ -259,10 +259,10 @@ index 2cf9330a4e24b..4bf0890ae000b 100644
// Specifies which edges of the window are tiled.
diff --git ui/ozone/platform/x11/x11_window.cc ui/ozone/platform/x11/x11_window.cc
index f1c5f06fb2966..649a206664a00 100644
index 4907de4e24cea..9824c17378207 100644
--- ui/ozone/platform/x11/x11_window.cc
+++ ui/ozone/platform/x11/x11_window.cc
@@ -1862,7 +1862,8 @@ void X11Window::CreateXWindow(const PlatformWindowInitProperties& properties) {
@@ -1864,7 +1864,8 @@ void X11Window::CreateXWindow(const PlatformWindowInitProperties& properties) {
req.border_pixel = 0;
bounds_in_pixels_ = SanitizeBounds(bounds);
@ -350,7 +350,7 @@ index e698f71577c51..8a6e28128564d 100644
base::WeakPtrFactory<DesktopWindowTreeHostLinux> weak_factory_{this};
};
diff --git ui/views/widget/desktop_aura/desktop_window_tree_host_platform.cc ui/views/widget/desktop_aura/desktop_window_tree_host_platform.cc
index 389e7186c3429..38f7c34326ef9 100644
index 30781b584b649..6edaa60e652ab 100644
--- ui/views/widget/desktop_aura/desktop_window_tree_host_platform.cc
+++ ui/views/widget/desktop_aura/desktop_window_tree_host_platform.cc
@@ -281,8 +281,8 @@ void DesktopWindowTreeHostPlatform::Init(const Widget::InitParams& params) {
@ -365,7 +365,7 @@ index 389e7186c3429..38f7c34326ef9 100644
// Calculate initial bounds.
diff --git ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc
index 288a76d86ed87..1fd024d1645c3 100644
index e24cb885f357c..f6998f9720124 100644
--- ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc
+++ ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc
@@ -20,6 +20,7 @@
@ -499,10 +499,10 @@ index 288a76d86ed87..1fd024d1645c3 100644
}
diff --git ui/views/widget/desktop_aura/desktop_window_tree_host_win.h ui/views/widget/desktop_aura/desktop_window_tree_host_win.h
index 8d5b01098915d..ae5b6a2193031 100644
index 8169f17982253..fd8c22449a6a3 100644
--- ui/views/widget/desktop_aura/desktop_window_tree_host_win.h
+++ ui/views/widget/desktop_aura/desktop_window_tree_host_win.h
@@ -322,6 +322,14 @@ class VIEWS_EXPORT DesktopWindowTreeHostWin
@@ -324,6 +324,14 @@ class VIEWS_EXPORT DesktopWindowTreeHostWin
// True if the window should have the frame removed.
bool remove_standard_frame_;
@ -518,7 +518,7 @@ index 8d5b01098915d..ae5b6a2193031 100644
// the implementation of ::ShowCursor() is based on a counter, so making this
// member static ensures that ::ShowCursor() is always called exactly once
diff --git ui/views/widget/native_widget_mac.mm ui/views/widget/native_widget_mac.mm
index 6383110804d44..e5bc85f63fab9 100644
index 3698346dcf4c0..96365d3f28179 100644
--- ui/views/widget/native_widget_mac.mm
+++ ui/views/widget/native_widget_mac.mm
@@ -640,6 +640,7 @@ void NativeWidgetMac::Show(ui::WindowShowState show_state,
@ -530,10 +530,10 @@ index 6383110804d44..e5bc85f63fab9 100644
break;
case ui::SHOW_STATE_END:
diff --git ui/views/widget/widget.cc ui/views/widget/widget.cc
index f2f1f54c474cf..2feb6a47c04e1 100644
index 8009dcfd98dac..5ee39207d190d 100644
--- ui/views/widget/widget.cc
+++ ui/views/widget/widget.cc
@@ -409,7 +409,8 @@ void Widget::Init(InitParams params) {
@@ -412,7 +412,8 @@ void Widget::Init(InitParams params) {
}
params.child |= (params.type == InitParams::TYPE_CONTROL);
@ -543,7 +543,7 @@ index f2f1f54c474cf..2feb6a47c04e1 100644
is_headless_ = params.ShouldInitAsHeadless();
is_autosized_ = params.autosize;
@@ -501,9 +502,14 @@ void Widget::Init(InitParams params) {
@@ -508,9 +509,14 @@ void Widget::Init(InitParams params) {
if (show_state == ui::SHOW_STATE_MAXIMIZED) {
Maximize();
@ -558,7 +558,7 @@ index f2f1f54c474cf..2feb6a47c04e1 100644
}
#if BUILDFLAG(IS_CHROMEOS_ASH)
@@ -517,7 +523,12 @@ void Widget::Init(InitParams params) {
@@ -524,7 +530,12 @@ void Widget::Init(InitParams params) {
} else if (delegate) {
SetContentsView(delegate->TransferOwnershipOfContentsView());
if (should_set_initial_bounds) {
@ -572,7 +572,7 @@ index f2f1f54c474cf..2feb6a47c04e1 100644
}
}
@@ -1696,10 +1707,16 @@ void Widget::OnNativeWidgetParentChanged(gfx::NativeView parent) {
@@ -1714,10 +1725,16 @@ void Widget::OnNativeWidgetParentChanged(gfx::NativeView parent) {
}
gfx::Size Widget::GetMinimumSize() const {
@ -589,7 +589,7 @@ index f2f1f54c474cf..2feb6a47c04e1 100644
return non_client_view_ ? non_client_view_->GetMaximumSize() : gfx::Size();
}
@@ -1950,7 +1967,8 @@ bool Widget::SetInitialFocus(ui::WindowShowState show_state) {
@@ -1968,7 +1985,8 @@ bool Widget::SetInitialFocus(ui::WindowShowState show_state) {
return false;
View* v = widget_delegate_->GetInitiallyFocusedView();
if (!focus_on_creation_ || show_state == ui::SHOW_STATE_INACTIVE ||
@ -600,10 +600,10 @@ index f2f1f54c474cf..2feb6a47c04e1 100644
// focus when the window is restored.
if (v)
diff --git ui/views/widget/widget.h ui/views/widget/widget.h
index 68c2ac9da74ac..94f75266c6917 100644
index e6e8e42178d1a..ab30be8f29dff 100644
--- ui/views/widget/widget.h
+++ ui/views/widget/widget.h
@@ -358,6 +358,8 @@ class VIEWS_EXPORT Widget : public internal::NativeWidgetDelegate,
@@ -368,6 +368,8 @@ class VIEWS_EXPORT Widget : public internal::NativeWidgetDelegate,
// the concept with bubble anchoring a la BubbleDialogDelegateView.
gfx::NativeView parent = gfx::NativeView();
@ -612,7 +612,7 @@ index 68c2ac9da74ac..94f75266c6917 100644
// Specifies the initial bounds of the Widget. Default is empty, which means
// the NativeWidget may specify a default size. If the parent is specified,
// |bounds| is in the parent's coordinate system. If the parent is not
@@ -764,7 +766,7 @@ class VIEWS_EXPORT Widget : public internal::NativeWidgetDelegate,
@@ -774,7 +776,7 @@ class VIEWS_EXPORT Widget : public internal::NativeWidgetDelegate,
void ShowInactive();
// Activates the widget, assuming it already exists and is visible.

View File

@ -1,5 +1,5 @@
diff --git components/viz/host/host_display_client.cc components/viz/host/host_display_client.cc
index 0ef41b4efc339..a1c1ea6a00fc1 100644
index 0ad0fcd3d3ab1..16c9fd0360d80 100644
--- components/viz/host/host_display_client.cc
+++ components/viz/host/host_display_client.cc
@@ -48,9 +48,14 @@ void HostDisplayClient::OnDisplayReceivedCALayerParams(
@ -28,7 +28,7 @@ index 0ef41b4efc339..a1c1ea6a00fc1 100644
+#if BUILDFLAG(IS_WIN)
void HostDisplayClient::AddChildWindowToBrowser(
gpu::SurfaceHandle child_window) {
NOTREACHED();
NOTREACHED_IN_MIGRATION();
diff --git components/viz/host/host_display_client.h components/viz/host/host_display_client.h
index cb16487f9fc08..6191f8801f302 100644
--- components/viz/host/host_display_client.h
@ -80,7 +80,7 @@ index 8af69cac78b74..9f74e511c263d 100644
private:
const HWND hwnd_;
diff --git components/viz/service/BUILD.gn components/viz/service/BUILD.gn
index 35b6474193b3f..55b518fe138cc 100644
index f28503c3bd02b..7a474b9839e46 100644
--- components/viz/service/BUILD.gn
+++ components/viz/service/BUILD.gn
@@ -253,6 +253,8 @@ viz_component("service") {
@ -93,7 +93,7 @@ index 35b6474193b3f..55b518fe138cc 100644
defines = [ "VIZ_SERVICE_IMPLEMENTATION" ]
diff --git components/viz/service/display_embedder/output_surface_provider_impl.cc components/viz/service/display_embedder/output_surface_provider_impl.cc
index e8e3237bb2b8f..cec146af141ba 100644
index 54a83ba9fe1e9..e5520ccf6265d 100644
--- components/viz/service/display_embedder/output_surface_provider_impl.cc
+++ components/viz/service/display_embedder/output_surface_provider_impl.cc
@@ -18,6 +18,7 @@
@ -150,10 +150,10 @@ index 796ae2688436e..37a3406790210 100644
TRACE_EVENT_ASYNC_BEGIN0("viz", "SoftwareOutputDeviceWinProxy::Draw", this);
diff --git content/browser/compositor/viz_process_transport_factory.cc content/browser/compositor/viz_process_transport_factory.cc
index 3634618a687b3..3a568135f6a0f 100644
index 2ea7347d2abe0..ab412fabe399b 100644
--- content/browser/compositor/viz_process_transport_factory.cc
+++ content/browser/compositor/viz_process_transport_factory.cc
@@ -385,8 +385,13 @@ void VizProcessTransportFactory::OnEstablishedGpuChannel(
@@ -390,8 +390,13 @@ void VizProcessTransportFactory::OnEstablishedGpuChannel(
mojo::AssociatedRemote<viz::mojom::DisplayPrivate> display_private;
root_params->display_private =
display_private.BindNewEndpointAndPassReceiver();

View File

@ -1,8 +1,8 @@
diff --git content/browser/web_contents/web_contents_impl.cc content/browser/web_contents/web_contents_impl.cc
index d08ad3ae25ab3..0979551ef5fcb 100644
index 205a1bb692091..d5cf0a22b11b2 100644
--- content/browser/web_contents/web_contents_impl.cc
+++ content/browser/web_contents/web_contents_impl.cc
@@ -3578,6 +3578,12 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params,
@@ -3610,6 +3610,12 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params,
params.main_frame_name, GetOpener(), primary_main_frame_policy,
base::UnguessableToken::Create());
@ -15,7 +15,7 @@ index d08ad3ae25ab3..0979551ef5fcb 100644
std::unique_ptr<WebContentsViewDelegate> delegate =
GetContentClient()->browser()->GetWebContentsViewDelegate(this);
@@ -3588,6 +3594,7 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params,
@@ -3620,6 +3626,7 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params,
view_ = CreateWebContentsView(this, std::move(delegate),
&render_view_host_delegate_view_);
}
@ -23,7 +23,7 @@ index d08ad3ae25ab3..0979551ef5fcb 100644
CHECK(render_view_host_delegate_view_);
CHECK(view_.get());
@@ -3784,6 +3791,9 @@ void WebContentsImpl::RenderWidgetCreated(
@@ -3816,6 +3823,9 @@ void WebContentsImpl::RenderWidgetCreated(
OPTIONAL_TRACE_EVENT1("content", "WebContentsImpl::RenderWidgetCreated",
"render_widget_host", render_widget_host);
created_widgets_.insert(render_widget_host);
@ -33,7 +33,7 @@ index d08ad3ae25ab3..0979551ef5fcb 100644
}
void WebContentsImpl::RenderWidgetDeleted(
@@ -4632,6 +4642,15 @@ FrameTree* WebContentsImpl::CreateNewWindow(
@@ -4678,6 +4688,15 @@ FrameTree* WebContentsImpl::CreateNewWindow(
create_params.picture_in_picture_options = *(params.pip_options);
}
@ -49,7 +49,7 @@ index d08ad3ae25ab3..0979551ef5fcb 100644
// Check whether there is an available prerendered page for this navigation if
// this is not for guest. If it exists, take WebContents pre-created for
// hosting the prerendered page instead of creating new WebContents.
@@ -8955,6 +8974,9 @@ void WebContentsImpl::SetFocusedFrame(FrameTreeNode* node,
@@ -9008,6 +9027,9 @@ void WebContentsImpl::SetFocusedFrame(FrameTreeNode* node,
}
CloseListenerManager::DidChangeFocusedFrame(this);
@ -58,12 +58,12 @@ index d08ad3ae25ab3..0979551ef5fcb 100644
+ node->current_frame_host());
}
void WebContentsImpl::DidCallFocus() {
FrameTree* WebContentsImpl::GetOwnedPictureInPictureFrameTree() {
diff --git content/public/browser/web_contents.h content/public/browser/web_contents.h
index 629b699461464..04d2008af250f 100644
index 1ee36913ac37c..19b13abaf0679 100644
--- content/public/browser/web_contents.h
+++ content/public/browser/web_contents.h
@@ -104,10 +104,12 @@ class BrowserContext;
@@ -105,10 +105,12 @@ class BrowserContext;
class BrowserPluginGuestDelegate;
class RenderFrameHost;
class RenderViewHost;
@ -76,7 +76,7 @@ index 629b699461464..04d2008af250f 100644
class WebUI;
struct DropData;
struct MHTMLGenerationParams;
@@ -254,6 +256,10 @@ class WebContents : public PageNavigator,
@@ -255,6 +257,10 @@ class WebContents : public PageNavigator,
network::mojom::WebSandboxFlags starting_sandbox_flags =
network::mojom::WebSandboxFlags::kNone;
@ -88,7 +88,7 @@ index 629b699461464..04d2008af250f 100644
// the value that'll be returned by GetLastActiveTime(). If this is left
// default initialized then the value is not passed on to the WebContents
diff --git content/public/browser/web_contents_delegate.h content/public/browser/web_contents_delegate.h
index 7c43ffab6a865..608c87ace18d5 100644
index fd851a9347dd6..82abe6dd2fd07 100644
--- content/public/browser/web_contents_delegate.h
+++ content/public/browser/web_contents_delegate.h
@@ -63,9 +63,11 @@ class EyeDropperListener;
@ -103,7 +103,7 @@ index 7c43ffab6a865..608c87ace18d5 100644
struct ContextMenuParams;
struct DropData;
struct MediaPlayerWatchTime;
@@ -355,6 +357,14 @@ class CONTENT_EXPORT WebContentsDelegate {
@@ -358,6 +360,14 @@ class CONTENT_EXPORT WebContentsDelegate {
const StoragePartitionConfig& partition_config,
SessionStorageNamespace* session_storage_namespace);

View File

@ -1,8 +1,8 @@
diff --git third_party/blink/public/platform/platform.h third_party/blink/public/platform/platform.h
index 38c079e1f9c37..6a029e131a870 100644
index 86a9cc130b215..74322f90420f6 100644
--- third_party/blink/public/platform/platform.h
+++ third_party/blink/public/platform/platform.h
@@ -780,6 +780,11 @@ class BLINK_PLATFORM_EXPORT Platform {
@@ -787,6 +787,11 @@ class BLINK_PLATFORM_EXPORT Platform {
}
#endif
@ -15,7 +15,7 @@ index 38c079e1f9c37..6a029e131a870 100644
static void InitializeMainThreadCommon(
Platform* platform,
diff --git third_party/blink/renderer/core/inspector/devtools_session.cc third_party/blink/renderer/core/inspector/devtools_session.cc
index 912eb6434368a..ae58f9e10355d 100644
index 9f9a6aa7c7a73..2cc5e50b7406b 100644
--- third_party/blink/renderer/core/inspector/devtools_session.cc
+++ third_party/blink/renderer/core/inspector/devtools_session.cc
@@ -11,6 +11,7 @@

View File

@ -1,8 +1,8 @@
diff --git third_party/blink/public/web/web_view.h third_party/blink/public/web/web_view.h
index 6dfc5bef7ed41..493781d809a35 100644
index a1197832494af..7ba707ef9c442 100644
--- third_party/blink/public/web/web_view.h
+++ third_party/blink/public/web/web_view.h
@@ -349,6 +349,7 @@ class BLINK_EXPORT WebView {
@@ -337,6 +337,7 @@ class BLINK_EXPORT WebView {
// Sets whether select popup menus should be rendered by the browser.
static void SetUseExternalPopupMenus(bool);
@ -11,10 +11,10 @@ index 6dfc5bef7ed41..493781d809a35 100644
// Cancels and hides the current popup (datetime, select...) if any.
virtual void CancelPagePopup() = 0;
diff --git third_party/blink/renderer/core/exported/web_view_impl.cc third_party/blink/renderer/core/exported/web_view_impl.cc
index 173ca5a588d8b..092094e89eef0 100644
index 65c00aae8e04a..6ab9760efcc52 100644
--- third_party/blink/renderer/core/exported/web_view_impl.cc
+++ third_party/blink/renderer/core/exported/web_view_impl.cc
@@ -251,8 +251,13 @@ void WebView::SetUseExternalPopupMenus(bool use_external_popup_menus) {
@@ -252,8 +252,13 @@ void WebView::SetUseExternalPopupMenus(bool use_external_popup_menus) {
g_should_use_external_popup_menus = use_external_popup_menus;
}
@ -30,7 +30,7 @@ index 173ca5a588d8b..092094e89eef0 100644
}
namespace {
@@ -584,6 +589,7 @@ WebViewImpl::WebViewImpl(
@@ -586,6 +591,7 @@ WebViewImpl::WebViewImpl(
chrome_client_(MakeGarbageCollected<ChromeClientImpl>(this)),
minimum_zoom_level_(PageZoomFactorToZoomLevel(kMinimumPageZoomFactor)),
maximum_zoom_level_(PageZoomFactorToZoomLevel(kMaximumPageZoomFactor)),
@ -39,10 +39,10 @@ index 173ca5a588d8b..092094e89eef0 100644
fullscreen_controller_(std::make_unique<FullscreenController>(this)),
page_base_background_color_(
diff --git third_party/blink/renderer/core/exported/web_view_impl.h third_party/blink/renderer/core/exported/web_view_impl.h
index d6bfd9b670d03..fa01890543ceb 100644
index 0a1db1e8faa6b..5369bac9c60cb 100644
--- third_party/blink/renderer/core/exported/web_view_impl.h
+++ third_party/blink/renderer/core/exported/web_view_impl.h
@@ -139,7 +139,8 @@ class CORE_EXPORT WebViewImpl final : public WebView,
@@ -140,7 +140,8 @@ class CORE_EXPORT WebViewImpl final : public WebView,
static HashSet<WebViewImpl*>& AllInstances();
// Returns true if popup menus should be rendered by the browser, false if
// they should be rendered by WebKit (which is the default).
@ -52,7 +52,7 @@ index d6bfd9b670d03..fa01890543ceb 100644
// Returns whether frames under this WebView are backed by a compositor.
bool does_composite() const { return does_composite_; }
@@ -871,6 +872,8 @@ class CORE_EXPORT WebViewImpl final : public WebView,
@@ -872,6 +873,8 @@ class CORE_EXPORT WebViewImpl final : public WebView,
float fake_page_scale_animation_page_scale_factor_ = 0.f;
bool fake_page_scale_animation_use_anchor_ = false;
@ -62,10 +62,10 @@ index d6bfd9b670d03..fa01890543ceb 100644
gfx::Transform device_emulation_transform_;
diff --git third_party/blink/renderer/core/page/chrome_client_impl.cc third_party/blink/renderer/core/page/chrome_client_impl.cc
index 1144e63a6d394..5773f6da9333d 100644
index 1a299dabd80be..e8997cd629aee 100644
--- third_party/blink/renderer/core/page/chrome_client_impl.cc
+++ third_party/blink/renderer/core/page/chrome_client_impl.cc
@@ -987,7 +987,7 @@ PopupMenu* ChromeClientImpl::OpenPopupMenu(LocalFrame& frame,
@@ -988,7 +988,7 @@ PopupMenu* ChromeClientImpl::OpenPopupMenu(LocalFrame& frame,
HTMLSelectElement& select) {
NotifyPopupOpeningObservers();

View File

@ -1,8 +1,8 @@
diff --git third_party/blink/renderer/build/scripts/templates/runtime_enabled_features.h.tmpl third_party/blink/renderer/build/scripts/templates/runtime_enabled_features.h.tmpl
index 1f8a978367a46..6f073aa18151e 100644
index 56abb01572e0e..0fd747f75f7cf 100644
--- third_party/blink/renderer/build/scripts/templates/runtime_enabled_features.h.tmpl
+++ third_party/blink/renderer/build/scripts/templates/runtime_enabled_features.h.tmpl
@@ -14,6 +14,8 @@
@@ -13,6 +13,8 @@
#include "third_party/blink/renderer/platform/platform_export.h"
#include "third_party/blink/renderer/platform/wtf/allocator/allocator.h"
@ -11,7 +11,7 @@ index 1f8a978367a46..6f073aa18151e 100644
#define ASSERT_ORIGIN_TRIAL(feature) \
static_assert(std::is_same<decltype(::blink::RuntimeEnabledFeatures:: \
feature##EnabledByRuntimeFlag()), \
@@ -134,6 +136,7 @@ class PLATFORM_EXPORT RuntimeEnabledFeatures : public RuntimeEnabledFeaturesBase
@@ -125,6 +127,7 @@ class PLATFORM_EXPORT RuntimeEnabledFeatures : public RuntimeEnabledFeaturesBase
// protected section of RuntimeEnabledFeaturesBase. Normally, unit tests
// should use the ScopedFeatureNameForTest classes defined in
// platform/testing/runtime_enabled_features_test_helpers.h.

View File

@ -1,5 +1,5 @@
diff --git chrome/browser/feedback/system_logs/log_sources/chrome_internal_log_source.cc chrome/browser/feedback/system_logs/log_sources/chrome_internal_log_source.cc
index 16c370e6d9759..7fc6d74075dd4 100644
index 49a9705d3310a..f87fae993baf9 100644
--- chrome/browser/feedback/system_logs/log_sources/chrome_internal_log_source.cc
+++ chrome/browser/feedback/system_logs/log_sources/chrome_internal_log_source.cc
@@ -20,10 +20,12 @@
@ -15,7 +15,7 @@ index 16c370e6d9759..7fc6d74075dd4 100644
#include "chrome/browser/browser_process.h"
#include "chrome/browser/extensions/chrome_content_browser_client_extensions_part.h"
#include "chrome/browser/google/google_brand.h"
@@ -422,7 +424,15 @@ void ChromeInternalLogSource::Fetch(SysLogsSourceCallback callback) {
@@ -420,7 +422,15 @@ void ChromeInternalLogSource::Fetch(SysLogsSourceCallback callback) {
response->emplace(kOsVersionTag, os_version);
#endif
@ -31,7 +31,7 @@ index 16c370e6d9759..7fc6d74075dd4 100644
PopulateExtensionInfoLogs(response.get());
PopulatePowerApiLogs(response.get());
#if BUILDFLAG(IS_WIN)
@@ -510,8 +520,14 @@ void ChromeInternalLogSource::PopulateExtensionInfoLogs(
@@ -508,8 +518,14 @@ void ChromeInternalLogSource::PopulateExtensionInfoLogs(
if (!profile)
return;
@ -46,7 +46,7 @@ index 16c370e6d9759..7fc6d74075dd4 100644
std::string extensions_list;
for (const scoped_refptr<const extensions::Extension>& extension :
extension_registry->enabled_extensions()) {
@@ -612,6 +628,8 @@ void ChromeInternalLogSource::PopulateOnboardingTime(
@@ -610,6 +626,8 @@ void ChromeInternalLogSource::PopulateOnboardingTime(
#if BUILDFLAG(IS_WIN)
void ChromeInternalLogSource::PopulateUsbKeyboardDetected(
SystemLogsResponse* response) {
@ -56,7 +56,7 @@ index 16c370e6d9759..7fc6d74075dd4 100644
bool result =
base::win::IsKeyboardPresentOnSlate(ui::GetHiddenWindow(), &reason);
diff --git chrome/browser/memory_details.cc chrome/browser/memory_details.cc
index 362542c0af479..1841cbe14d5b6 100644
index 3ba0a09109a8b..db64d5cffc02e 100644
--- chrome/browser/memory_details.cc
+++ chrome/browser/memory_details.cc
@@ -17,6 +17,7 @@

View File

@ -1,39 +0,0 @@
diff --git base/allocator/partition_allocator/src/partition_alloc/partition_freelist_entry.h base/allocator/partition_allocator/src/partition_alloc/partition_freelist_entry.h
index 244e52b25278a..df39958ecdc5b 100644
--- base/allocator/partition_allocator/src/partition_alloc/partition_freelist_entry.h
+++ base/allocator/partition_allocator/src/partition_alloc/partition_freelist_entry.h
@@ -10,7 +10,6 @@
#include "partition_alloc/partition_alloc_base/bits.h"
#include "partition_alloc/partition_alloc_base/compiler_specific.h"
#include "partition_alloc/partition_alloc_base/component_export.h"
-#include "partition_alloc/partition_alloc_base/no_destructor.h"
#include "partition_alloc/partition_alloc_buildflags.h"
#include "partition_alloc/partition_alloc_constants.h"
@@ -299,16 +298,18 @@ PA_ALWAYS_INLINE const PartitionFreelistDispatcher*
PartitionFreelistDispatcher::Create(PartitionFreelistEncoding encoding) {
switch (encoding) {
case PartitionFreelistEncoding::kEncodedFreeList: {
- static base::NoDestructor<PartitionFreelistDispatcherImpl<
- PartitionFreelistEncoding::kEncodedFreeList>>
- encoded_impl;
- return encoded_impl.get();
+ static constinit PartitionFreelistDispatcherImpl<
+ PartitionFreelistEncoding::kEncodedFreeList>
+ encoded = PartitionFreelistDispatcherImpl<
+ PartitionFreelistEncoding::kEncodedFreeList>();
+ return &encoded;
}
case PartitionFreelistEncoding::kPoolOffsetFreeList: {
- static base::NoDestructor<PartitionFreelistDispatcherImpl<
- PartitionFreelistEncoding::kPoolOffsetFreeList>>
- pool_offset_impl;
- return pool_offset_impl.get();
+ static constinit PartitionFreelistDispatcherImpl<
+ PartitionFreelistEncoding::kPoolOffsetFreeList>
+ pool = PartitionFreelistDispatcherImpl<
+ PartitionFreelistEncoding::kPoolOffsetFreeList>();
+ return &pool;
}
}
}

View File

@ -1,8 +1,8 @@
diff --git sandbox/policy/win/sandbox_win.cc sandbox/policy/win/sandbox_win.cc
index 05a9bd7063f78..32e5659341a70 100644
index 0e6de2b7b4956..63ae91189c031 100644
--- sandbox/policy/win/sandbox_win.cc
+++ sandbox/policy/win/sandbox_win.cc
@@ -1044,6 +1044,13 @@ ResultCode SandboxWin::StartSandboxedProcess(
@@ -971,6 +971,13 @@ ResultCode SandboxWin::StartSandboxedProcess(
const base::HandlesToInheritVector& handles_to_inherit,
SandboxDelegate* delegate,
base::Process* process) {

View File

@ -1,5 +1,5 @@
diff --git base/time/time.h base/time/time.h
index 0efbea85491f4..17f9fe92ef78c 100644
index 295433eed9f83..2cee8bd38649e 100644
--- base/time/time.h
+++ base/time/time.h
@@ -134,6 +134,13 @@ constexpr bool isnan(double d) {

View File

@ -12,7 +12,7 @@ index a2d801b370b01..b56de03637fec 100644
} // namespace sandbox
diff --git sandbox/win/src/sandbox_policy_base.cc sandbox/win/src/sandbox_policy_base.cc
index 6a9b45d8de663..24646ea209be0 100644
index e41f68c171438..40eeaacde5fad 100644
--- sandbox/win/src/sandbox_policy_base.cc
+++ sandbox/win/src/sandbox_policy_base.cc
@@ -190,12 +190,12 @@ PolicyGlobal* ConfigBase::policy() {