Update to Chromium version 126.0.6478.0 (#1300313)

This commit is contained in:
Marshall Greenblatt 2024-05-22 21:52:35 -04:00
parent bc1b856b96
commit 701fc03f00
127 changed files with 915 additions and 909 deletions

View File

@ -252,8 +252,7 @@ if (is_linux) {
# Set by GetRequiredArgs() in //cef/tools/gn_args.py.
#
# Set ENABLE_PRINTING=1 ENABLE_BASIC_PRINTING=1.
assert(enable_basic_printing)
# Enable support for Print Preview.
assert(enable_print_preview)
# Enable support for Widevine CDM.
@ -1018,7 +1017,6 @@ source_set("libcef_static") {
# Normal build dependencies. Should be sorted alphabetically.
"//base:base_static",
"//base/third_party/dynamic_annotations",
"//cc",
"//chrome:dependencies",
"//chrome:packed_resources",

View File

@ -7,5 +7,5 @@
# https://bitbucket.org/chromiumembedded/cef/wiki/BranchesAndBuilding
{
'chromium_checkout': 'refs/tags/125.0.6422.0'
'chromium_checkout': 'refs/tags/126.0.6478.0'
}

View File

@ -33,7 +33,7 @@
// by hand. See the translator.README.txt file in the tools directory for
// more information.
//
// $hash=3a188f380f8044060ea93fdca0b3d231df88979d$
// $hash=5dd4948a92af2ad69e2171f2dffb8f2c23e5c147$
//
#ifndef CEF_INCLUDE_CAPI_CEF_V8_CAPI_H_
@ -611,7 +611,6 @@ typedef struct _cef_v8value_t {
///
int(CEF_CALLBACK* set_value_byaccessor)(struct _cef_v8value_t* self,
const cef_string_t* key,
cef_v8_accesscontrol_t settings,
cef_v8_propertyattribute_t attribute);
///

View File

@ -42,13 +42,13 @@
// way that may cause binary incompatibility with other builds. The universal
// hash value will change if any platform is affected whereas the platform hash
// values will change only if that particular platform is affected.
#define CEF_API_HASH_UNIVERSAL "c9171db05e2e3ad611ea09d9457edaaa336bd4d6"
#define CEF_API_HASH_UNIVERSAL "a600703f7e1ff2c897b6ee0a77123fdfe25501f7"
#if defined(OS_WIN)
#define CEF_API_HASH_PLATFORM "d65aa12068be307fd8e6642024cb67d82643d412"
#define CEF_API_HASH_PLATFORM "1af2a8ac18627ab06e6012ab57f0e3edb9bbd426"
#elif defined(OS_MAC)
#define CEF_API_HASH_PLATFORM "41e80b4bf45ce56cea0e87e825f9e6b58977a1da"
#define CEF_API_HASH_PLATFORM "7b7d434bce93b2176cd1bb9332f12929db1e85b9"
#elif defined(OS_LINUX)
#define CEF_API_HASH_PLATFORM "1ed8d88d0d7d9d8a3b0296e9f84fea7752fdff2e"
#define CEF_API_HASH_PLATFORM "51042cfa82f6dd179acba9848cb7418b2c24b514"
#endif
#ifdef __cplusplus

View File

@ -435,7 +435,6 @@ class CefV8ArrayBufferReleaseCallback : public virtual CefBaseRefCounted {
/*--cef(source=library,no_debugct_check)--*/
class CefV8Value : public virtual CefBaseRefCounted {
public:
typedef cef_v8_accesscontrol_t AccessControl;
typedef cef_v8_propertyattribute_t PropertyAttribute;
///
@ -794,9 +793,7 @@ class CefV8Value : public virtual CefBaseRefCounted {
/// will return true even though assignment failed.
///
/*--cef(capi_name=set_value_byaccessor,optional_param=key)--*/
virtual bool SetValue(const CefString& key,
AccessControl settings,
PropertyAttribute attribute) = 0;
virtual bool SetValue(const CefString& key, PropertyAttribute attribute) = 0;
///
/// Read the keys for the object's values into the specified vector. Integer-

View File

@ -1239,16 +1239,6 @@ typedef enum {
CEF_TEXT_INPUT_MODE_MAX = CEF_TEXT_INPUT_MODE_SEARCH,
} cef_text_input_mode_t;
///
/// V8 access control values.
///
typedef enum {
V8_ACCESS_CONTROL_DEFAULT = 0,
V8_ACCESS_CONTROL_ALL_CAN_READ = 1,
V8_ACCESS_CONTROL_ALL_CAN_WRITE = 1 << 1,
V8_ACCESS_CONTROL_PROHIBITS_OVERWRITING = 1 << 2
} cef_v8_accesscontrol_t;
///
/// V8 property attribute values.
///
@ -3480,11 +3470,11 @@ typedef enum {
CEF_CPAIT_PAYMENTS_OFFER_NOTIFICATION,
CEF_CPAIT_PRICE_TRACKING,
CEF_CPAIT_PWA_INSTALL,
CEF_CPAIT_QR_CODE_GENERATOR,
CEF_CPAIT_READER_MODE,
CEF_CPAIT_QR_CODE_GENERATOR_DEPRECATED,
CEF_CPAIT_READER_MODE_DEPRECATED,
CEF_CPAIT_SAVE_AUTOFILL_ADDRESS,
CEF_CPAIT_SAVE_CARD,
CEF_CPAIT_SEND_TAB_TO_SELF,
CEF_CPAIT_SEND_TAB_TO_SELF_DEPRECATED,
CEF_CPAIT_SHARING_HUB,
CEF_CPAIT_SIDE_SEARCH,
CEF_CPAIT_SMS_REMOTE_FETCHER,
@ -3496,7 +3486,8 @@ typedef enum {
CEF_CPAIT_MANDATORY_REAUTH,
CEF_CPAIT_PRICE_INSIGHTS,
CEF_CPAIT_PRICE_READ_ANYTHING,
CEF_CPAIT_MAX_VALUE = CEF_CPAIT_PRICE_READ_ANYTHING,
CEF_CPAIT_PRODUCT_SPECIFICATIONS,
CEF_CPAIT_MAX_VALUE = CEF_CPAIT_PRODUCT_SPECIFICATIONS,
} cef_chrome_page_action_icon_type_t;
///
@ -3642,12 +3633,14 @@ typedef enum {
CEF_PERMISSION_TYPE_MIDI_SYSEX = 1 << 13,
CEF_PERMISSION_TYPE_MULTIPLE_DOWNLOADS = 1 << 14,
CEF_PERMISSION_TYPE_NOTIFICATIONS = 1 << 15,
CEF_PERMISSION_TYPE_PROTECTED_MEDIA_IDENTIFIER = 1 << 16,
CEF_PERMISSION_TYPE_REGISTER_PROTOCOL_HANDLER = 1 << 17,
CEF_PERMISSION_TYPE_STORAGE_ACCESS = 1 << 18,
CEF_PERMISSION_TYPE_VR_SESSION = 1 << 19,
CEF_PERMISSION_TYPE_WINDOW_MANAGEMENT = 1 << 20,
CEF_PERMISSION_TYPE_FILE_SYSTEM_ACCESS = 1 << 21,
CEF_PERMISSION_TYPE_KEYBOARD_LOCK = 1 << 16,
CEF_PERMISSION_TYPE_POINTER_LOCK = 1 << 17,
CEF_PERMISSION_TYPE_PROTECTED_MEDIA_IDENTIFIER = 1 << 18,
CEF_PERMISSION_TYPE_REGISTER_PROTOCOL_HANDLER = 1 << 19,
CEF_PERMISSION_TYPE_STORAGE_ACCESS = 1 << 20,
CEF_PERMISSION_TYPE_VR_SESSION = 1 << 21,
CEF_PERMISSION_TYPE_WINDOW_MANAGEMENT = 1 << 22,
CEF_PERMISSION_TYPE_FILE_SYSTEM_ACCESS = 1 << 23,
} cef_permission_request_types_t;
///

View File

@ -432,6 +432,11 @@ AlloyBrowserContext::GetProfileCloudPolicyManager() {
return nullptr;
}
policy::CloudPolicyManager* AlloyBrowserContext::GetCloudPolicyManager() {
DCHECK(false);
return nullptr;
}
policy::ProfilePolicyConnector*
AlloyBrowserContext::GetProfilePolicyConnector() {
DCHECK(false);

View File

@ -94,6 +94,7 @@ class AlloyBrowserContext : public ChromeProfileAlloy,
policy::SchemaRegistryService* GetPolicySchemaRegistryService() override;
policy::UserCloudPolicyManager* GetUserCloudPolicyManager() override;
policy::ProfileCloudPolicyManager* GetProfileCloudPolicyManager() override;
policy::CloudPolicyManager* GetCloudPolicyManager() override;
policy::ProfilePolicyConnector* GetProfilePolicyConnector() override;
const policy::ProfilePolicyConnector* GetProfilePolicyConnector()
const override;

View File

@ -1365,26 +1365,26 @@ void AlloyBrowserHostImpl::OnRecentlyAudibleTimerFired() {
}
void AlloyBrowserHostImpl::AccessibilityEventReceived(
const content::AXEventNotificationDetails& content_event_bundle) {
const ui::AXUpdatesAndEvents& details) {
// Only needed in windowless mode.
if (IsWindowless()) {
if (!web_contents() || !platform_delegate_) {
return;
}
platform_delegate_->AccessibilityEventReceived(content_event_bundle);
platform_delegate_->AccessibilityEventReceived(details);
}
}
void AlloyBrowserHostImpl::AccessibilityLocationChangesReceived(
const std::vector<content::AXLocationChangeNotificationDetails>& locData) {
const std::vector<ui::AXLocationChanges>& details) {
// Only needed in windowless mode.
if (IsWindowless()) {
if (!web_contents() || !platform_delegate_) {
return;
}
platform_delegate_->AccessibilityLocationChangesReceived(locData);
platform_delegate_->AccessibilityLocationChangesReceived(details);
}
}

View File

@ -303,10 +303,9 @@ class AlloyBrowserHostImpl : public CefBrowserHostBase,
content::NavigationHandle* navigation_handle) override;
void OnAudioStateChanged(bool audible) override;
void AccessibilityEventReceived(
const content::AXEventNotificationDetails& content_event_bundle) override;
const ui::AXUpdatesAndEvents& details) override;
void AccessibilityLocationChangesReceived(
const std::vector<content::AXLocationChangeNotificationDetails>& locData)
override;
const std::vector<ui::AXLocationChanges>& details) override;
void WebContentsDestroyed() override;
private:

View File

@ -50,6 +50,7 @@
#include "ui/native_theme/native_theme.h"
#if BUILDFLAG(IS_LINUX)
#include "components/password_manager/core/browser/password_manager_switches.h"
#include "ui/base/ozone_buildflags.h"
#if defined(USE_AURA) && BUILDFLAG(IS_OZONE_X11)
#include "ui/events/devices/x11/touch_factory_x11.h"
@ -283,12 +284,13 @@ void AlloyBrowserMainParts::PostCreateMainMessageLoop() {
std::unique_ptr<os_crypt::Config> config =
std::make_unique<os_crypt::Config>();
// Forward to os_crypt the flag to use a specific password store.
config->store = command_line->GetSwitchValueASCII(switches::kPasswordStore);
// Forward the product name (defaults to "Chromium").
config->store =
command_line->GetSwitchValueASCII(password_manager::kPasswordStore);
// Forward the product name
config->product_name = l10n_util::GetStringUTF8(IDS_PRODUCT_NAME);
// OSCrypt can be disabled in a special settings file.
config->should_use_preference =
command_line->HasSwitch(switches::kEnableEncryptionSelection);
command_line->HasSwitch(password_manager::kEnableEncryptionSelection);
base::PathService::Get(chrome::DIR_USER_DATA, &config->user_data_path);
DCHECK(!config->user_data_path.empty());
OSCrypt::SetConfig(std::move(config));

View File

@ -445,6 +445,12 @@ os_crypt_async::OSCryptAsync* ChromeBrowserProcessAlloy::os_crypt_async() {
return os_crypt_async_.get();
}
void ChromeBrowserProcessAlloy::set_additional_os_crypt_async_provider_for_test(
size_t precedence,
std::unique_ptr<os_crypt_async::KeyProvider> provider) {
DCHECK(false);
}
BuildState* ChromeBrowserProcessAlloy::GetBuildState() {
DCHECK(false);
return nullptr;

View File

@ -109,6 +109,9 @@ class ChromeBrowserProcessAlloy : public BrowserProcess {
resource_coordinator::ResourceCoordinatorParts* resource_coordinator_parts()
override;
os_crypt_async::OSCryptAsync* os_crypt_async() override;
void set_additional_os_crypt_async_provider_for_test(
size_t precedence,
std::unique_ptr<os_crypt_async::KeyProvider> provider) override;
BuildState* GetBuildState() override;
SerialPolicyAllowedPorts* serial_policy_allowed_ports() override;
HidSystemTrayIcon* hid_system_tray_icon() override;

View File

@ -495,12 +495,12 @@ void CefBrowserPlatformDelegate::DragSourceSystemDragEnded() {
}
void CefBrowserPlatformDelegate::AccessibilityEventReceived(
const content::AXEventNotificationDetails& eventData) {
const ui::AXUpdatesAndEvents& details) {
DCHECK(false);
}
void CefBrowserPlatformDelegate::AccessibilityLocationChangesReceived(
const std::vector<content::AXLocationChangeNotificationDetails>& locData) {
const std::vector<ui::AXLocationChanges>& details) {
DCHECK(false);
}

View File

@ -41,8 +41,6 @@ class WindowFeatures;
} // namespace blink
namespace content {
struct AXEventNotificationDetails;
struct AXLocationChangeNotificationDetails;
struct DropData;
struct NativeWebKeyboardEvent;
class RenderViewHost;
@ -67,6 +65,11 @@ class Size;
class Vector2d;
} // namespace gfx
namespace ui {
struct AXLocationChanges;
struct AXUpdatesAndEvents;
} // namespace ui
namespace views {
class Widget;
}
@ -382,9 +385,9 @@ class CefBrowserPlatformDelegate {
virtual void DragSourceEndedAt(int x, int y, cef_drag_operations_mask_t op);
virtual void DragSourceSystemDragEnded();
virtual void AccessibilityEventReceived(
const content::AXEventNotificationDetails& eventData);
const ui::AXUpdatesAndEvents& details);
virtual void AccessibilityLocationChangesReceived(
const std::vector<content::AXLocationChangeNotificationDetails>& locData);
const std::vector<ui::AXLocationChanges>& details);
virtual gfx::Point GetDialogPosition(const gfx::Size& size);
virtual gfx::Size GetMaximumDialogSize();

View File

@ -247,6 +247,7 @@ ProcessManagerDelegate* CefExtensionsBrowserClient::GetProcessManagerDelegate()
mojo::PendingRemote<network::mojom::URLLoaderFactory>
CefExtensionsBrowserClient::GetControlledFrameEmbedderURLLoader(
const url::Origin& app_origin,
int frame_tree_node_id,
content::BrowserContext* browser_context) {
return mojo::PendingRemote<network::mojom::URLLoaderFactory>();

View File

@ -85,6 +85,7 @@ class CefExtensionsBrowserClient : public ExtensionsBrowserClient {
ProcessManagerDelegate* GetProcessManagerDelegate() const override;
mojo::PendingRemote<network::mojom::URLLoaderFactory>
GetControlledFrameEmbedderURLLoader(
const url::Origin& app_origin,
int frame_tree_node_id,
content::BrowserContext* browser_context) override;
std::unique_ptr<ExtensionHostDelegate> CreateExtensionHostDelegate() override;

View File

@ -466,16 +466,16 @@ class CefURLDataSource : public content::URLDataSource {
bool handled = false;
switch (host_id_) {
case CHROME_EXTENSIONS_SUPPORT:
handled = OnExtensionsSupportUI(&mime_type_, &output_->data());
handled = OnExtensionsSupportUI(&mime_type_, &output_->as_string());
break;
case CHROME_LICENSE:
handled = OnLicenseUI(&mime_type_, &output_->data());
handled = OnLicenseUI(&mime_type_, &output_->as_string());
break;
case CHROME_VERSION:
handled = OnVersionUI(profile_, &mime_type_, &output_->data());
handled = OnVersionUI(profile_, &mime_type_, &output_->as_string());
break;
case CHROME_WEBUI_HOSTS:
handled = OnWebUIHostsUI(&mime_type_, &output_->data());
handled = OnWebUIHostsUI(&mime_type_, &output_->as_string());
break;
default:
break;

View File

@ -250,10 +250,12 @@ void LoadCookies(const CefBrowserContext::Getter& browser_context_getter,
net::CookiePartitionKeyCollection partition_key_collection;
if (request.trusted_params.has_value() &&
!request.trusted_params->isolation_info.IsEmpty()) {
const auto& isolation_info = request.trusted_params->isolation_info;
partition_key_collection = net::CookiePartitionKeyCollection::FromOptional(
net::CookiePartitionKey::FromNetworkIsolationKey(
request.trusted_params->isolation_info.network_isolation_key(),
request.site_for_cookies, net::SchemefulSite(request.url)));
isolation_info.network_isolation_key(), request.site_for_cookies,
net::SchemefulSite(request.url),
isolation_info.IsMainFrameRequest()));
}
CEF_POST_TASK(

View File

@ -93,7 +93,7 @@ bool ResponseFilterWrapper::CreateOutputHandle(
void ResponseFilterWrapper::OnSourceReadable(MojoResult,
const mojo::HandleSignalsState&) {
const void* buffer = nullptr;
uint32_t read_bytes = 0;
size_t read_bytes = 0;
MojoResult result = source_handle_->BeginReadData(&buffer, &read_bytes,
MOJO_READ_DATA_FLAG_NONE);
if (result == MOJO_RESULT_SHOULD_WAIT) {

View File

@ -625,7 +625,7 @@ void CefBrowserPlatformDelegateOsr::DragSourceSystemDragEnded() {
}
void CefBrowserPlatformDelegateOsr::AccessibilityEventReceived(
const content::AXEventNotificationDetails& eventData) {
const ui::AXUpdatesAndEvents& details) {
CefRefPtr<CefRenderHandler> handler = browser_->client()->GetRenderHandler();
if (handler.get()) {
CefRefPtr<CefAccessibilityHandler> acchandler =
@ -633,13 +633,13 @@ void CefBrowserPlatformDelegateOsr::AccessibilityEventReceived(
if (acchandler.get()) {
acchandler->OnAccessibilityTreeChange(
osr_accessibility_util::ParseAccessibilityEventData(eventData));
osr_accessibility_util::ParseAccessibilityEventData(details));
}
}
}
void CefBrowserPlatformDelegateOsr::AccessibilityLocationChangesReceived(
const std::vector<content::AXLocationChangeNotificationDetails>& locData) {
const std::vector<ui::AXLocationChanges>& details) {
CefRefPtr<CefRenderHandler> handler = browser_->client()->GetRenderHandler();
if (handler.get()) {
CefRefPtr<CefAccessibilityHandler> acchandler =
@ -647,7 +647,7 @@ void CefBrowserPlatformDelegateOsr::AccessibilityLocationChangesReceived(
if (acchandler.get()) {
acchandler->OnAccessibilityLocationChange(
osr_accessibility_util::ParseAccessibilityLocationData(locData));
osr_accessibility_util::ParseAccessibilityLocationData(details));
}
}
}

View File

@ -88,10 +88,9 @@ class CefBrowserPlatformDelegateOsr
void DragSourceEndedAt(int x, int y, cef_drag_operations_mask_t op) override;
void DragSourceSystemDragEnded() override;
void AccessibilityEventReceived(
const content::AXEventNotificationDetails& eventData) override;
const ui::AXUpdatesAndEvents& details) override;
void AccessibilityLocationChangesReceived(
const std::vector<content::AXLocationChangeNotificationDetails>& locData)
override;
const std::vector<ui::AXLocationChanges>& details) override;
// CefBrowserPlatformDelegateNative::WindowlessHandler methods:
CefWindowHandle GetParentWindowHandle() const override;

View File

@ -12,11 +12,11 @@
#include "base/stl_util.h"
#include "base/strings/string_number_conversions.h"
#include "base/strings/stringprintf.h"
#include "content/public/browser/ax_event_notification_details.h"
#include "ui/accessibility/ax_enum_util.h"
#include "ui/accessibility/ax_enums.mojom.h"
#include "ui/accessibility/ax_text_utils.h"
#include "ui/accessibility/ax_tree_update.h"
#include "ui/accessibility/ax_updates_and_events.h"
#include "ui/gfx/geometry/transform.h"
namespace {
@ -474,7 +474,7 @@ CefRefPtr<CefDictionaryValue> ToCefValue(const ui::AXEvent& event) {
// Convert AXEventNotificationDetails to CefDictionaryValue.
CefRefPtr<CefDictionaryValue> ToCefValue(
const content::AXEventNotificationDetails& eventData) {
const ui::AXUpdatesAndEvents& eventData) {
CefRefPtr<CefDictionaryValue> value = CefDictionaryValue::Create();
if (!eventData.ax_tree_id.ToString().empty()) {
@ -525,8 +525,7 @@ CefRefPtr<CefDictionaryValue> ToCefValue(const ui::AXRelativeBounds& location) {
}
// Convert AXLocationChangeNotificationDetails to CefDictionaryValue.
CefRefPtr<CefDictionaryValue> ToCefValue(
const content::AXLocationChangeNotificationDetails& locData) {
CefRefPtr<CefDictionaryValue> ToCefValue(const ui::AXLocationChanges& locData) {
CefRefPtr<CefDictionaryValue> value = CefDictionaryValue::Create();
if (locData.id != -1) {
@ -558,16 +557,16 @@ CefRefPtr<CefListValue> ToCefValue(const std::vector<T>& vecData) {
namespace osr_accessibility_util {
CefRefPtr<CefValue> ParseAccessibilityEventData(
const content::AXEventNotificationDetails& data) {
const ui::AXUpdatesAndEvents& details) {
CefRefPtr<CefValue> value = CefValue::Create();
value->SetDictionary(ToCefValue(data));
value->SetDictionary(ToCefValue(details));
return value;
}
CefRefPtr<CefValue> ParseAccessibilityLocationData(
const std::vector<content::AXLocationChangeNotificationDetails>& data) {
const std::vector<ui::AXLocationChanges>& details) {
CefRefPtr<CefValue> value = CefValue::Create();
value->SetList(ToCefValue(data));
value->SetList(ToCefValue(details));
return value;
}

View File

@ -10,20 +10,20 @@
#include "cef/include/cef_values.h"
namespace content {
struct AXEventNotificationDetails;
struct AXLocationChangeNotificationDetails;
} // namespace content
namespace ui {
struct AXLocationChanges;
struct AXUpdatesAndEvents;
} // namespace ui
namespace osr_accessibility_util {
// Convert Accessibility Event and location updates to CefValue, which may be
// consumed or serialized with CefJSONWrite.
CefRefPtr<CefValue> ParseAccessibilityEventData(
const content::AXEventNotificationDetails& data);
const ui::AXUpdatesAndEvents& details);
CefRefPtr<CefValue> ParseAccessibilityLocationData(
const std::vector<content::AXLocationChangeNotificationDetails>& data);
const std::vector<ui::AXLocationChanges>& details);
} // namespace osr_accessibility_util

View File

@ -116,8 +116,11 @@ class CefDelegatedFrameHostClient : public content::DelegatedFrameHostClient {
return view_->GetDeviceScaleFactor();
}
std::vector<viz::SurfaceId> CollectSurfaceIdsForEviction() override {
return view_->render_widget_host()->CollectSurfaceIdsForEviction();
viz::FrameEvictorClient::EvictIds CollectSurfaceIdsForEviction() override {
viz::FrameEvictorClient::EvictIds ids;
ids.embedded_ids =
view_->render_widget_host()->CollectSurfaceIdsForEviction();
return ids;
}
void InvalidateLocalSurfaceIdOnEviction() override {
@ -958,7 +961,7 @@ CefRenderWidgetHostViewOSR::CreateSyntheticGestureTarget() {
bool CefRenderWidgetHostViewOSR::TransformPointToCoordSpaceForView(
const gfx::PointF& point,
RenderWidgetHostViewBase* target_view,
RenderWidgetHostViewInput* target_view,
gfx::PointF* transformed_point) {
if (target_view == this) {
*transformed_point = point;

View File

@ -188,7 +188,7 @@ class CefRenderWidgetHostViewOSR
CreateSyntheticGestureTarget() override;
bool TransformPointToCoordSpaceForView(
const gfx::PointF& point,
RenderWidgetHostViewBase* target_view,
RenderWidgetHostViewInput* target_view,
gfx::PointF* transformed_point) override;
void DidNavigate() override;
void SelectionChanged(const std::u16string& text,

View File

@ -132,6 +132,7 @@ class CefPermissionPrompt : public permissions::PermissionPrompt {
const override {
return {};
}
bool IsAskPrompt() const override { return true; }
private:
// We don't expose AcceptThisTime() because it's a special case for
@ -216,6 +217,10 @@ cef_permission_request_types_t GetCefRequestType(
return CEF_PERMISSION_TYPE_MULTIPLE_DOWNLOADS;
case permissions::RequestType::kNotifications:
return CEF_PERMISSION_TYPE_NOTIFICATIONS;
case permissions::RequestType::kKeyboardLock:
return CEF_PERMISSION_TYPE_KEYBOARD_LOCK;
case permissions::RequestType::kPointerLock:
return CEF_PERMISSION_TYPE_POINTER_LOCK;
#if BUILDFLAG(IS_WIN)
case permissions::RequestType::kProtectedMediaIdentifier:
return CEF_PERMISSION_TYPE_PROTECTED_MEDIA_IDENTIFIER;

View File

@ -258,6 +258,7 @@ std::unique_ptr<PrefService> CreatePrefService(Profile* profile,
// Default profile preferences.
AccessibilityUIMessageHandler::RegisterProfilePrefs(registry.get());
content_settings::CookieSettings::RegisterProfilePrefs(registry.get());
extensions::ExtensionPrefs::RegisterProfilePrefs(registry.get());
HostContentSettingsMap::RegisterProfilePrefs(registry.get());
language::LanguagePrefs::RegisterProfilePrefs(registry.get());

View File

@ -41,9 +41,6 @@ void CefSpeechRecognitionManagerDelegate::OnRecognitionStart(int session_id) {}
void CefSpeechRecognitionManagerDelegate::OnAudioStart(int session_id) {}
void CefSpeechRecognitionManagerDelegate::OnEnvironmentEstimationComplete(
int session_id) {}
void CefSpeechRecognitionManagerDelegate::OnSoundStart(int session_id) {}
void CefSpeechRecognitionManagerDelegate::OnSoundEnd(int session_id) {}

View File

@ -29,7 +29,6 @@ class CefSpeechRecognitionManagerDelegate
// SpeechRecognitionEventListener methods.
void OnRecognitionStart(int session_id) override;
void OnAudioStart(int session_id) override;
void OnEnvironmentEstimationComplete(int session_id) override;
void OnSoundStart(int session_id) override;
void OnSoundEnd(int session_id) override;
void OnAudioEnd(int session_id) override;

View File

@ -73,7 +73,8 @@ CEF_VIEW_VIEW_T class CefViewView : public ViewsViewClass {
}
// views::View methods:
gfx::Size CalculatePreferredSize() const override;
gfx::Size CalculatePreferredSize(
const views::SizeBounds& available_size) const override;
gfx::Size GetMinimumSize() const override;
gfx::Size GetMaximumSize() const override;
int GetHeightForWidth(int w) const override;
@ -100,7 +101,8 @@ CEF_VIEW_VIEW_T class CefViewView : public ViewsViewClass {
raw_ptr<CefViewDelegateClass> cef_delegate_;
};
CEF_VIEW_VIEW_T gfx::Size CEF_VIEW_VIEW_D::CalculatePreferredSize() const {
CEF_VIEW_VIEW_T gfx::Size CEF_VIEW_VIEW_D::CalculatePreferredSize(
const views::SizeBounds& available_size) const {
gfx::Size result;
if (cef_delegate()) {
CefSize cef_size = cef_delegate()->GetPreferredSize(GetCefView());
@ -109,7 +111,7 @@ CEF_VIEW_VIEW_T gfx::Size CEF_VIEW_VIEW_D::CalculatePreferredSize() const {
}
}
if (result.IsEmpty()) {
result = ParentClass::CalculatePreferredSize();
result = ParentClass::CalculatePreferredSize(available_size);
}
if (result.IsEmpty()) {
// Some layouts like BoxLayout expect the preferred size to be non-empty.

View File

@ -253,7 +253,8 @@ class CaptionlessFrameView : public views::NonClientFrameView {
LayoutSuperclass<views::NonClientFrameView>(this);
}
gfx::Size CalculatePreferredSize() const override {
gfx::Size CalculatePreferredSize(
const views::SizeBounds& available_size) const override {
return widget_->non_client_view()
->GetWindowBoundsForClientBounds(
gfx::Rect(widget_->client_view()->GetPreferredSize()))
@ -529,7 +530,7 @@ void CefWindowView::CreateWidget(gfx::AcceleratedWidget parent_widget) {
if (params.bounds.IsEmpty()) {
// The window will be placed on the default screen with origin (0,0).
params.bounds = gfx::Rect(CalculatePreferredSize());
params.bounds = gfx::Rect(CalculatePreferredSize({}));
if (params.bounds.IsEmpty()) {
// Choose a reasonable default size.
params.bounds.set_size({800, 600});
@ -756,7 +757,7 @@ bool CefWindowView::MaybeGetMinimumSize(gfx::Size* size) const {
// Resize is disabled on Linux by returning the preferred size as the min/max
// size.
if (!CanResize()) {
*size = CalculatePreferredSize();
*size = CalculatePreferredSize({});
return true;
}
#endif
@ -768,7 +769,7 @@ bool CefWindowView::MaybeGetMaximumSize(gfx::Size* size) const {
// Resize is disabled on Linux by returning the preferred size as the min/max
// size.
if (!CanResize()) {
*size = CalculatePreferredSize();
*size = CalculatePreferredSize({});
return true;
}
#endif

View File

@ -35,6 +35,8 @@
#include "cef/libcef/common/util_mac.h"
#elif BUILDFLAG(IS_POSIX)
#include "cef/libcef/common/util_linux.h"
#elif BUILDFLAG(IS_WIN)
#include "sandbox/policy/features.h"
#endif
namespace {
@ -322,6 +324,14 @@ std::optional<int> ChromeMainDelegateCef::BasicStartupComplete() {
disable_features.push_back(base::kEnableHangWatcher.name);
}
#if BUILDFLAG(IS_WIN) && !defined(OFFICIAL_BUILD)
// Disable WinSboxNoFakeGdiInit which causes the renderer processes to crash
// with STATUS_DLL_INIT_FAILED. This is currently enabled via a field trial
// for non-Official builds. See https://crbug.com/326277735#comment23.
disable_features.push_back(
sandbox::policy::features::kWinSboxNoFakeGdiInit.name);
#endif
if (!disable_features.empty()) {
DCHECK(!base::FeatureList::GetInstance());
std::string disable_features_str =

View File

@ -260,7 +260,7 @@ bool MakeCefCookie(const GURL& url,
path_string = pc.Path();
}
std::string cookie_path =
net::CanonicalCookie::CanonPathWithString(url, path_string);
net::cookie_util::CanonPathWithString(url, path_string);
base::Time creation_time = base::Time::Now();
base::Time cookie_expires =
net::CanonicalCookie::ParseExpiration(pc, creation_time, creation_time);

View File

@ -23,13 +23,14 @@ void GetCefString(scoped_refptr<base::RefCountedMemory> source,
if (source && source->size() > 0U) {
#if defined(CEF_STRING_TYPE_UTF8) || defined(CEF_STRING_TYPE_UTF16)
// Reference existing UTF8 or UTF16 data.
cef_string.FromString(source->front_as<CefString::char_type>(),
source->size() / sizeof(CefString::char_type),
/*copy=*/false);
cef_string.FromString(
reinterpret_cast<const CefString::char_type*>(source->data()),
source->size() / sizeof(CefString::char_type),
/*copy=*/false);
#else
// Must convert from UTF16.
cef_string.FromString16(
source->front_as<std::u16string::value_type>(),
reinterpret_cast<const std::u16string::value_type*>(source->data()),
source->size() / sizeof(std::u16string::value_type));
#endif
} else {

View File

@ -215,7 +215,7 @@ v8::Local<v8::Value> ExecuteV8ScriptAndReturnValue(
// The Rethrow() message is unused due to kDoNotSanitize but it still needs
// to be non-nullopt for exceptions to be re-thrown as expected.
auto result = blink::V8ScriptRunner::CompileAndRunScript(
blink::ScriptState::From(context), script,
blink::ScriptState::From(context->GetIsolate(), context), script,
blink::ExecuteScriptPolicy::kExecuteScriptWhenScriptsDisabled,
blink::V8ScriptRunner::RethrowErrorsOption::Rethrow(""));

View File

@ -142,7 +142,7 @@ void CefRenderFrameObserver::DidCreateScriptContext(
v8::Isolate* isolate = context->GetIsolate();
v8::HandleScope handle_scope(isolate);
v8::Context::Scope scope(context);
v8::MicrotasksScope microtasks_scope(isolate,
v8::MicrotasksScope microtasks_scope(isolate, context->GetMicrotaskQueue(),
v8::MicrotasksScope::kRunMicrotasks);
CefRefPtr<CefV8Context> contextPtr(new CefV8ContextImpl(isolate, context));

View File

@ -579,6 +579,11 @@ void AccessorNameGetterCallbackImpl(
return info.GetReturnValue().SetUndefined();
}
// See explanation in https://crbug.com/336325111.
void EmptySetterCallbackImpl(v8::Local<v8::Name> property,
v8::Local<v8::Value> value,
const v8::PropertyCallbackInfo<void>& info) {}
void AccessorNameSetterCallbackImpl(
v8::Local<v8::Name> property,
v8::Local<v8::Value> value,
@ -625,7 +630,7 @@ int PropertyToIndex(v8::Isolate* isolate, uint32_t index) {
// T == v8::Local<v8::Name> for named property handlers and
// T == uint32_t for indexed property handlers
template <typename T>
void InterceptorGetterCallbackImpl(
v8::Intercepted InterceptorGetterCallbackImpl(
T property,
const v8::PropertyCallbackInfo<v8::Value>& info) {
v8::Isolate* isolate = info.GetIsolate();
@ -639,7 +644,7 @@ void InterceptorGetterCallbackImpl(
interceptorPtr = tracker->GetInterceptor();
}
if (!interceptorPtr.get()) {
return;
return v8::Intercepted::kNo;
}
CefRefPtr<CefV8Value> object = new CefV8ValueImpl(isolate, context, obj);
@ -654,15 +659,18 @@ void InterceptorGetterCallbackImpl(
CefV8ValueImpl* retval_impl = static_cast<CefV8ValueImpl*>(retval.get());
if (retval_impl && retval_impl->IsValid()) {
info.GetReturnValue().Set(retval_impl->GetV8Value(true));
return v8::Intercepted::kYes;
}
}
return v8::Intercepted::kNo;
}
template <typename T>
void InterceptorSetterCallbackImpl(
v8::Intercepted InterceptorSetterCallbackImpl(
T property,
v8::Local<v8::Value> value,
const v8::PropertyCallbackInfo<v8::Value>& info) {
const v8::PropertyCallbackInfo<void>& info) {
v8::Isolate* isolate = info.GetIsolate();
v8::Local<v8::Context> context = isolate->GetCurrentContext();
v8::Handle<v8::Object> obj = info.This();
@ -674,7 +682,7 @@ void InterceptorSetterCallbackImpl(
}
if (!interceptorPtr.get()) {
return;
return v8::Intercepted::kNo;
}
CefRefPtr<CefV8Value> object = new CefV8ValueImpl(isolate, context, obj);
CefRefPtr<CefV8Value> cefValue = new CefV8ValueImpl(isolate, context, value);
@ -685,6 +693,10 @@ void InterceptorSetterCallbackImpl(
isolate->ThrowException(
v8::Exception::Error(GetV8String(isolate, exception)));
}
// Proceed with execution of the Accessor, if any.
// TODO(cef): Allow the CefV8Interceptor::Set callback to stop propegation by
// returning a bool value.
return v8::Intercepted::kNo;
}
// V8 extension registration.
@ -1337,8 +1349,11 @@ CefRefPtr<CefV8Value> CefV8Value::CreateObject(
nullptr, v8::Local<v8::Value>(),
v8::PropertyHandlerFlags::kOnlyInterceptStrings));
tmpl->SetIndexedPropertyHandler(InterceptorGetterCallbackImpl<uint32_t>,
InterceptorSetterCallbackImpl<uint32_t>);
// TODO(cef): Implement additional Query and Enumerator callbacks.
// See https://crbug.com/328490288#comment6.
tmpl->SetHandler(v8::IndexedPropertyHandlerConfiguration(
InterceptorGetterCallbackImpl<uint32_t>,
InterceptorSetterCallbackImpl<uint32_t>));
v8::MaybeLocal<v8::Object> maybe_object = tmpl->NewInstance(context);
if (!maybe_object.ToLocal<v8::Object>(&obj)) {
@ -2124,7 +2139,6 @@ bool CefV8ValueImpl::SetValue(int index, CefRefPtr<CefV8Value> value) {
}
bool CefV8ValueImpl::SetValue(const CefString& key,
AccessControl settings,
PropertyAttribute attribute) {
CEF_V8_REQUIRE_OBJECT_RETURN(false);
@ -2155,15 +2169,14 @@ bool CefV8ValueImpl::SetValue(const CefString& key,
v8::AccessorNameGetterCallback getter = AccessorNameGetterCallbackImpl;
v8::AccessorNameSetterCallback setter =
(attribute & V8_PROPERTY_ATTRIBUTE_READONLY)
? nullptr
? EmptySetterCallbackImpl
: AccessorNameSetterCallbackImpl;
v8::TryCatch try_catch(isolate);
try_catch.SetVerbose(true);
v8::Maybe<bool> set =
obj->SetAccessor(context, GetV8String(isolate, key), getter, setter, obj,
static_cast<v8::AccessControl>(settings),
static_cast<v8::PropertyAttribute>(attribute));
v8::Maybe<bool> set = obj->SetNativeDataProperty(
context, GetV8String(isolate, key), getter, setter, obj,
static_cast<v8::PropertyAttribute>(attribute));
return (!HasCaught(context, try_catch) && set.FromJust());
}

View File

@ -261,9 +261,7 @@ class CefV8ValueImpl : public CefV8Value {
CefRefPtr<CefV8Value> value,
PropertyAttribute attribute) override;
bool SetValue(int index, CefRefPtr<CefV8Value> value) override;
bool SetValue(const CefString& key,
AccessControl settings,
PropertyAttribute attribute) override;
bool SetValue(const CefString& key, PropertyAttribute attribute) override;
bool GetKeys(std::vector<CefString>& keys) override;
bool SetUserData(CefRefPtr<CefBaseRefCounted> user_data) override;
CefRefPtr<CefBaseRefCounted> GetUserData() override;

View File

@ -9,7 +9,7 @@
// implementations. See the translator.README.txt file in the tools directory
// for more information.
//
// $hash=b1970fff502586e8d6d473b36ec3d8008fbf7c2a$
// $hash=c59808566c2a9f2d204b6724bb5a905aeb0e7620$
//
#include "libcef_dll/cpptoc/v8value_cpptoc.h"
@ -782,7 +782,6 @@ int CEF_CALLBACK v8value_set_value_byindex(struct _cef_v8value_t* self,
int CEF_CALLBACK
v8value_set_value_byaccessor(struct _cef_v8value_t* self,
const cef_string_t* key,
cef_v8_accesscontrol_t settings,
cef_v8_propertyattribute_t attribute) {
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
@ -793,8 +792,8 @@ v8value_set_value_byaccessor(struct _cef_v8value_t* self,
// Unverified params: key
// Execute
bool _retval = CefV8ValueCppToC::Get(self)->SetValue(CefString(key), settings,
attribute);
bool _retval =
CefV8ValueCppToC::Get(self)->SetValue(CefString(key), attribute);
// Return type: bool
return _retval;

View File

@ -9,7 +9,7 @@
// implementations. See the translator.README.txt file in the tools directory
// for more information.
//
// $hash=3f2600b370dd8fbcb78b1728e458584bf24358f3$
// $hash=856fc6c190d0e3376824564155618e468764e841$
//
#include "libcef_dll/ctocpp/v8value_ctocpp.h"
@ -790,7 +790,6 @@ bool CefV8ValueCToCpp::SetValue(int index, CefRefPtr<CefV8Value> value) {
NO_SANITIZE("cfi-icall")
bool CefV8ValueCToCpp::SetValue(const CefString& key,
AccessControl settings,
PropertyAttribute attribute) {
cef_v8value_t* _struct = GetStruct();
if (CEF_MEMBER_MISSING(_struct, set_value_byaccessor)) {
@ -802,8 +801,8 @@ bool CefV8ValueCToCpp::SetValue(const CefString& key,
// Unverified params: key
// Execute
int _retval = _struct->set_value_byaccessor(_struct, key.GetStruct(),
settings, attribute);
int _retval =
_struct->set_value_byaccessor(_struct, key.GetStruct(), attribute);
// Return type: bool
return _retval ? true : false;

View File

@ -9,7 +9,7 @@
// implementations. See the translator.README.txt file in the tools directory
// for more information.
//
// $hash=962bf2f9c8f5628a19f96d379edbf5e83313a858$
// $hash=82c0a5d4a178b6731729c6fcc267388c19471cb0$
//
#ifndef CEF_LIBCEF_DLL_CTOCPP_V8VALUE_CTOCPP_H_
@ -72,9 +72,7 @@ class CefV8ValueCToCpp
CefRefPtr<CefV8Value> value,
PropertyAttribute attribute) override;
bool SetValue(int index, CefRefPtr<CefV8Value> value) override;
bool SetValue(const CefString& key,
AccessControl settings,
PropertyAttribute attribute) override;
bool SetValue(const CefString& key, PropertyAttribute attribute) override;
bool GetKeys(std::vector<CefString>& keys) override;
bool SetUserData(CefRefPtr<CefBaseRefCounted> user_data) override;
CefRefPtr<CefBaseRefCounted> GetUserData() override;

View File

@ -164,9 +164,6 @@ patches = [
# Fix DiscardableSharedMemoryManager crash on shutdown with multi-threaded
# message loop.
# https://github.com/chromiumembedded/cef/issues/2798
#
# win: Don't create console window for `--enable-logging=handle`
# https://chromium-review.googlesource.com/c/chromium/src/+/5381045
'name': 'content_main_654986',
},
{
@ -811,5 +808,11 @@ patches = [
# Fix dangling raw_ptr errors.
# https://github.com/chromiumembedded/cef/issues/3239
'name': 'raw_ptr_3239'
},
{
# Fix DCHECK(initiator_policy_container_host) failure when running
# RequestContextTest.PopupNavDestroyParentAfterCreationRCGlobal.
# https://issues.chromium.org/issues/323753235#comment11
'name': 'content_initiator_policy_323753235'
}
]

View File

@ -1,5 +1,5 @@
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 9f9c94cce4599..c6a25c4e2fa0c 100644
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() {

View File

@ -1,8 +1,8 @@
diff --git base/command_line.cc base/command_line.cc
index 3596432cb48b3..b7846f07f7b1d 100644
index 1e5e33b0c156d..be0ccb28fc627 100644
--- base/command_line.cc
+++ base/command_line.cc
@@ -384,11 +384,10 @@ void CommandLine::AppendSwitchNative(std::string_view switch_string,
@@ -389,11 +389,10 @@ void CommandLine::AppendSwitchNative(std::string_view switch_string,
#if BUILDFLAG(ENABLE_COMMANDLINE_SEQUENCE_CHECKS)
sequence_checker_.Check();
#endif

View File

@ -1,5 +1,5 @@
diff --git base/BUILD.gn base/BUILD.gn
index 5dc15da08eeff..4d98f417eabc3 100644
index 575149b2f3246..74719a39cf4e4 100644
--- base/BUILD.gn
+++ base/BUILD.gn
@@ -41,6 +41,7 @@ import("//build/nocompile.gni")
@ -37,7 +37,7 @@ index 5dc15da08eeff..4d98f417eabc3 100644
"cfgmgr32.lib",
"ntdll.lib",
diff --git base/allocator/dispatcher/dispatcher.cc base/allocator/dispatcher/dispatcher.cc
index 78f706cd6bef8..87eafa7a762f6 100644
index 2c5dfc7870ce8..7ed12711289b4 100644
--- base/allocator/dispatcher/dispatcher.cc
+++ base/allocator/dispatcher/dispatcher.cc
@@ -8,6 +8,7 @@
@ -88,7 +88,7 @@ index 1891e95fa387d..fc190dc39ae7d 100644
#else
#include "base/hash/sha1_boringssl.h"
diff --git base/rand_util.h base/rand_util.h
index a24e93122172e..5084668cb93a7 100644
index 746166bf75df7..7192a939e4fec 100644
--- base/rand_util.h
+++ base/rand_util.h
@@ -17,8 +17,9 @@
@ -102,7 +102,7 @@ index a24e93122172e..5084668cb93a7 100644
#include "third_party/boringssl/src/include/openssl/rand.h"
#endif
@@ -125,7 +126,7 @@ class RandomBitGenerator {
@@ -123,7 +124,7 @@ class RandomBitGenerator {
~RandomBitGenerator() = default;
};
@ -112,10 +112,10 @@ index a24e93122172e..5084668cb93a7 100644
public:
using result_type = uint64_t;
diff --git base/rand_util_win.cc base/rand_util_win.cc
index 299e54300a09d..cdc43cc48dce6 100644
index 6961e0ef8153c..8863f4ed65ee8 100644
--- base/rand_util_win.cc
+++ base/rand_util_win.cc
@@ -15,8 +15,12 @@
@@ -20,8 +20,12 @@
#include "base/check.h"
#include "base/feature_list.h"
@ -128,7 +128,7 @@ index 299e54300a09d..cdc43cc48dce6 100644
// Prototype for ProcessPrng.
// See: https://learn.microsoft.com/en-us/windows/win32/seccng/processprng
@@ -28,6 +32,7 @@ namespace base {
@@ -33,6 +37,7 @@ namespace base {
namespace internal {
@ -136,7 +136,7 @@ index 299e54300a09d..cdc43cc48dce6 100644
namespace {
// The BoringSSl helpers are duplicated in rand_util_fuchsia.cc and
@@ -49,6 +54,10 @@ bool UseBoringSSLForRandBytes() {
@@ -54,6 +59,10 @@ bool UseBoringSSLForRandBytes() {
return g_use_boringssl.load(std::memory_order_relaxed);
}
@ -147,15 +147,15 @@ index 299e54300a09d..cdc43cc48dce6 100644
} // namespace internal
namespace {
@@ -66,6 +75,7 @@ decltype(&ProcessPrng) GetProcessPrng() {
@@ -71,6 +80,7 @@ decltype(&ProcessPrng) GetProcessPrng() {
}
void RandBytes(span<uint8_t> output, bool avoid_allocation) {
void RandBytesInternal(span<uint8_t> output, bool avoid_allocation) {
+#if !BUILDFLAG(IS_CEF_SANDBOX_BUILD)
if (!avoid_allocation && internal::UseBoringSSLForRandBytes()) {
// Ensure BoringSSL is initialized so it can use things like RDRAND.
CRYPTO_library_init();
@@ -73,6 +83,7 @@ void RandBytes(span<uint8_t> output, bool avoid_allocation) {
@@ -78,6 +88,7 @@ void RandBytesInternal(span<uint8_t> output, bool avoid_allocation) {
(void)RAND_bytes(output.data(), output.size());
return;
}
@ -188,10 +188,10 @@ index 1f91a938caf55..e7b383ebe3986 100644
return lhs.token_ == rhs.token_;
#else
diff --git base/win/sid.cc base/win/sid.cc
index ccaf03323d60f..3d7a7513d1843 100644
index dd063382d97e1..6f8d6a0be91b1 100644
--- base/win/sid.cc
+++ base/win/sid.cc
@@ -17,6 +17,7 @@
@@ -22,6 +22,7 @@
#include <utility>
#include "base/check.h"
@ -199,7 +199,7 @@ index ccaf03323d60f..3d7a7513d1843 100644
#include "base/no_destructor.h"
#include "base/rand_util.h"
#include "base/ranges/algorithm.h"
@@ -24,8 +25,12 @@
@@ -29,8 +30,12 @@
#include "base/win/scoped_handle.h"
#include "base/win/scoped_localalloc.h"
#include "base/win/windows_version.h"
@ -212,7 +212,7 @@ index ccaf03323d60f..3d7a7513d1843 100644
namespace base::win {
@@ -126,6 +131,7 @@ Sid Sid::FromNamedCapability(const std::wstring& capability_name) {
@@ -131,6 +136,7 @@ Sid Sid::FromNamedCapability(const std::wstring& capability_name) {
if (known_cap != known_capabilities->end()) {
return FromKnownCapability(known_cap->second);
}
@ -220,7 +220,7 @@ index ccaf03323d60f..3d7a7513d1843 100644
CRYPTO_library_init();
static_assert((SHA256_DIGEST_LENGTH / sizeof(DWORD)) ==
SECURITY_APP_PACKAGE_RID_COUNT);
@@ -138,6 +144,10 @@ Sid Sid::FromNamedCapability(const std::wstring& capability_name) {
@@ -143,6 +149,10 @@ Sid Sid::FromNamedCapability(const std::wstring& capability_name) {
reinterpret_cast<uint8_t*>(&rids[2]));
return FromSubAuthorities(SECURITY_APP_PACKAGE_AUTHORITY, std::size(rids),
rids);

View File

@ -1,5 +1,5 @@
diff --git base/test/BUILD.gn base/test/BUILD.gn
index f50c2e942aed5..3a682be935a99 100644
index feafabc3a60f9..f78cafeadb879 100644
--- base/test/BUILD.gn
+++ base/test/BUILD.gn
@@ -191,11 +191,6 @@ static_library("test_support") {
@ -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 c469f1ee966ea..dec797956143f 100644
index 2439098be9ada..7235455526000 100644
--- content/shell/BUILD.gn
+++ content/shell/BUILD.gn
@@ -871,7 +871,6 @@ if (is_mac) {
@@ -908,7 +908,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

@ -1,5 +1,5 @@
diff --git content/browser/scheduler/browser_task_executor.cc content/browser/scheduler/browser_task_executor.cc
index 24f9538d6fd0d..0d57d47d70d38 100644
index 68b69f564d911..0dba72515782f 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 d660380d5d9ca..c0480add36259 100644
index 7822aeab4826a..fa72112bfee98 100644
--- content/browser/child_process_security_policy_impl.cc
+++ content/browser/child_process_security_policy_impl.cc
@@ -1953,6 +1953,16 @@ bool ChildProcessSecurityPolicyImpl::CanAccessMaybeOpaqueOrigin(
@@ -1988,6 +1988,16 @@ bool ChildProcessSecurityPolicyImpl::CanAccessMaybeOpaqueOrigin(
// DeclarativeApiTest.PersistRules.
if (actual_process_lock.matches_scheme(url::kDataScheme))
return true;
@ -20,10 +20,10 @@ index d660380d5d9ca..c0480add36259 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 5b2a0a561b948..2f0c7f9941877 100644
index e3dd21898b85e..2176fde9c1764 100644
--- content/browser/renderer_host/navigation_request.cc
+++ content/browser/renderer_host/navigation_request.cc
@@ -7944,10 +7944,22 @@ NavigationRequest::GetOriginForURLLoaderFactoryBeforeResponseWithDebugInfo(
@@ -7958,10 +7958,22 @@ NavigationRequest::GetOriginForURLLoaderFactoryBeforeResponseWithDebugInfo(
bool use_opaque_origin =
(sandbox_flags & network::mojom::WebSandboxFlags::kOrigin) ==
network::mojom::WebSandboxFlags::kOrigin;
@ -47,7 +47,7 @@ index 5b2a0a561b948..2f0c7f9941877 100644
}
return origin_and_debug_info;
@@ -8055,6 +8067,15 @@ NavigationRequest::GetOriginForURLLoaderFactoryAfterResponseWithDebugInfo() {
@@ -8069,6 +8081,15 @@ NavigationRequest::GetOriginForURLLoaderFactoryAfterResponseWithDebugInfo() {
DetermineInitiatorRelationship(initiator_rfh,
frame_tree_node_->current_frame_host()));

View File

@ -1,8 +1,8 @@
diff --git build/config/compiler/BUILD.gn build/config/compiler/BUILD.gn
index 973d8bcbd2f1f..385c865f0159e 100644
index 6efe967eb0a1c..429b3d8897085 100644
--- build/config/compiler/BUILD.gn
+++ build/config/compiler/BUILD.gn
@@ -137,6 +137,9 @@ declare_args() {
@@ -133,6 +133,9 @@ declare_args() {
# The cache can lead to non-determinism: https://crbug.com/1486045
thin_lto_enable_cache = true
@ -12,7 +12,7 @@ index 973d8bcbd2f1f..385c865f0159e 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,
@@ -2204,11 +2207,13 @@ config("export_dynamic") {
@@ -2179,11 +2182,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 70c3930b4d357..f71d0ff5bd9a7 100644
index c9ff70a8f2f71..d056d3758d564 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 70c3930b4d357..f71d0ff5bd9a7 100644
import("//chrome/browser/buildflags.gni")
import("//chrome/browser/downgrade/buildflags.gni")
import("//chrome/common/features.gni")
@@ -2089,6 +2090,7 @@ static_library("browser") {
@@ -2091,6 +2092,7 @@ static_library("browser") {
"//build/config/chromebox_for_meetings:buildflags",
"//build/config/compiler:compiler_buildflags",
"//cc",
@ -18,7 +18,7 @@ index 70c3930b4d357..f71d0ff5bd9a7 100644
"//chrome:extra_resources",
"//chrome:resources",
"//chrome:strings",
@@ -2759,6 +2761,10 @@ static_library("browser") {
@@ -2790,6 +2792,10 @@ static_library("browser") {
]
}

View File

@ -1,8 +1,8 @@
diff --git chrome/browser/browser_process.h chrome/browser/browser_process.h
index 0a7910bc42894..7dc340fb9c29e 100644
index 21ab47267370b..eb9b383727995 100644
--- chrome/browser/browser_process.h
+++ chrome/browser/browser_process.h
@@ -210,9 +210,9 @@ class BrowserProcess {
@@ -211,9 +211,9 @@ class BrowserProcess {
virtual DownloadStatusUpdater* download_status_updater() = 0;
virtual DownloadRequestLimiter* download_request_limiter() = 0;
@ -14,10 +14,10 @@ index 0a7910bc42894..7dc340fb9c29e 100644
std::unique_ptr<BackgroundModeManager> manager) = 0;
#endif
diff --git chrome/browser/browser_process_impl.cc chrome/browser/browser_process_impl.cc
index 19949bdecce72..cf4ed48fff5ce 100644
index f77210dcc2ff5..1d0eaa8ff245d 100644
--- chrome/browser/browser_process_impl.cc
+++ chrome/browser/browser_process_impl.cc
@@ -1097,18 +1097,14 @@ DownloadRequestLimiter* BrowserProcessImpl::download_request_limiter() {
@@ -1113,18 +1113,14 @@ DownloadRequestLimiter* BrowserProcessImpl::download_request_limiter() {
return download_request_limiter_.get();
}
@ -38,10 +38,10 @@ index 19949bdecce72..cf4ed48fff5ce 100644
std::unique_ptr<BackgroundModeManager> manager) {
background_mode_manager_ = std::move(manager);
diff --git chrome/browser/browser_process_impl.h chrome/browser/browser_process_impl.h
index e4cfec362d50c..2c17d0307601c 100644
index 8091cc691f093..9f16156c1f2cb 100644
--- chrome/browser/browser_process_impl.h
+++ chrome/browser/browser_process_impl.h
@@ -191,8 +191,8 @@ class BrowserProcessImpl : public BrowserProcess,
@@ -194,8 +194,8 @@ class BrowserProcessImpl : public BrowserProcess,
void SetApplicationLocale(const std::string& actual_locale) override;
DownloadStatusUpdater* download_status_updater() override;
DownloadRequestLimiter* download_request_limiter() override;

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 8fbc9ab537c6d..e87d068678767 100644
index e857e2363da9e..3dd4db8ae4267 100644
--- chrome/browser/devtools/devtools_window.cc
+++ chrome/browser/devtools/devtools_window.cc
@@ -37,6 +37,7 @@
@ -38,7 +38,7 @@ index 8fbc9ab537c6d..e87d068678767 100644
}
// Create WebContents with devtools.
@@ -1908,12 +1916,28 @@ void DevToolsWindow::CreateDevToolsBrowser() {
@@ -1916,12 +1924,28 @@ void DevToolsWindow::CreateDevToolsBrowser() {
Browser::CreationStatus::kOk) {
return;
}
@ -74,7 +74,7 @@ index 8fbc9ab537c6d..e87d068678767 100644
}
diff --git chrome/browser/ui/BUILD.gn chrome/browser/ui/BUILD.gn
index d6c14b3d70a75..577586f0dd8b4 100644
index 6ca4ed42a601d..feec87943fee4 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 d6c14b3d70a75..577586f0dd8b4 100644
import("//chrome/browser/buildflags.gni")
import("//chrome/common/features.gni")
import("//chromeos/ash/components/assistant/assistant.gni")
@@ -401,6 +402,10 @@ static_library("ui") {
@@ -403,6 +404,10 @@ static_library("ui") {
"//build/config/compiler:wexit_time_destructors",
]
@ -96,7 +96,7 @@ index d6c14b3d70a75..577586f0dd8b4 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
@@ -426,6 +431,7 @@ static_library("ui") {
@@ -429,6 +434,7 @@ static_library("ui") {
"//build:chromeos_buildflags",
"//build/config/chromebox_for_meetings:buildflags",
"//cc/paint",
@ -104,7 +104,7 @@ index d6c14b3d70a75..577586f0dd8b4 100644
"//chrome:resources",
"//chrome:strings",
"//chrome/app:chrome_dll_resources",
@@ -2979,6 +2985,8 @@ static_library("ui") {
@@ -3000,6 +3006,8 @@ static_library("ui") {
"views/apps/app_dialog/app_block_dialog_view.h",
"views/apps/app_dialog/app_pause_dialog_view.cc",
"views/apps/app_dialog/app_pause_dialog_view.h",
@ -113,7 +113,7 @@ index d6c14b3d70a75..577586f0dd8b4 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",
@@ -5062,8 +5070,6 @@ static_library("ui") {
@@ -5113,8 +5121,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 +122,7 @@ index d6c14b3d70a75..577586f0dd8b4 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",
@@ -6895,6 +6901,7 @@ static_library("ui") {
@@ -6965,6 +6971,7 @@ static_library("ui") {
if (enable_printing) {
deps += [
"//components/printing/browser",
@ -131,10 +131,10 @@ index d6c14b3d70a75..577586f0dd8b4 100644
]
}
diff --git chrome/browser/ui/browser.cc chrome/browser/ui/browser.cc
index cf9de7df6299d..3f93ff73ab038 100644
index a1d50c2e47056..5519a1c7714d5 100644
--- chrome/browser/ui/browser.cc
+++ chrome/browser/ui/browser.cc
@@ -267,6 +267,25 @@
@@ -269,6 +269,25 @@
#include "components/captive_portal/content/captive_portal_tab_helper.h"
#endif
@ -160,7 +160,7 @@ index cf9de7df6299d..3f93ff73ab038 100644
#if BUILDFLAG(ENABLE_EXTENSIONS)
#include "chrome/browser/extensions/extension_browser_window_helper.h"
#endif
@@ -476,6 +495,10 @@ Browser::Browser(const CreateParams& params)
@@ -515,6 +534,10 @@ Browser::Browser(const CreateParams& params)
type_(params.type),
profile_(params.profile),
window_(nullptr),
@ -171,7 +171,7 @@ index cf9de7df6299d..3f93ff73ab038 100644
tab_strip_model_delegate_(
std::make_unique<chrome::BrowserTabStripModelDelegate>(this)),
tab_strip_model_(std::make_unique<TabStripModel>(
@@ -678,6 +701,12 @@ Browser::~Browser() {
@@ -722,6 +745,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 +184,7 @@ index cf9de7df6299d..3f93ff73ab038 100644
}
///////////////////////////////////////////////////////////////////////////////
@@ -1109,6 +1138,8 @@ void Browser::WindowFullscreenStateChanged() {
@@ -1170,6 +1199,8 @@ void Browser::WindowFullscreenStateChanged() {
->WindowFullscreenStateChanged();
command_controller_->FullscreenStateChanged();
UpdateBookmarkBarState(BOOKMARK_BAR_STATE_CHANGE_TOGGLE_FULLSCREEN);
@ -193,7 +193,7 @@ index cf9de7df6299d..3f93ff73ab038 100644
}
void Browser::FullscreenTopUIStateChanged() {
@@ -1450,6 +1481,14 @@ content::KeyboardEventProcessingResult Browser::PreHandleKeyboardEvent(
@@ -1511,6 +1542,14 @@ content::KeyboardEventProcessingResult Browser::PreHandleKeyboardEvent(
if (exclusive_access_manager_->HandleUserKeyEvent(event))
return content::KeyboardEventProcessingResult::HANDLED;
@ -208,7 +208,7 @@ index cf9de7df6299d..3f93ff73ab038 100644
return window()->PreHandleKeyboardEvent(event);
}
@@ -1457,8 +1496,18 @@ bool Browser::HandleKeyboardEvent(content::WebContents* source,
@@ -1518,8 +1557,18 @@ bool Browser::HandleKeyboardEvent(content::WebContents* source,
const NativeWebKeyboardEvent& event) {
DevToolsWindow* devtools_window =
DevToolsWindow::GetInstanceForInspectedWebContents(source);
@ -229,7 +229,7 @@ index cf9de7df6299d..3f93ff73ab038 100644
}
bool Browser::TabsNeedBeforeUnloadFired() const {
@@ -1660,6 +1709,16 @@ WebContents* Browser::OpenURLFromTab(
@@ -1695,6 +1744,16 @@ WebContents* Browser::OpenURLFromTab(
}
#endif // BUILDFLAG(IS_CHROMEOS_ASH)
@ -246,7 +246,7 @@ index cf9de7df6299d..3f93ff73ab038 100644
NavigateParams nav_params(this, params.url, params.transition);
nav_params.FillNavigateParamsFromOpenURLParams(params);
nav_params.source_contents = source;
@@ -1822,6 +1881,8 @@ void Browser::LoadingStateChanged(WebContents* source,
@@ -1857,6 +1916,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 +255,7 @@ index cf9de7df6299d..3f93ff73ab038 100644
}
void Browser::CloseContents(WebContents* source) {
@@ -1850,6 +1911,8 @@ void Browser::SetContentsBounds(WebContents* source, const gfx::Rect& bounds) {
@@ -1885,6 +1946,8 @@ void Browser::SetContentsBounds(WebContents* source, const gfx::Rect& bounds) {
}
void Browser::UpdateTargetURL(WebContents* source, const GURL& url) {
@ -264,7 +264,7 @@ index cf9de7df6299d..3f93ff73ab038 100644
if (!GetStatusBubble())
return;
@@ -1857,6 +1920,17 @@ void Browser::UpdateTargetURL(WebContents* source, const GURL& url) {
@@ -1892,6 +1955,17 @@ void Browser::UpdateTargetURL(WebContents* source, const GURL& url) {
GetStatusBubble()->SetURL(url);
}
@ -279,10 +279,10 @@ index cf9de7df6299d..3f93ff73ab038 100644
+ return false;
+}
+
void Browser::ContentsMouseEvent(WebContents* source,
bool motion,
bool exited) {
@@ -1881,6 +1955,19 @@ bool Browser::TakeFocus(content::WebContents* source, bool reverse) {
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) {
return false;
}
@ -302,7 +302,7 @@ index cf9de7df6299d..3f93ff73ab038 100644
void Browser::BeforeUnloadFired(WebContents* web_contents,
bool proceed,
bool* proceed_to_fire_unload) {
@@ -1980,12 +2067,24 @@ void Browser::WebContentsCreated(WebContents* source_contents,
@@ -2018,12 +2105,24 @@ void Browser::WebContentsCreated(WebContents* source_contents,
// Make the tab show up in the task manager.
task_manager::WebContentsTags::CreateForTabContents(new_contents);
@ -327,7 +327,7 @@ index cf9de7df6299d..3f93ff73ab038 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();
@@ -1998,6 +2097,13 @@ void Browser::RendererUnresponsive(
@@ -2036,6 +2135,13 @@ void Browser::RendererUnresponsive(
void Browser::RendererResponsive(
WebContents* source,
content::RenderWidgetHost* render_widget_host) {
@ -341,7 +341,7 @@ index cf9de7df6299d..3f93ff73ab038 100644
RenderWidgetHostView* view = render_widget_host->GetView();
if (view && !render_widget_host->GetView()->IsHTMLFormPopup()) {
TabDialogs::FromWebContents(source)->HideHungRendererDialog(
@@ -2051,6 +2157,11 @@ void Browser::DraggableRegionsChanged(
@@ -2089,6 +2195,11 @@ void Browser::DraggableRegionsChanged(
if (app_controller_) {
app_controller_->DraggableRegionsChanged(regions, contents);
}
@ -353,7 +353,7 @@ index cf9de7df6299d..3f93ff73ab038 100644
}
void Browser::DidFinishNavigation(
@@ -2132,11 +2243,15 @@ void Browser::EnterFullscreenModeForTab(
@@ -2169,11 +2280,15 @@ void Browser::EnterFullscreenModeForTab(
const blink::mojom::FullscreenOptions& options) {
exclusive_access_manager_->fullscreen_controller()->EnterFullscreenModeForTab(
requesting_frame, options.display_id);
@ -369,7 +369,7 @@ index cf9de7df6299d..3f93ff73ab038 100644
}
bool Browser::IsFullscreenForTabOrPending(const WebContents* web_contents) {
@@ -2336,6 +2451,15 @@ void Browser::RequestMediaAccessPermission(
@@ -2373,6 +2488,15 @@ void Browser::RequestMediaAccessPermission(
content::WebContents* web_contents,
const content::MediaStreamRequest& request,
content::MediaResponseCallback callback) {
@ -385,7 +385,7 @@ index cf9de7df6299d..3f93ff73ab038 100644
const extensions::Extension* extension =
GetExtensionForOrigin(profile_, request.security_origin);
MediaCaptureDevicesDispatcher::GetInstance()->ProcessMediaAccessRequest(
@@ -2880,9 +3004,11 @@ void Browser::RemoveScheduledUpdatesFor(WebContents* contents) {
@@ -2917,9 +3041,11 @@ void Browser::RemoveScheduledUpdatesFor(WebContents* contents) {
// Browser, Getters for UI (private):
StatusBubble* Browser::GetStatusBubble() {
@ -398,7 +398,7 @@ index cf9de7df6299d..3f93ff73ab038 100644
}
// We hide the status bar for web apps windows as this matches native
@@ -2890,6 +3016,12 @@ StatusBubble* Browser::GetStatusBubble() {
@@ -2927,6 +3053,12 @@ StatusBubble* Browser::GetStatusBubble() {
// mode, as the minimal browser UI includes the status bar.
if (web_app::AppBrowserController::IsWebApp(this) &&
!app_controller()->HasMinimalUiButtons()) {
@ -411,7 +411,7 @@ index cf9de7df6299d..3f93ff73ab038 100644
return nullptr;
}
@@ -3026,6 +3158,8 @@ void Browser::SetAsDelegate(WebContents* web_contents, bool set_delegate) {
@@ -3076,6 +3208,8 @@ void Browser::SetAsDelegate(WebContents* web_contents, bool set_delegate) {
BookmarkTabHelper::FromWebContents(web_contents)->RemoveObserver(this);
web_contents_collection_.StopObserving(web_contents);
}
@ -420,7 +420,7 @@ index cf9de7df6299d..3f93ff73ab038 100644
}
void Browser::TabDetachedAtImpl(content::WebContents* contents,
@@ -3180,6 +3314,14 @@ bool Browser::PictureInPictureBrowserSupportsWindowFeature(
@@ -3230,6 +3364,14 @@ bool Browser::PictureInPictureBrowserSupportsWindowFeature(
bool Browser::SupportsWindowFeatureImpl(WindowFeature feature,
bool check_can_support) const {
@ -436,7 +436,7 @@ index cf9de7df6299d..3f93ff73ab038 100644
case TYPE_NORMAL:
return NormalBrowserSupportsWindowFeature(feature, check_can_support);
diff --git chrome/browser/ui/browser.h chrome/browser/ui/browser.h
index 6a3a4af355be9..b04d27dab01ed 100644
index af562dfe07909..c81b2b05a85df 100644
--- chrome/browser/ui/browser.h
+++ chrome/browser/ui/browser.h
@@ -22,6 +22,7 @@
@ -447,7 +447,7 @@ index 6a3a4af355be9..b04d27dab01ed 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"
@@ -49,6 +50,10 @@
@@ -50,6 +51,10 @@
#include "ui/gfx/geometry/rect.h"
#include "ui/shell_dialogs/select_file_dialog.h"
@ -458,7 +458,7 @@ index 6a3a4af355be9..b04d27dab01ed 100644
#if BUILDFLAG(IS_ANDROID)
#error This file should only be included on desktop.
#endif
@@ -365,6 +370,15 @@ class Browser : public TabStripModelObserver,
@@ -367,6 +372,15 @@ class Browser : public TabStripModelObserver,
// Document Picture in Picture options, specific to TYPE_PICTURE_IN_PICTURE.
std::optional<blink::mojom::PictureInPictureWindowOptions> pip_options;
@ -474,7 +474,7 @@ index 6a3a4af355be9..b04d27dab01ed 100644
private:
friend class Browser;
friend class WindowSizerChromeOSTest;
@@ -446,6 +460,13 @@ class Browser : public TabStripModelObserver,
@@ -448,6 +462,13 @@ class Browser : public TabStripModelObserver,
update_ui_immediately_for_testing_ = true;
}
@ -488,7 +488,7 @@ index 6a3a4af355be9..b04d27dab01ed 100644
// Accessors ////////////////////////////////////////////////////////////////
const CreateParams& create_params() const { return create_params_; }
@@ -536,6 +557,12 @@ class Browser : public TabStripModelObserver,
@@ -541,6 +562,12 @@ class Browser : public TabStripModelObserver,
base::WeakPtr<Browser> AsWeakPtr();
base::WeakPtr<const Browser> AsWeakPtr() const;
@ -501,7 +501,7 @@ index 6a3a4af355be9..b04d27dab01ed 100644
// Get the FindBarController for this browser, creating it if it does not
// yet exist.
FindBarController* GetFindBarController();
@@ -947,11 +974,19 @@ class Browser : public TabStripModelObserver,
@@ -947,10 +974,18 @@ class Browser : public TabStripModelObserver,
void SetContentsBounds(content::WebContents* source,
const gfx::Rect& bounds) override;
void UpdateTargetURL(content::WebContents* source, const GURL& url) override;
@ -511,8 +511,7 @@ index 6a3a4af355be9..b04d27dab01ed 100644
+ int32_t line_no,
+ const std::u16string& source_id) override;
void ContentsMouseEvent(content::WebContents* source,
bool motion,
bool exited) override;
const ui::Event& event) override;
void ContentsZoomChange(bool zoom_in) override;
bool TakeFocus(content::WebContents* source, bool reverse) override;
+ void CanDownload(const GURL& url,
@ -521,7 +520,7 @@ index 6a3a4af355be9..b04d27dab01ed 100644
void BeforeUnloadFired(content::WebContents* source,
bool proceed,
bool* proceed_to_fire_unload) override;
@@ -1289,6 +1324,10 @@ class Browser : public TabStripModelObserver,
@@ -1292,6 +1327,10 @@ class Browser : public TabStripModelObserver,
// This Browser's window.
raw_ptr<BrowserWindow, DanglingUntriaged> window_;
@ -532,7 +531,7 @@ index 6a3a4af355be9..b04d27dab01ed 100644
std::unique_ptr<TabStripModelDelegate> const tab_strip_model_delegate_;
std::unique_ptr<TabStripModel> const tab_strip_model_;
@@ -1355,6 +1394,8 @@ class Browser : public TabStripModelObserver,
@@ -1358,6 +1397,8 @@ class Browser : public TabStripModelObserver,
const std::string initial_workspace_;
bool initial_visible_on_all_workspaces_state_;
@ -542,7 +541,7 @@ index 6a3a4af355be9..b04d27dab01ed 100644
UnloadController unload_controller_;
diff --git chrome/browser/ui/browser_navigator.cc chrome/browser/ui/browser_navigator.cc
index cefb9f62051fe..6e19377f78e4f 100644
index 1bf5227d7c252..250012b2eb5fb 100644
--- chrome/browser/ui/browser_navigator.cc
+++ chrome/browser/ui/browser_navigator.cc
@@ -313,6 +313,10 @@ std::pair<Browser*, int> GetBrowserAndTabForDisposition(

View File

@ -1,5 +1,5 @@
diff --git chrome/browser/content_settings/host_content_settings_map_factory.cc chrome/browser/content_settings/host_content_settings_map_factory.cc
index 9356bf044a318..883c322eef5bb 100644
index a344dc5c74ce3..548e6218b0e82 100644
--- chrome/browser/content_settings/host_content_settings_map_factory.cc
+++ chrome/browser/content_settings/host_content_settings_map_factory.cc
@@ -9,6 +9,7 @@
@ -21,7 +21,7 @@ index 9356bf044a318..883c322eef5bb 100644
#if BUILDFLAG(ENABLE_EXTENSIONS)
#include "base/trace_event/trace_event.h"
#include "extensions/browser/api/content_settings/content_settings_custom_extension_provider.h"
@@ -58,7 +63,13 @@ HostContentSettingsMapFactory::HostContentSettingsMapFactory()
@@ -60,7 +65,13 @@ HostContentSettingsMapFactory::HostContentSettingsMapFactory()
#endif
DependsOn(OneTimePermissionsTrackerFactory::GetInstance());
#if BUILDFLAG(ENABLE_EXTENSIONS)
@ -35,8 +35,8 @@ index 9356bf044a318..883c322eef5bb 100644
#endif
// Used by way of ShouldRestoreOldSessionCookies().
#if BUILDFLAG(ENABLE_SESSION_SERVICE)
@@ -112,6 +123,9 @@ scoped_refptr<RefcountedKeyedService>
std::move(allowlist_provider));
@@ -113,6 +124,9 @@ scoped_refptr<RefcountedKeyedService>
std::move(allowlist_provider));
#if BUILDFLAG(ENABLE_EXTENSIONS)
+#if BUILDFLAG(ENABLE_ALLOY_BOOTSTRAP)
@ -45,7 +45,7 @@ index 9356bf044a318..883c322eef5bb 100644
// These must be registered before before the HostSettings are passed over to
// the IOThread. Simplest to do this on construction.
settings_map->RegisterProvider(
@@ -124,6 +138,9 @@ scoped_refptr<RefcountedKeyedService>
@@ -125,6 +139,9 @@ scoped_refptr<RefcountedKeyedService>
// the case where profile->IsOffTheRecord() is true? And what is the
// interaction with profile->IsGuestSession()?
false));

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 72a2b681d5b98..8f7368add83fb 100644
index b62e659a27d00..e76cc7c0a7813 100644
--- chrome/browser/renderer_context_menu/render_view_context_menu.cc
+++ chrome/browser/renderer_context_menu/render_view_context_menu.cc
@@ -358,6 +358,18 @@ base::OnceCallback<void(RenderViewContextMenu*)>* GetMenuShownCallback() {
@@ -357,6 +357,18 @@ base::OnceCallback<void(RenderViewContextMenu*)>* GetMenuShownCallback() {
return callback.get();
}
@ -21,7 +21,7 @@ index 72a2b681d5b98..8f7368add83fb 100644
enum class UmaEnumIdLookupType {
GeneralEnumId,
ContextSpecificEnumId,
@@ -615,6 +627,10 @@ int FindUMAEnumValueForCommand(int id, UmaEnumIdLookupType type) {
@@ -618,6 +630,10 @@ int FindUMAEnumValueForCommand(int id, UmaEnumIdLookupType type) {
if (ContextMenuMatcher::IsExtensionsCustomCommandId(id))
return 1;
@ -32,7 +32,7 @@ index 72a2b681d5b98..8f7368add83fb 100644
id = CollapseCommandsForUMA(id);
const auto& map = GetIdcToUmaMap(type);
auto it = map.find(id);
@@ -865,6 +881,14 @@ RenderViewContextMenu::RenderViewContextMenu(
@@ -868,6 +884,14 @@ RenderViewContextMenu::RenderViewContextMenu(
pdf_ocr_submenu_model_ = std::make_unique<ui::SimpleMenuModel>(this);
#endif // BUILDFLAG(ENABLE_SCREEN_AI_SERVICE)
@ -47,8 +47,8 @@ index 72a2b681d5b98..8f7368add83fb 100644
observers_.AddObserver(&autofill_context_menu_manager_);
}
@@ -1339,6 +1363,12 @@ void RenderViewContextMenu::InitMenu() {
autofill::PopupHidingReason::kContextMenuOpened);
@@ -1343,6 +1367,12 @@ void RenderViewContextMenu::InitMenu() {
autofill::SuggestionHidingReason::kContextMenuOpened);
}
}
+
@ -60,7 +60,7 @@ index 72a2b681d5b98..8f7368add83fb 100644
}
Profile* RenderViewContextMenu::GetProfile() const {
@@ -3572,6 +3602,26 @@ void RenderViewContextMenu::RegisterExecutePluginActionCallbackForTesting(
@@ -3564,6 +3594,26 @@ void RenderViewContextMenu::RegisterExecutePluginActionCallbackForTesting(
execute_plugin_action_callback_ = std::move(cb);
}
@ -88,7 +88,7 @@ index 72a2b681d5b98..8f7368add83fb 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 548004a597fa0..f63405fa8badc 100644
index 6c59d4ccaf3d5..21c959aea9c21 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
@ -113,7 +113,7 @@ index 548004a597fa0..f63405fa8badc 100644
Profile* GetProfile() const;
// This may return nullptr (e.g. for WebUI dialogs). Virtual to allow tests to
@@ -465,6 +479,9 @@ class RenderViewContextMenu
@@ -464,6 +478,9 @@ class RenderViewContextMenu
// built.
bool is_protocol_submenu_valid_ = false;

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 19c2d39b6aa73..099dcb71a6373 100644
index ee871fcaed0fd..96480a8bd5db7 100644
--- chrome/browser/devtools/chrome_devtools_manager_delegate.cc
+++ chrome/browser/devtools/chrome_devtools_manager_delegate.cc
@@ -13,6 +13,7 @@
@ -10,7 +10,7 @@ index 19c2d39b6aa73..099dcb71a6373 100644
#include "chrome/browser/browser_features.h"
#include "chrome/browser/devtools/chrome_devtools_session.h"
#include "chrome/browser/devtools/device/android_device_manager.h"
@@ -66,6 +67,10 @@
@@ -67,6 +68,10 @@
#include "ash/constants/ash_switches.h"
#endif
@ -21,7 +21,7 @@ index 19c2d39b6aa73..099dcb71a6373 100644
using content::DevToolsAgentHost;
const char ChromeDevToolsManagerDelegate::kTypeApp[] = "app";
@@ -246,6 +251,12 @@ std::string ChromeDevToolsManagerDelegate::GetTargetType(
@@ -247,6 +252,12 @@ std::string ChromeDevToolsManagerDelegate::GetTargetType(
return DevToolsAgentHost::kTypePage;
}

View File

@ -344,10 +344,10 @@ 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 cb1a0d203b448..307158e8117fe 100644
index e5d4311ba152c..16c86e544fe3a 100644
--- ui/shell_dialogs/select_file_dialog_win.cc
+++ ui/shell_dialogs/select_file_dialog_win.cc
@@ -253,6 +253,8 @@ void SelectFileDialogImpl::SelectFileImpl(
@@ -254,6 +254,8 @@ void SelectFileDialogImpl::SelectFileImpl(
HWND owner = owning_window && owning_window->GetRootWindow()
? owning_window->GetHost()->GetAcceleratedWidget()
: nullptr;

View File

@ -12,36 +12,32 @@ 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 630ede12ce3f8..b7bc765e3eb99 100644
index a2ca2f52148fd..7689d43ec9e0b 100644
--- components/constrained_window/constrained_window_views.cc
+++ components/constrained_window/constrained_window_views.cc
@@ -105,15 +105,24 @@ void UpdateModalDialogPosition(views::Widget* widget,
if (widget->HasCapture())
return;
@@ -101,9 +101,18 @@ 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 =
- views::Widget::GetWidgetForNativeView(dialog_host->GetHostView());
+ views::Widget* host_widget =
+ host_view ? views::Widget::GetWidgetForNativeView(host_view) : nullptr;
+
+ // If the host view is not backed by a Views::Widget, just update the widget
+ // 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) {
+ return gfx::Rect(dialog_host->GetDialogPosition(size), size);
+ }
// If the host view is not backed by a Views::Widget, just update the widget
// 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 BUILDFLAG(IS_MAC)
widget->SetSize(size);
+#elif BUILDFLAG(IS_POSIX)
+ // Set the bounds here instead of relying on the default behavior of
+ // DesktopWindowTreeHostPlatform::CenterWindow which incorrectly centers
+ // the window on the screen.
+ widget->SetBounds(gfx::Rect(dialog_host->GetDialogPosition(size), size));
+#endif
return;
}
@@ -123,44 +132,22 @@ void UpdateModalDialogPosition(views::Widget* widget,
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,
position.set_y(position.y() -
widget->non_client_view()->frame_view()->GetInsets().top());
@ -93,23 +89,40 @@ index 630ede12ce3f8..b7bc765e3eb99 100644
+ display_rect.AdjustToFit(work_area);
+ position = display_rect.origin();
}
- widget->SetBounds(dialog_bounds);
+ widget->SetBounds(gfx::Rect(position, size));
- return dialog_bounds;
+
+ return gfx::Rect(position, size);
}
} // namespace
@@ -242,7 +229,8 @@ views::Widget* CreateWebModalDialogViews(views::WidgetDelegate* dialog,
void UpdateModalDialogPosition(views::Widget* widget,
@@ -158,15 +146,24 @@ void UpdateModalDialogPosition(views::Widget* widget,
return;
}
views::Widget* widget = views::DialogDelegate::CreateDialogWidget(
dialog, nullptr,
- manager->delegate()->GetWebContentsModalDialogHost()->GetHostView());
+ manager->delegate()->GetWebContentsModalDialogHost()->GetHostView(),
+ manager->delegate()->GetWebContentsModalDialogHost()->GetAcceleratedWidget());
widget->SetNativeWindowProperty(
views::kWidgetIdentifierKey,
const_cast<void*>(kConstrainedWindowWidgetIdentifier));
@@ -264,8 +252,13 @@ views::Widget* CreateBrowserModalDialogViews(views::DialogDelegate* dialog,
- views::Widget* const host_widget =
- views::Widget::GetWidgetForNativeView(dialog_host->GetHostView());
+ // |host_view| will be nullptr with CEF windowless rendering.
+ auto host_view = dialog_host->GetHostView();
+ views::Widget* host_widget =
+ host_view ? views::Widget::GetWidgetForNativeView(host_view) : nullptr;
// If the host view is not backed by a Views::Widget, just update the widget
// 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 BUILDFLAG(IS_MAC)
widget->SetSize(size);
+#elif BUILDFLAG(IS_POSIX)
+ // Set the bounds here instead of relying on the default behavior of
+ // DesktopWindowTreeHostPlatform::CenterWindow which incorrectly centers
+ // the window on the screen.
+ widget->SetBounds(gfx::Rect(dialog_host->GetDialogPosition(size), size));
+#endif
return;
}
@@ -282,8 +279,13 @@ views::Widget* CreateBrowserModalDialogViews(views::DialogDelegate* dialog,
gfx::NativeView parent_view =
parent ? CurrentClient()->GetDialogHostView(parent) : nullptr;
@ -124,7 +137,7 @@ index 630ede12ce3f8..b7bc765e3eb99 100644
widget->SetNativeWindowProperty(
views::kWidgetIdentifierKey,
const_cast<void*>(kConstrainedWindowWidgetIdentifier));
@@ -281,8 +274,7 @@ views::Widget* CreateBrowserModalDialogViews(views::DialogDelegate* dialog,
@@ -299,8 +301,7 @@ views::Widget* CreateBrowserModalDialogViews(views::DialogDelegate* dialog,
if (!requires_positioning)
return widget;
@ -134,6 +147,25 @@ index 630ede12ce3f8..b7bc765e3eb99 100644
if (host) {
DCHECK_EQ(parent_view, host->GetHostView());
ModalDialogHostObserver* dialog_host_observer =
@@ -313,10 +314,17 @@ views::Widget* CreateBrowserModalDialogViews(views::DialogDelegate* dialog,
views::Widget* ShowBrowserModal(std::unique_ptr<ui::DialogModel> dialog_model,
gfx::NativeWindow parent) {
+ gfx::NativeView parent_view =
+ parent ? CurrentClient()->GetDialogHostView(parent) : nullptr;
+ // Use with CEF windowless rendering.
+ gfx::AcceleratedWidget parent_widget = parent ?
+ CurrentClient()->GetModalDialogHost(parent)->GetAcceleratedWidget() :
+ gfx::kNullAcceleratedWidget;
+
// TODO(crbug.com/41493925): Remove will_use_custom_frame once native frame
// dialogs support autosize.
bool will_use_custom_frame = views::DialogDelegate::CanSupportCustomFrame(
- parent ? CurrentClient()->GetDialogHostView(parent) : nullptr);
+ parent_view, parent_widget);
auto dialog = views::BubbleDialogModelHost::CreateModal(
std::move(dialog_model), ui::MODAL_TYPE_WINDOW, will_use_custom_frame);
dialog->SetOwnedByWidget(true);
diff --git components/constrained_window/native_web_contents_modal_dialog_manager_views.cc components/constrained_window/native_web_contents_modal_dialog_manager_views.cc
index 2b495a8ab092c..01a28aca853d0 100644
--- components/constrained_window/native_web_contents_modal_dialog_manager_views.cc
@ -178,10 +210,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 1361ac9b3d57b..5a41f86862561 100644
index 941699c28e286..3f6569b116e64 100644
--- ui/views/window/dialog_delegate.cc
+++ ui/views/window/dialog_delegate.cc
@@ -84,10 +84,12 @@ DialogDelegate::DialogDelegate() {
@@ -85,10 +85,12 @@ DialogDelegate::DialogDelegate() {
// static
Widget* DialogDelegate::CreateDialogWidget(WidgetDelegate* delegate,
gfx::NativeWindow context,
@ -196,7 +228,7 @@ index 1361ac9b3d57b..5a41f86862561 100644
widget->Init(std::move(params));
return widget;
}
@@ -96,17 +98,19 @@ Widget* DialogDelegate::CreateDialogWidget(WidgetDelegate* delegate,
@@ -97,17 +99,19 @@ Widget* DialogDelegate::CreateDialogWidget(WidgetDelegate* delegate,
Widget* DialogDelegate::CreateDialogWidget(
std::unique_ptr<WidgetDelegate> delegate,
gfx::NativeWindow context,
@ -220,7 +252,7 @@ index 1361ac9b3d57b..5a41f86862561 100644
#else
return true;
#endif
@@ -117,14 +121,15 @@ Widget::InitParams DialogDelegate::GetDialogWidgetInitParams(
@@ -118,14 +122,15 @@ Widget::InitParams DialogDelegate::GetDialogWidgetInitParams(
WidgetDelegate* delegate,
gfx::NativeWindow context,
gfx::NativeView parent,
@ -238,7 +270,7 @@ index 1361ac9b3d57b..5a41f86862561 100644
if (!dialog || dialog->use_custom_frame()) {
params.opacity = Widget::InitParams::WindowOpacity::kTranslucent;
@@ -137,6 +142,7 @@ Widget::InitParams DialogDelegate::GetDialogWidgetInitParams(
@@ -138,6 +143,7 @@ Widget::InitParams DialogDelegate::GetDialogWidgetInitParams(
}
params.context = context;
params.parent = parent;
@ -247,7 +279,7 @@ index 1361ac9b3d57b..5a41f86862561 100644
// Web-modal (ui::MODAL_TYPE_CHILD) dialogs with parents are marked as child
// widgets to prevent top-level window behavior (independent movement, etc).
diff --git ui/views/window/dialog_delegate.h ui/views/window/dialog_delegate.h
index de642a3bc1101..bdd8664f481a9 100644
index 3cb2a5e22972d..1a716178e3f51 100644
--- ui/views/window/dialog_delegate.h
+++ ui/views/window/dialog_delegate.h
@@ -97,13 +97,18 @@ class VIEWS_EXPORT DialogDelegate : public WidgetDelegate {

View File

@ -1,5 +1,5 @@
diff --git chrome/browser/download/chrome_download_manager_delegate.cc chrome/browser/download/chrome_download_manager_delegate.cc
index 447e7d0d5dc6d..7bba632f1331c 100644
index bc10e7566bd71..3b513b0b00b34 100644
--- chrome/browser/download/chrome_download_manager_delegate.cc
+++ chrome/browser/download/chrome_download_manager_delegate.cc
@@ -146,6 +146,10 @@
@ -85,7 +85,7 @@ index e2cf12d2c8fee..376818e28798c 100644
};
diff --git chrome/browser/download/download_prefs.cc chrome/browser/download/download_prefs.cc
index 773f72da82f90..0043dd530934d 100644
index 4ffbb8f5630d4..da0d2975b13d5 100644
--- chrome/browser/download/download_prefs.cc
+++ chrome/browser/download/download_prefs.cc
@@ -23,6 +23,7 @@
@ -107,7 +107,7 @@ index 773f72da82f90..0043dd530934d 100644
using content::BrowserContext;
using content::BrowserThread;
using content::DownloadManager;
@@ -355,6 +360,11 @@ DownloadPrefs* DownloadPrefs::FromDownloadManager(
@@ -351,6 +356,11 @@ DownloadPrefs* DownloadPrefs::FromDownloadManager(
// static
DownloadPrefs* DownloadPrefs::FromBrowserContext(
content::BrowserContext* context) {

View File

@ -34,7 +34,7 @@ index 4007e26f780c3..5f92d74018f9e 100644
}
diff --git chrome/browser/extensions/api/tabs/tabs_api.cc chrome/browser/extensions/api/tabs/tabs_api.cc
index 1eab73b209fea..fca0a2318202e 100644
index 3d0843c7d1a60..b07956d25797d 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() {
@ -153,7 +153,7 @@ index 46154f4501a36..81adec54cee06 100644
// Prerendering tab is not visible and it cannot be in `TabStripModel`, if
// the tab id exists as a prerendering tab, and the API will returns
diff --git chrome/browser/ui/tab_helpers.h chrome/browser/ui/tab_helpers.h
index 2f769363f8519..228c20926634b 100644
index 4ca4ecd147267..dc8a8d004a1d6 100644
--- chrome/browser/ui/tab_helpers.h
+++ chrome/browser/ui/tab_helpers.h
@@ -6,6 +6,7 @@
@ -175,7 +175,7 @@ index 2f769363f8519..228c20926634b 100644
// A "tab contents" is a WebContents that is used as a tab in a browser window
// (or the equivalent on Android). The TabHelpers class allows specific classes
// to attach the set of tab helpers that is used for tab contents.
@@ -75,6 +80,10 @@ class TabHelpers {
@@ -74,6 +79,10 @@ class TabHelpers {
// Link Preview shows a preview of a page, then promote it as a new tab.
friend class PreviewTab;
@ -187,10 +187,10 @@ index 2f769363f8519..228c20926634b 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 a76c331ec5344..ffe3cbe7ce37c 100644
index b667ccfe87ccf..65283ef921458 100644
--- chrome/browser/ui/views/download/bubble/download_toolbar_button_view.cc
+++ chrome/browser/ui/views/download/bubble/download_toolbar_button_view.cc
@@ -850,6 +850,10 @@ void DownloadToolbarButtonView::ShowPendingDownloadStartedAnimation() {
@@ -841,6 +841,10 @@ void DownloadToolbarButtonView::ShowPendingDownloadStartedAnimation() {
if (!gfx::Animation::ShouldRenderRichAnimation()) {
return;
}

View File

@ -49,7 +49,7 @@ 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 7f14b48feedf6..9679552640788 100644
index 6d07868a1100b..ac8fc5e70f045 100644
--- chrome/browser/permissions/chrome_permissions_client.cc
+++ chrome/browser/permissions/chrome_permissions_client.cc
@@ -14,6 +14,7 @@
@ -60,7 +60,7 @@ index 7f14b48feedf6..9679552640788 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"
@@ -190,6 +191,11 @@ ChromePermissionsClient::GetPermissionDecisionAutoBlocker(
@@ -198,6 +199,11 @@ ChromePermissionsClient::GetPermissionDecisionAutoBlocker(
double ChromePermissionsClient::GetSiteEngagementScore(
content::BrowserContext* browser_context,
const GURL& origin) {
@ -72,7 +72,7 @@ index 7f14b48feedf6..9679552640788 100644
return site_engagement::SiteEngagementService::Get(
Profile::FromBrowserContext(browser_context))
->GetScore(origin);
@@ -360,8 +366,14 @@ ChromePermissionsClient::CreatePermissionUiSelectors(
@@ -368,8 +374,14 @@ ChromePermissionsClient::CreatePermissionUiSelectors(
std::make_unique<ContextualNotificationPermissionUiSelector>());
selectors.emplace_back(std::make_unique<PrefBasedQuietPermissionUiSelector>(
Profile::FromBrowserContext(browser_context)));
@ -88,7 +88,7 @@ index 7f14b48feedf6..9679552640788 100644
}
diff --git chrome/browser/permissions/permission_manager_factory.cc chrome/browser/permissions/permission_manager_factory.cc
index 1ad4009827a9d..6aba08191cf35 100644
index 8cadbddb47767..879ed1cab0558 100644
--- chrome/browser/permissions/permission_manager_factory.cc
+++ chrome/browser/permissions/permission_manager_factory.cc
@@ -6,6 +6,7 @@
@ -99,10 +99,10 @@ index 1ad4009827a9d..6aba08191cf35 100644
#include "chrome/browser/background_fetch/background_fetch_permission_context.h"
#include "chrome/browser/background_sync/periodic_background_sync_permission_context.h"
#include "chrome/browser/content_settings/host_content_settings_map_factory.h"
@@ -64,9 +65,15 @@ permissions::PermissionManager::PermissionContextMap CreatePermissionContexts(
@@ -68,9 +69,15 @@ permissions::PermissionManager::PermissionContextMap CreatePermissionContexts(
std::make_unique<GeolocationPermissionContextDelegate>(profile);
#endif // BUILDFLAG(IS_ANDROID)
#if BUILDFLAG(IS_MAC) || BUILDFLAG(IS_CHROMEOS)
#if BUILDFLAG(OS_LEVEL_GEOLOCATION_PERMISSION_SUPPORTED)
+#if BUILDFLAG(ENABLE_ALLOY_BOOTSTRAP)
+ if (!cef::IsAlloyRuntimeEnabled()) {
+#endif
@ -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 613500ba8c3d3..36c9aa0d2ea71 100644
index 7bf3d2015afc8..8a58296f19c30 100644
--- chrome/browser/ui/views/permissions/permission_prompt_factory.cc
+++ chrome/browser/ui/views/permissions/permission_prompt_factory.cc
@@ -202,11 +202,28 @@ std::unique_ptr<permissions::PermissionPrompt> CreateQuietPrompt(
@@ -217,11 +217,28 @@ std::unique_ptr<permissions::PermissionPrompt> CreateQuietPrompt(
}
}
@ -194,7 +194,7 @@ index 613500ba8c3d3..36c9aa0d2ea71 100644
if (!browser) {
DLOG(WARNING) << "Permission prompt suppressed because the WebContents is "
diff --git components/embedder_support/permission_context_utils.cc components/embedder_support/permission_context_utils.cc
index 9c0ec651d494f..8ba6512557edc 100644
index 063b8e6c0747d..0b7deda8a97b3 100644
--- components/embedder_support/permission_context_utils.cc
+++ components/embedder_support/permission_context_utils.cc
@@ -5,6 +5,7 @@
@ -208,7 +208,7 @@ index 9c0ec651d494f..8ba6512557edc 100644
@@ -79,10 +80,21 @@ CreateDefaultPermissionContexts(content::BrowserContext* browser_context,
std::move(delegates.geolocation_permission_context_delegate),
is_regular_profile);
#elif BUILDFLAG(IS_MAC) || BUILDFLAG(IS_CHROMEOS)
#elif BUILDFLAG(OS_LEVEL_GEOLOCATION_PERMISSION_SUPPORTED)
+#if BUILDFLAG(ENABLE_ALLOY_BOOTSTRAP)
+ if (cef::IsAlloyRuntimeEnabled()) {
+ permission_contexts[ContentSettingsType::GEOLOCATION] =

View File

@ -1,5 +1,5 @@
diff --git chrome/browser/policy/browser_dm_token_storage_linux.cc chrome/browser/policy/browser_dm_token_storage_linux.cc
index 9fef3079833f4..43576d91d53f1 100644
index 02c801eb35549..2fa2e336a8cf7 100644
--- chrome/browser/policy/browser_dm_token_storage_linux.cc
+++ chrome/browser/policy/browser_dm_token_storage_linux.cc
@@ -22,6 +22,7 @@
@ -8,9 +8,9 @@ index 9fef3079833f4..43576d91d53f1 100644
#include "base/threading/scoped_blocking_call.h"
+#include "chrome/browser/policy/chrome_browser_policy_connector.h"
#include "chrome/common/chrome_paths.h"
#include "components/policy/core/common/policy_logger.h"
namespace policy {
@@ -116,8 +117,8 @@ std::string BrowserDMTokenStorageLinux::InitEnrollmentToken() {
@@ -121,8 +122,8 @@ std::string BrowserDMTokenStorageLinux::InitEnrollmentToken() {
std::string enrollment_token;
base::FilePath dir_policy_files_path;
@ -21,7 +21,7 @@ index 9fef3079833f4..43576d91d53f1 100644
return std::string();
}
@@ -147,8 +148,8 @@ bool BrowserDMTokenStorageLinux::InitEnrollmentErrorOption() {
@@ -152,8 +153,8 @@ bool BrowserDMTokenStorageLinux::InitEnrollmentErrorOption() {
std::string options;
base::FilePath dir_policy_files_path;
@ -33,7 +33,7 @@ index 9fef3079833f4..43576d91d53f1 100644
}
diff --git chrome/browser/policy/browser_dm_token_storage_mac.mm chrome/browser/policy/browser_dm_token_storage_mac.mm
index 27af6ec08f593..156689eec644d 100644
index d8fda08453256..466718e824503 100644
--- chrome/browser/policy/browser_dm_token_storage_mac.mm
+++ chrome/browser/policy/browser_dm_token_storage_mac.mm
@@ -27,6 +27,7 @@
@ -42,9 +42,9 @@ index 27af6ec08f593..156689eec644d 100644
#include "base/threading/scoped_blocking_call.h"
+#include "chrome/browser/policy/chrome_browser_policy_connector.h"
#include "chrome/common/chrome_paths.h"
#include "components/policy/core/common/policy_logger.h"
namespace policy {
@@ -47,11 +48,6 @@ const char kEnrollmentOptionsFilePath[] = FILE_PATH_LITERAL(
@@ -48,11 +49,6 @@ const char kEnrollmentOptionsFilePath[] = FILE_PATH_LITERAL(
"/Library/Google/Chrome/CloudManagementEnrollmentOptions");
const char kEnrollmentMandatoryOption[] = "Mandatory";
@ -56,7 +56,7 @@ index 27af6ec08f593..156689eec644d 100644
constexpr char kEnrollmentTokenMetricsName[] =
"Enterprise.CloudManagementEnrollmentTokenLocation.Mac";
@@ -104,16 +100,23 @@ bool DeleteDMTokenFromAppDataDir(const std::string& client_id) {
@@ -109,16 +105,23 @@ bool DeleteDMTokenFromAppDataDir(const std::string& client_id) {
// Get the enrollment token from policy file: /Library/com.google.Chrome.plist.
// Return true if policy is set, otherwise false.
bool GetEnrollmentTokenFromPolicy(std::string* enrollment_token) {
@ -82,7 +82,7 @@ index 27af6ec08f593..156689eec644d 100644
return false;
}
CFStringRef value_string = base::apple::CFCast<CFStringRef>(value.get());
@@ -138,12 +141,19 @@ bool GetEnrollmentTokenFromFile(std::string* enrollment_token) {
@@ -143,12 +146,19 @@ bool GetEnrollmentTokenFromFile(std::string* enrollment_token) {
}
std::optional<bool> IsEnrollmentMandatoryByPolicy() {
@ -254,7 +254,7 @@ index 50f1b5313ce45..687e667e4b942 100644
// If the folder containing the policy files doesn't exist, there's no need
// to have a provider for them. Note that in verified boot, the folder
diff --git chrome/browser/policy/chrome_browser_policy_connector.h chrome/browser/policy/chrome_browser_policy_connector.h
index 7d08b9b3a548e..c1acd530587a3 100644
index 8f90fe72995f3..4d818e1cc61c7 100644
--- chrome/browser/policy/chrome_browser_policy_connector.h
+++ chrome/browser/policy/chrome_browser_policy_connector.h
@@ -28,6 +28,10 @@
@ -357,7 +357,7 @@ index 8dbf958c189dd..6eaccc6688eca 100644
*dir = base::FilePath(policy::path_parser::ExpandPathVariables(value));
return true;
diff --git chrome/common/chrome_paths.cc chrome/common/chrome_paths.cc
index c94a25e390864..b47996eaeb902 100644
index 3c569bc610124..4f438a3d1f857 100644
--- chrome/common/chrome_paths.cc
+++ chrome/common/chrome_paths.cc
@@ -541,7 +541,8 @@ bool PathProvider(int key, base::FilePath* result) {
@ -371,7 +371,7 @@ index c94a25e390864..b47996eaeb902 100644
cur = base::FilePath(policy::kPolicyPath);
break;
diff --git chrome/common/chrome_paths.h chrome/common/chrome_paths.h
index 4cde94111918e..aaf8245abd9a6 100644
index 13abfd26b92b3..acb4d58f02650 100644
--- chrome/common/chrome_paths.h
+++ chrome/common/chrome_paths.h
@@ -8,6 +8,7 @@
@ -392,10 +392,10 @@ index 4cde94111918e..aaf8245abd9a6 100644
// policy files that allow sys-admins
// to set policies for chrome. This directory
diff --git components/policy/tools/generate_policy_source.py components/policy/tools/generate_policy_source.py
index aef54cfd633eb..a3760acb82ea5 100755
index be1553785d5b5..2446e30bea57e 100755
--- components/policy/tools/generate_policy_source.py
+++ components/policy/tools/generate_policy_source.py
@@ -449,6 +449,7 @@ def _WritePolicyConstantHeader(all_policies, policy_atomic_groups,
@@ -465,6 +465,7 @@ def _WritePolicyConstantHeader(all_policies, policy_atomic_groups,
#include <cstdint>
#include <string>
@ -403,7 +403,7 @@ index aef54cfd633eb..a3760acb82ea5 100755
#include "components/policy/core/common/policy_details.h"
#include "components/policy/core/common/policy_map.h"
@@ -471,9 +472,11 @@ struct SchemaData;
@@ -487,9 +488,11 @@ struct SchemaData;
''')
if target_platform == 'win':
@ -417,7 +417,7 @@ index aef54cfd633eb..a3760acb82ea5 100755
f.write('''#if BUILDFLAG(IS_CHROMEOS)
// Sets default profile policies values for enterprise users.
@@ -1116,7 +1119,8 @@ namespace policy {
@@ -1130,7 +1133,8 @@ namespace policy {
f.write('} // namespace\n\n')
if target_platform == 'win':
@ -427,7 +427,7 @@ index aef54cfd633eb..a3760acb82ea5 100755
'const wchar_t kRegistryChromePolicyKey[] = '
'L"' + CHROME_POLICY_KEY + '";\n'
'#elif BUILDFLAG(GOOGLE_CHROME_FOR_TESTING_BRANDING)\n'
@@ -1125,6 +1129,7 @@ namespace policy {
@@ -1139,6 +1143,7 @@ namespace policy {
'#else\n'
'const wchar_t kRegistryChromePolicyKey[] = '
'L"' + CHROMIUM_POLICY_KEY + '";\n'

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 ea046f5f1dfe3..0a915b7e3a091 100644
index e3a6645add6e3..4dde23d0451ff 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;

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 2e67f8c97fab8..a3367979977c9 100644
index 52da35f06a7a9..5fb43c7c65d34 100644
--- chrome/browser/profiles/off_the_record_profile_impl.cc
+++ chrome/browser/profiles/off_the_record_profile_impl.cc
@@ -666,7 +666,9 @@ std::unique_ptr<Profile> Profile::CreateOffTheRecordProfile(
@@ -669,7 +669,9 @@ std::unique_ptr<Profile> Profile::CreateOffTheRecordProfile(
#endif
if (!profile)
profile = std::make_unique<OffTheRecordProfileImpl>(parent, otr_profile_id);
@ -52,10 +52,10 @@ 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 b06035ad4748f..5d51cd1038a66 100644
index 7ad5372c8a135..1112491861262 100644
--- chrome/browser/profiles/profile.h
+++ chrome/browser/profiles/profile.h
@@ -93,6 +93,10 @@ class Profile : public content::BrowserContext {
@@ -94,6 +94,10 @@ class Profile : public content::BrowserContext {
// be applicable to run. Please see crbug.com/1098697#c3 for more details.
static OTRProfileID CreateUnique(const std::string& profile_id_prefix);
@ -66,7 +66,7 @@ index b06035ad4748f..5d51cd1038a66 100644
// Creates a unique OTR profile id to be used for DevTools browser contexts.
static OTRProfileID CreateUniqueForDevTools();
@@ -504,6 +508,8 @@ class Profile : public content::BrowserContext {
@@ -515,6 +519,8 @@ class Profile : public content::BrowserContext {
return instant_service_;
}
@ -75,7 +75,7 @@ index b06035ad4748f..5d51cd1038a66 100644
protected:
// Creates an OffTheRecordProfile which points to this Profile.
static std::unique_ptr<Profile> CreateOffTheRecordProfile(
@@ -515,7 +521,6 @@ class Profile : public content::BrowserContext {
@@ -526,7 +532,6 @@ class Profile : public content::BrowserContext {
static PrefStore* CreateExtensionPrefStore(Profile*,
bool incognito_pref_store);
@ -84,7 +84,7 @@ index b06035ad4748f..5d51cd1038a66 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 47ada6bf53225..a0c4d18b93278 100644
index fbe18f0773bda..1066b8d2b382a 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,
@ -99,10 +99,10 @@ index 47ada6bf53225..a0c4d18b93278 100644
return raw_otr_profile;
}
diff --git chrome/browser/profiles/profile_manager.cc chrome/browser/profiles/profile_manager.cc
index a8ae9d577d4fb..381d6ceeaccba 100644
index 6e991d99df8ff..00145aba0bd83 100644
--- chrome/browser/profiles/profile_manager.cc
+++ chrome/browser/profiles/profile_manager.cc
@@ -437,7 +437,7 @@ ProfileManager::ProfileManager(const base::FilePath& user_data_dir)
@@ -436,7 +436,7 @@ ProfileManager::ProfileManager(const base::FilePath& user_data_dir)
profile_manager_android_ = std::make_unique<ProfileManagerAndroid>(this);
#endif
@ -156,7 +156,7 @@ index 0d1d2e3661ff1..ba4b8cb233102 100644
#endif
{
diff --git chrome/browser/profiles/renderer_updater_factory.cc chrome/browser/profiles/renderer_updater_factory.cc
index ed5b366aa47ab..794cf8b3bbec1 100644
index a836288d08abc..26219d19f0973 100644
--- chrome/browser/profiles/renderer_updater_factory.cc
+++ chrome/browser/profiles/renderer_updater_factory.cc
@@ -4,6 +4,7 @@

View File

@ -1,10 +1,10 @@
diff --git chrome/browser/safe_browsing/BUILD.gn chrome/browser/safe_browsing/BUILD.gn
index 9bb9b155d3024..34f1bfcffd7d8 100644
index 102625231e535..47d0d7574b2ee 100644
--- chrome/browser/safe_browsing/BUILD.gn
+++ chrome/browser/safe_browsing/BUILD.gn
@@ -32,6 +32,7 @@ static_library("safe_browsing") {
"//components/browser_sync",
@@ -33,6 +33,7 @@ static_library("safe_browsing") {
"//components/enterprise:enterprise",
"//components/enterprise/buildflags",
"//components/enterprise/common:strings",
+ "//components/gcm_driver:gcm_buildflags",
"//components/keyed_service/content",

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 f5fdf2a05a7e7..4622df9f7b0cb 100644
index 86ab9563e08bc..182be3b6ec1dc 100644
--- chrome/browser/ui/startup/startup_browser_creator.cc
+++ chrome/browser/ui/startup/startup_browser_creator.cc
@@ -603,6 +603,13 @@ std::optional<ash::KioskAppId> GetAppId(const base::CommandLine& command_line,
@@ -604,6 +604,13 @@ std::optional<ash::KioskAppId> GetAppId(const base::CommandLine& command_line,
}
#endif // BUILDFLAG(IS_CHROMEOS_ASH)
@ -16,7 +16,7 @@ index f5fdf2a05a7e7..4622df9f7b0cb 100644
} // namespace
StartupProfileMode StartupProfileModeFromReason(
@@ -1487,6 +1494,12 @@ void StartupBrowserCreator::ProcessCommandLineWithProfile(
@@ -1488,6 +1495,12 @@ void StartupBrowserCreator::ProcessCommandLineWithProfile(
{profile, mode}, last_opened_profiles);
}
@ -29,7 +29,7 @@ index f5fdf2a05a7e7..4622df9f7b0cb 100644
// static
void StartupBrowserCreator::ProcessCommandLineAlreadyRunning(
const base::CommandLine& command_line,
@@ -1496,6 +1509,11 @@ void StartupBrowserCreator::ProcessCommandLineAlreadyRunning(
@@ -1497,6 +1510,11 @@ void StartupBrowserCreator::ProcessCommandLineAlreadyRunning(
return;
}
@ -42,7 +42,7 @@ index f5fdf2a05a7e7..4622df9f7b0cb 100644
StartupProfileMode mode =
StartupProfileModeFromReason(profile_path_info.reason);
diff --git chrome/browser/ui/startup/startup_browser_creator.h chrome/browser/ui/startup/startup_browser_creator.h
index fc41cf3c88d9b..e0e51cb9e2dec 100644
index 11a33a0bdec02..5a8146c95f99d 100644
--- chrome/browser/ui/startup/startup_browser_creator.h
+++ chrome/browser/ui/startup/startup_browser_creator.h
@@ -9,6 +9,7 @@

View File

@ -1,5 +1,5 @@
diff --git chrome/browser/themes/theme_service.cc chrome/browser/themes/theme_service.cc
index 0b39e73c2a394..1c42fe06479ab 100644
index dd41ca3cb8f35..6123e27acffa8 100644
--- chrome/browser/themes/theme_service.cc
+++ chrome/browser/themes/theme_service.cc
@@ -30,6 +30,7 @@
@ -7,10 +7,10 @@ index 0b39e73c2a394..1c42fe06479ab 100644
#include "base/trace_event/trace_event.h"
#include "build/build_config.h"
+#include "cef/libcef/features/runtime.h"
#include "chrome/browser/browser_features.h"
#include "chrome/browser/extensions/extension_service.h"
#include "chrome/browser/extensions/theme_installed_infobar_delegate.h"
@@ -69,6 +70,10 @@
#include "chrome/browser/new_tab_page/chrome_colors/chrome_colors_service.h"
@@ -68,6 +69,10 @@
#include "ui/color/color_provider_manager.h"
#include "ui/native_theme/native_theme.h"
@ -21,7 +21,7 @@ index 0b39e73c2a394..1c42fe06479ab 100644
#if BUILDFLAG(ENABLE_EXTENSIONS)
#include "base/scoped_observation.h"
#include "extensions/browser/extension_registry_observer.h"
@@ -270,11 +275,19 @@ void ThemeService::Init() {
@@ -269,11 +274,19 @@ void ThemeService::Init() {
// OnExtensionServiceReady. Otherwise, the ThemeObserver won't be
// constructed in time to observe the corresponding events.
#if BUILDFLAG(ENABLE_EXTENSIONS)
@ -42,7 +42,7 @@ index 0b39e73c2a394..1c42fe06479ab 100644
theme_syncable_service_ =
std::make_unique<ThemeSyncableService>(profile_, this);
diff --git chrome/browser/themes/theme_service_factory.cc chrome/browser/themes/theme_service_factory.cc
index 879bbeef4037b..c52b9144cf966 100644
index 49fd0b0f7a21c..dc4258f7143d1 100644
--- chrome/browser/themes/theme_service_factory.cc
+++ chrome/browser/themes/theme_service_factory.cc
@@ -9,6 +9,7 @@

View File

@ -1,5 +1,5 @@
diff --git chrome/common/features.gni chrome/common/features.gni
index 01367ff6efd6c..975ea8e446dce 100644
index fc2d817cdab5d..bb0fe5b982aae 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 01367ff6efd6c..975ea8e446dce 100644
# Platforms where Chrome x509 server certificate enterprise policies are
# supported. This must must match the supported_on/future_on list of the
@@ -90,11 +91,13 @@ declare_args() {
@@ -94,11 +95,13 @@ declare_args() {
# optimize_webui was moved to ui/base/ui_features.gni
}

View File

@ -1,5 +1,5 @@
diff --git chrome/browser/plugins/plugin_info_host_impl.cc chrome/browser/plugins/plugin_info_host_impl.cc
index 2bb525046619c..200fc9c1f0067 100644
index 0ca794a57bed3..ce171b7a01a8c 100644
--- chrome/browser/plugins/plugin_info_host_impl.cc
+++ chrome/browser/plugins/plugin_info_host_impl.cc
@@ -16,6 +16,7 @@
@ -24,7 +24,7 @@ index 2bb525046619c..200fc9c1f0067 100644
extensions::WebViewRendererState::GetInstance();
std::string partition_id;
diff --git chrome/browser/plugins/plugin_utils.cc chrome/browser/plugins/plugin_utils.cc
index 438276b719c2f..e97fa0eaf2d7a 100644
index 00dd9a34cd3fb..89d4588bdbe4e 100644
--- chrome/browser/plugins/plugin_utils.cc
+++ chrome/browser/plugins/plugin_utils.cc
@@ -5,6 +5,7 @@
@ -34,8 +34,8 @@ index 438276b719c2f..e97fa0eaf2d7a 100644
+#include "cef/libcef/features/features.h"
#include "chrome/browser/profiles/profile.h"
#include "components/content_settings/core/browser/host_content_settings_map.h"
#include "components/content_settings/core/common/content_settings_types.h"
@@ -68,6 +69,15 @@ PluginUtils::GetMimeTypeToExtensionIdMap(
#include "components/content_settings/core/common/content_settings.h"
@@ -69,6 +70,15 @@ PluginUtils::GetMimeTypeToExtensionIdMap(
content::BrowserContext* browser_context) {
base::flat_map<std::string, std::string> mime_type_to_extension_id_map;
#if BUILDFLAG(ENABLE_EXTENSIONS)
@ -51,7 +51,7 @@ index 438276b719c2f..e97fa0eaf2d7a 100644
Profile* profile = Profile::FromBrowserContext(browser_context);
if (extensions::ChromeContentBrowserClientExtensionsPart::
AreExtensionsDisabledForProfile(profile)) {
@@ -78,9 +88,11 @@ PluginUtils::GetMimeTypeToExtensionIdMap(
@@ -79,9 +89,11 @@ PluginUtils::GetMimeTypeToExtensionIdMap(
MimeTypesHandler::GetMIMETypeAllowlist();
// Go through the allowed extensions and try to use them to intercept
// the URL request.
@ -64,10 +64,10 @@ index 438276b719c2f..e97fa0eaf2d7a 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 620f0ebad27d3..f36f4a6c5d1ee 100644
index 60bc3751cb325..ebce071c74a8b 100644
--- chrome/renderer/chrome_content_renderer_client.cc
+++ chrome/renderer/chrome_content_renderer_client.cc
@@ -1007,6 +1007,7 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
@@ -1006,6 +1006,7 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
if ((status == chrome::mojom::PluginStatus::kUnauthorized ||
status == chrome::mojom::PluginStatus::kBlocked) &&
@ -75,7 +75,7 @@ index 620f0ebad27d3..f36f4a6c5d1ee 100644
content_settings_agent_delegate->IsPluginTemporarilyAllowed(
identifier)) {
status = chrome::mojom::PluginStatus::kAllowed;
@@ -1167,7 +1168,8 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
@@ -1166,7 +1167,8 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
render_frame->GetRemoteAssociatedInterfaces()->GetInterface(
plugin_auth_host.BindNewEndpointAndPassReceiver());
plugin_auth_host->BlockedUnauthorizedPlugin(group_name, identifier);
@ -85,7 +85,7 @@ index 620f0ebad27d3..f36f4a6c5d1ee 100644
break;
}
case chrome::mojom::PluginStatus::kBlocked: {
@@ -1176,7 +1178,8 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
@@ -1175,7 +1177,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 620f0ebad27d3..f36f4a6c5d1ee 100644
break;
}
case chrome::mojom::PluginStatus::kBlockedByPolicy: {
@@ -1186,7 +1189,8 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
@@ -1185,7 +1188,8 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
group_name));
RenderThread::Get()->RecordAction(
UserMetricsAction("Plugin_BlockedByPolicy"));
@ -127,7 +127,7 @@ index 8b26a93f7527e..17890bf20e481 100644
BrowserPluginEmbedder(const BrowserPluginEmbedder&) = delete;
BrowserPluginEmbedder& operator=(const BrowserPluginEmbedder&) = delete;
diff --git content/browser/browser_plugin/browser_plugin_guest.cc content/browser/browser_plugin/browser_plugin_guest.cc
index f94fcfcf562db..066c66f46b7ae 100644
index 1ce20a2a42705..7a3ef88ec689b 100644
--- content/browser/browser_plugin/browser_plugin_guest.cc
+++ content/browser/browser_plugin/browser_plugin_guest.cc
@@ -49,6 +49,8 @@ std::unique_ptr<WebContentsImpl> BrowserPluginGuest::CreateNewGuestWindow(

View File

@ -1,8 +1,8 @@
diff --git chrome/browser/ui/prefs/pref_watcher.h chrome/browser/ui/prefs/pref_watcher.h
index c442c6f50eada..e8a42a9d4948d 100644
index 79ce1590df640..6b57feb48aad6 100644
--- chrome/browser/ui/prefs/pref_watcher.h
+++ chrome/browser/ui/prefs/pref_watcher.h
@@ -33,10 +33,10 @@ class PrefWatcher : public KeyedService,
@@ -36,10 +36,10 @@ class PrefWatcher : public KeyedService,
void RegisterRendererPreferenceWatcher(
mojo::PendingRemote<blink::mojom::RendererPreferenceWatcher> watcher);
@ -11,6 +11,6 @@ index c442c6f50eada..e8a42a9d4948d 100644
void Shutdown() override;
+ private:
void OnDoNotTrackEnabledChanged() override;
// ui::NativeThemeObserver:
void OnNativeThemeUpdated(ui::NativeTheme* observed_theme) override;
void UpdateRendererPreferences();

View File

@ -1,5 +1,5 @@
diff --git chrome/renderer/BUILD.gn chrome/renderer/BUILD.gn
index b17c8a5f9f9c3..cfa44b65d066a 100644
index 857247dd93f75..fc2f196d450cd 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 c09a805c4ed7b..3db1403d60ed5 100644
index d60a195d58a27..df74bb2c60264 100644
--- chrome/app/chrome_main_delegate.cc
+++ chrome/app/chrome_main_delegate.cc
@@ -37,6 +37,7 @@
@ -20,7 +20,7 @@ index c09a805c4ed7b..3db1403d60ed5 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
@@ -854,6 +858,10 @@ ChromeMainDelegate::~ChromeMainDelegate() {
@@ -845,6 +849,10 @@ ChromeMainDelegate::~ChromeMainDelegate() {
ChromeMainDelegate::~ChromeMainDelegate() = default;
#endif // !BUILDFLAG(IS_ANDROID)
@ -31,7 +31,7 @@ index c09a805c4ed7b..3db1403d60ed5 100644
std::optional<int> ChromeMainDelegate::PostEarlyInitialization(
InvokedIn invoked_in) {
DUMP_WILL_BE_CHECK(base::ThreadPoolInstance::Get());
@@ -879,7 +887,7 @@ std::optional<int> ChromeMainDelegate::PostEarlyInitialization(
@@ -870,7 +878,7 @@ std::optional<int> ChromeMainDelegate::PostEarlyInitialization(
// future session's metrics.
DeferBrowserMetrics(user_data_dir);
@ -40,7 +40,7 @@ index c09a805c4ed7b..3db1403d60ed5 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.
@@ -1050,7 +1058,8 @@ std::optional<int> ChromeMainDelegate::PostEarlyInitialization(
@@ -1038,7 +1046,8 @@ std::optional<int> ChromeMainDelegate::PostEarlyInitialization(
// Initializes the resource bundle and determines the locale.
std::string actual_locale = LoadLocalState(
@ -50,7 +50,7 @@ index c09a805c4ed7b..3db1403d60ed5 100644
chrome_feature_list_creator->SetApplicationLocale(actual_locale);
chrome_feature_list_creator->OverrideCachedUIStrings();
@@ -1069,7 +1078,8 @@ std::optional<int> ChromeMainDelegate::PostEarlyInitialization(
@@ -1057,7 +1066,8 @@ std::optional<int> ChromeMainDelegate::PostEarlyInitialization(
if (base::FeatureList::IsEnabled(
features::kWriteBasicSystemProfileToPersistentHistogramsFile)) {
@ -60,15 +60,15 @@ index c09a805c4ed7b..3db1403d60ed5 100644
#if BUILDFLAG(IS_ANDROID)
record =
base::FeatureList::IsEnabled(chrome::android::kUmaBackgroundSessions);
@@ -1505,6 +1515,7 @@ void ChromeMainDelegate::PreSandboxStartup() {
@@ -1502,6 +1512,7 @@ void ChromeMainDelegate::PreSandboxStartup() {
std::string process_type =
command_line.GetSwitchValueASCII(switches::kProcessType);
+ if (!cef::IsChromeRuntimeEnabled()) {
crash_reporter::InitializeCrashKeys();
#if BUILDFLAG(IS_CHROMEOS_LACROS)
@@ -1523,6 +1534,7 @@ void ChromeMainDelegate::PreSandboxStartup() {
#if BUILDFLAG(IS_POSIX)
@@ -1512,6 +1523,7 @@ void ChromeMainDelegate::PreSandboxStartup() {
InitMacCrashReporter(command_line, process_type);
SetUpInstallerPreferences(command_line);
#endif
@ -76,7 +76,7 @@ index c09a805c4ed7b..3db1403d60ed5 100644
#if BUILDFLAG(IS_WIN)
child_process_logging::Init();
@@ -1703,7 +1715,8 @@ void ChromeMainDelegate::PreSandboxStartup() {
@@ -1692,7 +1704,8 @@ void ChromeMainDelegate::PreSandboxStartup() {
#else
const std::string loaded_locale =
ui::ResourceBundle::InitSharedInstanceWithLocale(
@ -86,7 +86,7 @@ index c09a805c4ed7b..3db1403d60ed5 100644
base::FilePath resources_pack_path;
base::PathService::Get(chrome::FILE_RESOURCES_PACK, &resources_pack_path);
@@ -1733,6 +1746,7 @@ void ChromeMainDelegate::PreSandboxStartup() {
@@ -1722,6 +1735,7 @@ void ChromeMainDelegate::PreSandboxStartup() {
CHECK(!loaded_locale.empty()) << "Locale could not be found for " << locale;
}
@ -94,7 +94,7 @@ index c09a805c4ed7b..3db1403d60ed5 100644
#if BUILDFLAG(IS_POSIX) && !BUILDFLAG(IS_MAC)
// Zygote needs to call InitCrashReporter() in RunZygote().
if (process_type != switches::kZygoteProcess) {
@@ -1768,6 +1782,7 @@ void ChromeMainDelegate::PreSandboxStartup() {
@@ -1757,6 +1771,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 c09a805c4ed7b..3db1403d60ed5 100644
#if BUILDFLAG(ENABLE_PDF)
MaybePatchGdiGetFontData();
@@ -1893,6 +1908,7 @@ void ChromeMainDelegate::ZygoteForked() {
@@ -1880,6 +1895,7 @@ void ChromeMainDelegate::ZygoteForked() {
SetUpProfilingShutdownHandler();
}
@ -110,7 +110,7 @@ index c09a805c4ed7b..3db1403d60ed5 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 =
@@ -1905,6 +1921,7 @@ void ChromeMainDelegate::ZygoteForked() {
@@ -1892,6 +1908,7 @@ void ChromeMainDelegate::ZygoteForked() {
// Reset the command line for the newly spawned process.
crash_keys::SetCrashKeysFromCommandLine(*command_line);
@ -118,18 +118,18 @@ index c09a805c4ed7b..3db1403d60ed5 100644
}
#endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)
@@ -2001,6 +2018,7 @@ void ChromeMainDelegate::InitializeMemorySystem() {
const bool is_browser_process = process_type.empty();
const bool gwp_asan_boost_sampling = is_browser_process || IsCanaryDev();
@@ -1994,6 +2011,7 @@ void ChromeMainDelegate::InitializeMemorySystem() {
: memory_system::DispatcherParameters::
AllocationTraceRecorderInclusion::kIgnore;
+ memory_system_ = std::make_unique<memory_system::MemorySystem>();
memory_system::Initializer()
.SetGwpAsanParameters(gwp_asan_boost_sampling, process_type)
.SetProfilingClientParameters(chrome::GetChannel(),
@@ -2010,5 +2028,5 @@ void ChromeMainDelegate::InitializeMemorySystem() {
memory_system::DispatcherParameters::
AllocationTraceRecorderInclusion::kDynamic,
process_type)
@@ -2001,5 +2019,5 @@ void ChromeMainDelegate::InitializeMemorySystem() {
.SetDispatcherParameters(memory_system::DispatcherParameters::
PoissonAllocationSamplerInclusion::kEnforce,
allocation_recorder_inclusion, process_type)
- .Initialize(memory_system_);
+ .Initialize(*memory_system_);
}
@ -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 ed96ab7401650..625fd36e74d64 100644
index d6c9d21a0d4d3..9e0673a150d40 100644
--- chrome/browser/chrome_browser_main.cc
+++ chrome/browser/chrome_browser_main.cc
@@ -52,6 +52,7 @@
@ -185,7 +185,7 @@ index ed96ab7401650..625fd36e74d64 100644
#include "chrome/browser/about_flags.h"
#include "chrome/browser/active_use_util.h"
#include "chrome/browser/after_startup_task_utils.h"
@@ -513,7 +514,7 @@ void ProcessSingletonNotificationCallbackImpl(
@@ -529,7 +530,7 @@ void ProcessSingletonNotificationCallbackImpl(
return;
}
@ -194,7 +194,7 @@ index ed96ab7401650..625fd36e74d64 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
@@ -816,7 +817,7 @@ int ChromeBrowserMainParts::PreEarlyInitialization() {
@@ -832,7 +833,7 @@ int ChromeBrowserMainParts::PreEarlyInitialization() {
return content::RESULT_CODE_NORMAL_EXIT;
}
@ -203,7 +203,7 @@ index ed96ab7401650..625fd36e74d64 100644
// If we are running stale binaries then relaunch and exit immediately.
if (upgrade_util::IsRunningOldChrome()) {
if (!upgrade_util::RelaunchChromeBrowser(
@@ -829,7 +830,7 @@ int ChromeBrowserMainParts::PreEarlyInitialization() {
@@ -845,7 +846,7 @@ int ChromeBrowserMainParts::PreEarlyInitialization() {
// result in browser startup bailing.
return chrome::RESULT_CODE_NORMAL_EXIT_UPGRADE_RELAUNCHED;
}
@ -212,7 +212,7 @@ index ed96ab7401650..625fd36e74d64 100644
return load_local_state_result;
}
@@ -935,7 +936,7 @@ int ChromeBrowserMainParts::OnLocalStateLoaded(
@@ -951,7 +952,7 @@ int ChromeBrowserMainParts::OnLocalStateLoaded(
browser_process_->local_state());
platform_management_service->RefreshCache(base::NullCallback());
@ -221,7 +221,7 @@ index ed96ab7401650..625fd36e74d64 100644
if (first_run::IsChromeFirstRun()) {
bool stats_default;
if (GoogleUpdateSettings::GetCollectStatsConsentDefault(&stats_default)) {
@@ -948,7 +949,7 @@ int ChromeBrowserMainParts::OnLocalStateLoaded(
@@ -964,7 +965,7 @@ int ChromeBrowserMainParts::OnLocalStateLoaded(
: metrics::EnableMetricsDefault::OPT_IN);
}
}
@ -230,7 +230,7 @@ index ed96ab7401650..625fd36e74d64 100644
std::string locale =
startup_data_->chrome_feature_list_creator()->actual_locale();
@@ -981,6 +982,7 @@ int ChromeBrowserMainParts::ApplyFirstRunPrefs() {
@@ -997,6 +998,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 ed96ab7401650..625fd36e74d64 100644
std::unique_ptr<installer::InitialPreferences> installer_initial_prefs =
startup_data_->chrome_feature_list_creator()->TakeInitialPrefs();
if (!installer_initial_prefs)
@@ -1014,6 +1016,7 @@ int ChromeBrowserMainParts::ApplyFirstRunPrefs() {
@@ -1030,6 +1032,7 @@ int ChromeBrowserMainParts::ApplyFirstRunPrefs() {
master_prefs_->confirm_to_quit);
}
#endif // BUILDFLAG(IS_MAC)
@ -246,7 +246,7 @@ index ed96ab7401650..625fd36e74d64 100644
#endif // !BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_CHROMEOS_ASH)
return content::RESULT_CODE_NORMAL_EXIT;
}
@@ -1080,6 +1083,7 @@ int ChromeBrowserMainParts::PreCreateThreadsImpl() {
@@ -1091,6 +1094,7 @@ int ChromeBrowserMainParts::PreCreateThreadsImpl() {
browser_process_->browser_policy_connector()->OnResourceBundleCreated();
@ -254,7 +254,7 @@ index ed96ab7401650..625fd36e74d64 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)
@@ -1101,6 +1105,7 @@ int ChromeBrowserMainParts::PreCreateThreadsImpl() {
@@ -1112,6 +1116,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 ed96ab7401650..625fd36e74d64 100644
#if BUILDFLAG(IS_MAC)
#if defined(ARCH_CPU_X86_64)
@@ -1459,6 +1464,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
@@ -1470,6 +1475,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
browser_process_->PreMainMessageLoopRun();
#if BUILDFLAG(IS_WIN)
@ -270,7 +270,7 @@ index ed96ab7401650..625fd36e74d64 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)) {
@@ -1470,6 +1476,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
@@ -1481,6 +1487,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
return ChromeBrowserMainPartsWin::HandleIconsCommands(
*base::CommandLine::ForCurrentProcess());
}
@ -278,7 +278,7 @@ index ed96ab7401650..625fd36e74d64 100644
ui::SelectFileDialog::SetFactory(
std::make_unique<ChromeSelectFileDialogFactory>());
@@ -1495,6 +1502,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
@@ -1506,6 +1513,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
}
#endif // BUILDFLAG(CHROME_FOR_TESTING)
@ -286,7 +286,7 @@ index ed96ab7401650..625fd36e74d64 100644
if (base::CommandLine::ForCurrentProcess()->HasSwitch(
switches::kMakeDefaultBrowser)) {
bool is_managed = g_browser_process->local_state()->IsManagedPreference(
@@ -1508,18 +1516,22 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
@@ -1519,18 +1527,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 ed96ab7401650..625fd36e74d64 100644
#if !BUILDFLAG(IS_ANDROID) && BUILDFLAG(ENABLE_DOWNGRADE_PROCESSING)
// Begin relaunch processing immediately if User Data migration is required
@@ -1558,7 +1570,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
@@ -1569,7 +1581,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
}
#endif // !BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_CHROMEOS)
@ -318,7 +318,7 @@ index ed96ab7401650..625fd36e74d64 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
@@ -1567,7 +1579,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
@@ -1578,7 +1590,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 ed96ab7401650..625fd36e74d64 100644
// Desktop construction occurs here, (required before profile creation).
PreProfileInit();
@@ -1610,12 +1622,14 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
@@ -1621,12 +1633,14 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
browser_process_->local_state());
}
@ -342,7 +342,7 @@ index ed96ab7401650..625fd36e74d64 100644
#if BUILDFLAG(IS_ANDROID)
page_info::SetPageInfoClient(new ChromePageInfoClient());
@@ -1642,6 +1656,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
@@ -1653,6 +1667,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 ed96ab7401650..625fd36e74d64 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
@@ -1681,6 +1696,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
@@ -1692,6 +1707,7 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
*base::CommandLine::ForCurrentProcess());
}
#endif // BUILDFLAG(IS_WIN)
@ -358,7 +358,7 @@ index ed96ab7401650..625fd36e74d64 100644
// Configure modules that need access to resources.
net::NetModule::SetResourceProvider(ChromeNetResourceProvider);
@@ -1766,6 +1782,11 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
@@ -1783,6 +1799,11 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
g_browser_process->profile_manager()->GetLastOpenedProfiles();
}
#endif // BUILDFLAG(IS_CHROMEOS_ASH)
@ -370,7 +370,7 @@ index ed96ab7401650..625fd36e74d64 100644
// This step is costly.
if (browser_creator_->Start(*base::CommandLine::ForCurrentProcess(),
base::FilePath(), profile_info,
@@ -1798,11 +1819,14 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
@@ -1815,11 +1836,14 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
// Create the RunLoop for MainMessageLoopRun() to use and transfer
// ownership of the browser's lifetime to the BrowserProcess.
@ -386,7 +386,7 @@ index ed96ab7401650..625fd36e74d64 100644
#endif // !BUILDFLAG(IS_ANDROID)
diff --git chrome/browser/chrome_browser_main_mac.mm chrome/browser/chrome_browser_main_mac.mm
index 6568351d73ae9..f4a4bd3194c02 100644
index 3c12614c4d7d2..1dc97ecf5a11e 100644
--- chrome/browser/chrome_browser_main_mac.mm
+++ chrome/browser/chrome_browser_main_mac.mm
@@ -18,6 +18,7 @@
@ -397,7 +397,7 @@ index 6568351d73ae9..f4a4bd3194c02 100644
#import "chrome/browser/app_controller_mac.h"
#include "chrome/browser/apps/app_shim/app_shim_listener.h"
#include "chrome/browser/browser_process.h"
@@ -107,6 +108,7 @@ void ChromeBrowserMainPartsMac::PreCreateMainMessageLoop() {
@@ -106,6 +107,7 @@ void ChromeBrowserMainPartsMac::PreCreateMainMessageLoop() {
}
#endif // !BUILDFLAG(CHROME_FOR_TESTING)
@ -405,7 +405,7 @@ index 6568351d73ae9..f4a4bd3194c02 100644
// Create the app delegate by requesting the shared AppController.
CHECK_EQ(nil, NSApp.delegate);
AppController* app_controller = AppController.sharedController;
@@ -115,6 +117,7 @@ void ChromeBrowserMainPartsMac::PreCreateMainMessageLoop() {
@@ -114,6 +116,7 @@ void ChromeBrowserMainPartsMac::PreCreateMainMessageLoop() {
chrome::BuildMainMenu(NSApp, app_controller,
l10n_util::GetStringUTF16(IDS_PRODUCT_NAME), false);
[app_controller mainMenuCreated];
@ -413,7 +413,7 @@ index 6568351d73ae9..f4a4bd3194c02 100644
ui::WarmScreenCapture();
@@ -155,5 +158,7 @@ void ChromeBrowserMainPartsMac::PostProfileInit(Profile* profile,
@@ -154,5 +157,7 @@ void ChromeBrowserMainPartsMac::PostProfileInit(Profile* profile,
}
void ChromeBrowserMainPartsMac::DidEndMainMessageLoop() {
@ -422,10 +422,10 @@ index 6568351d73ae9..f4a4bd3194c02 100644
+#endif
}
diff --git chrome/browser/chrome_content_browser_client.cc chrome/browser/chrome_content_browser_client.cc
index b07f8f583dabb..94b2acd6ef46e 100644
index 675a9ab64ea08..d0c160a14b2a7 100644
--- chrome/browser/chrome_content_browser_client.cc
+++ chrome/browser/chrome_content_browser_client.cc
@@ -47,6 +47,7 @@
@@ -46,6 +46,7 @@
#include "build/build_config.h"
#include "build/chromeos_buildflags.h"
#include "build/config/chromebox_for_meetings/buildflags.h" // PLATFORM_CFM
@ -433,7 +433,7 @@ index b07f8f583dabb..94b2acd6ef46e 100644
#include "chrome/browser/after_startup_task_utils.h"
#include "chrome/browser/app_mode/app_mode_utils.h"
#include "chrome/browser/bluetooth/chrome_bluetooth_delegate_impl_client.h"
@@ -1462,6 +1463,8 @@ ChromeContentBrowserClient::GetPopupNavigationDelegateFactoryForTesting() {
@@ -1467,6 +1468,8 @@ ChromeContentBrowserClient::GetPopupNavigationDelegateFactoryForTesting() {
}
ChromeContentBrowserClient::ChromeContentBrowserClient() {
@ -442,7 +442,7 @@ index b07f8f583dabb..94b2acd6ef46e 100644
#if BUILDFLAG(ENABLE_PLUGINS)
extra_parts_.push_back(
std::make_unique<ChromeContentBrowserClientPluginsPart>());
@@ -1499,6 +1502,11 @@ ChromeContentBrowserClient::~ChromeContentBrowserClient() {
@@ -1504,6 +1507,11 @@ ChromeContentBrowserClient::~ChromeContentBrowserClient() {
}
}
@ -454,10 +454,22 @@ index b07f8f583dabb..94b2acd6ef46e 100644
// static
void ChromeContentBrowserClient::RegisterLocalStatePrefs(
PrefRegistrySimple* registry) {
@@ -3697,9 +3705,24 @@ bool UpdatePreferredColorScheme(WebPreferences* web_prefs,
@@ -3707,28 +3715,25 @@ bool UpdatePreferredColorScheme(WebPreferences* web_prefs,
web_prefs->preferred_color_scheme;
}
#else
- // Update based on native theme scheme.
- web_prefs->preferred_color_scheme =
- ToBlinkPreferredColorScheme(native_theme->GetPreferredColorScheme());
-
- bool using_different_colored_frame = false;
- if (Profile* profile =
- Profile::FromBrowserContext(web_contents->GetBrowserContext())) {
- if (ThemeService* theme_service =
- ThemeServiceFactory::GetForProfile(profile)) {
- using_different_colored_frame = !theme_service->UsingDefaultTheme() ||
- theme_service->GetUserColor().has_value();
- }
+ auto preferred_color_scheme = native_theme->GetPreferredColorScheme();
+
+ auto* profile = Profile::FromBrowserContext(
@ -471,16 +483,24 @@ index b07f8f583dabb..94b2acd6ef46e 100644
+ browser_color_scheme == ThemeService::BrowserColorScheme::kLight
+ ? ui::NativeTheme::PreferredColorScheme::kLight
+ : ui::NativeTheme::PreferredColorScheme::kDark;
+ }
+
// Update based on native theme scheme.
web_prefs->preferred_color_scheme =
- ToBlinkPreferredColorScheme(native_theme->GetPreferredColorScheme());
+ ToBlinkPreferredColorScheme(preferred_color_scheme);
}
// Update based on the ColorProvider associated with `web_contents`. Depends
// on the browser color mode settings.
@@ -4454,9 +4477,11 @@ void ChromeContentBrowserClient::BrowserURLHandlerCreated(
- // Update based on the ColorProvider associated with `web_contents`. Depends
- // on the browser color mode settings and whether the user profile has set a
- // custom coloring for the browser ui.
- web_prefs->preferred_root_scrollbar_color_scheme =
- web_contents->GetColorMode() == ui::ColorProviderKey::ColorMode::kLight ||
- using_different_colored_frame
- ? blink::mojom::PreferredColorScheme::kLight
- : blink::mojom::PreferredColorScheme::kDark;
+ // Update based on native theme scheme.
+ web_prefs->preferred_color_scheme =
+ web_prefs->preferred_root_scrollbar_color_scheme =
+ ToBlinkPreferredColorScheme(preferred_color_scheme);
#endif // BUILDFLAG(IS_ANDROID)
// Reauth WebUI doesn't support dark mode yet because it shares the dialog
@@ -4471,9 +4476,11 @@ void ChromeContentBrowserClient::BrowserURLHandlerCreated(
&search::HandleNewTabURLReverseRewrite);
#endif // BUILDFLAG(IS_ANDROID)
@ -492,7 +512,7 @@ index b07f8f583dabb..94b2acd6ef46e 100644
}
base::FilePath ChromeContentBrowserClient::GetDefaultDownloadDirectory() {
@@ -6565,7 +6590,7 @@ void ChromeContentBrowserClient::OnNetworkServiceCreated(
@@ -6592,7 +6599,7 @@ void ChromeContentBrowserClient::OnNetworkServiceCreated(
#endif
}
@ -501,7 +521,7 @@ index b07f8f583dabb..94b2acd6ef46e 100644
content::BrowserContext* context,
bool in_memory,
const base::FilePath& relative_partition_path,
@@ -6583,6 +6608,8 @@ void ChromeContentBrowserClient::ConfigureNetworkContextParams(
@@ -6610,6 +6617,8 @@ void ChromeContentBrowserClient::ConfigureNetworkContextParams(
network_context_params->user_agent = GetUserAgentBasedOnPolicy(context);
network_context_params->accept_language = GetApplicationLocale();
}
@ -510,7 +530,7 @@ index b07f8f583dabb..94b2acd6ef46e 100644
}
std::vector<base::FilePath>
@@ -7698,10 +7725,10 @@ void ChromeContentBrowserClient::OnKeepaliveRequestStarted(
@@ -7732,10 +7741,10 @@ void ChromeContentBrowserClient::OnKeepaliveRequestStarted(
const auto now = base::TimeTicks::Now();
const auto timeout = GetKeepaliveTimerTimeout(context);
keepalive_deadline_ = std::max(keepalive_deadline_, now + timeout);
@ -523,7 +543,7 @@ index b07f8f583dabb..94b2acd6ef46e 100644
FROM_HERE, keepalive_deadline_ - now,
base::BindOnce(
&ChromeContentBrowserClient::OnKeepaliveTimerFired,
@@ -7720,7 +7747,8 @@ void ChromeContentBrowserClient::OnKeepaliveRequestFinished() {
@@ -7754,7 +7763,8 @@ void ChromeContentBrowserClient::OnKeepaliveRequestFinished() {
--num_keepalive_requests_;
if (num_keepalive_requests_ == 0) {
DVLOG(1) << "Stopping the keepalive timer";
@ -533,7 +553,7 @@ index b07f8f583dabb..94b2acd6ef46e 100644
// This deletes the keep alive handle attached to the timer function and
// unblock the shutdown sequence.
}
@@ -7888,7 +7916,7 @@ void ChromeContentBrowserClient::OnKeepaliveTimerFired(
@@ -7923,7 +7933,7 @@ void ChromeContentBrowserClient::OnKeepaliveTimerFired(
const auto now = base::TimeTicks::Now();
const auto then = keepalive_deadline_;
if (now < then) {
@ -543,19 +563,19 @@ index b07f8f583dabb..94b2acd6ef46e 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 e21d5dbffda0b..113df89dcd68a 100644
index 6c9208d7b7907..77f049cc7483c 100644
--- chrome/browser/chrome_content_browser_client.h
+++ chrome/browser/chrome_content_browser_client.h
@@ -145,6 +145,8 @@ class ChromeContentBrowserClient : public content::ContentBrowserClient {
@@ -146,6 +146,8 @@ class ChromeContentBrowserClient : public content::ContentBrowserClient {
~ChromeContentBrowserClient() override;
+ virtual void CleanupOnUIThread();
+
// TODO(https://crbug.com/787567): This file is about calls from content/ out
// 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.
@@ -682,7 +684,7 @@ class ChromeContentBrowserClient : public content::ContentBrowserClient {
@@ -686,7 +688,7 @@ class ChromeContentBrowserClient : public content::ContentBrowserClient {
override;
void OnNetworkServiceCreated(
network::mojom::NetworkService* network_service) override;
@ -564,7 +584,7 @@ index e21d5dbffda0b..113df89dcd68a 100644
content::BrowserContext* context,
bool in_memory,
const base::FilePath& relative_partition_path,
@@ -1202,7 +1204,7 @@ class ChromeContentBrowserClient : public content::ContentBrowserClient {
@@ -1213,7 +1215,7 @@ class ChromeContentBrowserClient : public content::ContentBrowserClient {
#if !BUILDFLAG(IS_ANDROID)
uint64_t num_keepalive_requests_ = 0;
@ -574,7 +594,7 @@ index e21d5dbffda0b..113df89dcd68a 100644
#endif
diff --git chrome/browser/prefs/browser_prefs.cc chrome/browser/prefs/browser_prefs.cc
index 14c785c5686a8..ed24f5f045006 100644
index 750d634f641b1..86220ec515c0c 100644
--- chrome/browser/prefs/browser_prefs.cc
+++ chrome/browser/prefs/browser_prefs.cc
@@ -16,6 +16,7 @@
@ -585,7 +605,7 @@ index 14c785c5686a8..ed24f5f045006 100644
#include "chrome/browser/about_flags.h"
#include "chrome/browser/accessibility/accessibility_labels_service.h"
#include "chrome/browser/accessibility/invert_bubble_prefs.h"
@@ -194,6 +195,10 @@
@@ -197,6 +198,10 @@
#include "chrome/browser/background/background_mode_manager.h"
#endif
@ -596,7 +616,7 @@ index 14c785c5686a8..ed24f5f045006 100644
#if BUILDFLAG(ENABLE_EXTENSIONS)
#include "chrome/browser/accessibility/animation_policy_prefs.h"
#include "chrome/browser/apps/platform_apps/shortcut_manager.h"
@@ -1743,7 +1748,8 @@ void RegisterLocalState(PrefRegistrySimple* registry) {
@@ -1820,7 +1825,8 @@ void RegisterLocalState(PrefRegistrySimple* registry) {
#endif // BUILDFLAG(GOOGLE_CHROME_BRANDING)
#endif // BUILDFLAG(IS_WIN)
@ -606,7 +626,7 @@ index 14c785c5686a8..ed24f5f045006 100644
downgrade::RegisterPrefs(registry);
#endif
@@ -1779,6 +1785,11 @@ void RegisterLocalState(PrefRegistrySimple* registry) {
@@ -1864,6 +1870,11 @@ void RegisterLocalState(PrefRegistrySimple* registry) {
// This is intentionally last.
RegisterLocalStatePrefsForMigration(registry);
@ -618,7 +638,7 @@ index 14c785c5686a8..ed24f5f045006 100644
}
// Register prefs applicable to all profiles.
@@ -2213,6 +2224,10 @@ void RegisterUserProfilePrefs(user_prefs::PrefRegistrySyncable* registry,
@@ -2317,6 +2328,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 01d45469f3bae..d1bed9648e4a2 100644
index 3b992709445b9..822de797dcb3e 100644
--- chrome/browser/ui/browser_command_controller.cc
+++ chrome/browser/ui/browser_command_controller.cc
@@ -401,6 +401,7 @@ bool BrowserCommandController::ExecuteCommandWithDisposition(
@@ -406,6 +406,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 01d45469f3bae..d1bed9648e4a2 100644
return false;
}
@@ -417,6 +418,13 @@ bool BrowserCommandController::ExecuteCommandWithDisposition(
@@ -422,6 +423,13 @@ bool BrowserCommandController::ExecuteCommandWithDisposition(
DCHECK(command_updater_.IsCommandEnabled(id))
<< "Invalid/disabled command " << id;
@ -24,7 +24,7 @@ index 01d45469f3bae..d1bed9648e4a2 100644
// The order of commands in this switch statement must match the function
// declaration order in browser.h!
switch (id) {
@@ -1179,11 +1187,13 @@ void BrowserCommandController::TabRestoreServiceLoaded(
@@ -1207,11 +1215,13 @@ void BrowserCommandController::TabRestoreServiceLoaded(
// BrowserCommandController, private:
bool BrowserCommandController::IsShowingMainUI() {
@ -41,10 +41,10 @@ index 01d45469f3bae..d1bed9648e4a2 100644
bool BrowserCommandController::IsWebAppOrCustomTab() const {
diff --git chrome/browser/ui/toolbar/app_menu_model.cc chrome/browser/ui/toolbar/app_menu_model.cc
index fc51015c70183..52de604f96d9e 100644
index dca26d57b903d..3de463129b7ac 100644
--- chrome/browser/ui/toolbar/app_menu_model.cc
+++ chrome/browser/ui/toolbar/app_menu_model.cc
@@ -728,6 +728,57 @@ SaveAndShareSubMenuModel::SaveAndShareSubMenuModel(
@@ -739,6 +739,57 @@ SaveAndShareSubMenuModel::SaveAndShareSubMenuModel(
}
}
@ -102,7 +102,7 @@ index fc51015c70183..52de604f96d9e 100644
} // namespace
////////////////////////////////////////////////////////////////////////////////
@@ -1572,7 +1623,7 @@ bool AppMenuModel::IsCommandIdChecked(int command_id) const {
@@ -1583,7 +1634,7 @@ bool AppMenuModel::IsCommandIdChecked(int command_id) const {
return false;
}
@ -111,7 +111,7 @@ index fc51015c70183..52de604f96d9e 100644
GlobalError* error =
GlobalErrorServiceFactory::GetForProfile(browser_->profile())
->GetGlobalErrorByMenuItemCommandID(command_id);
@@ -1587,6 +1638,30 @@ bool AppMenuModel::IsCommandIdEnabled(int command_id) const {
@@ -1598,6 +1649,30 @@ bool AppMenuModel::IsCommandIdEnabled(int command_id) const {
}
}
@ -142,47 +142,20 @@ index fc51015c70183..52de604f96d9e 100644
bool AppMenuModel::IsCommandIdAlerted(int command_id) const {
if (command_id == IDC_VIEW_PASSWORDS ||
command_id == IDC_SHOW_PASSWORD_MANAGER) {
@@ -1755,11 +1830,15 @@ void AppMenuModel::Build() {
kDefaultIconSize));
}
@@ -1763,8 +1838,10 @@ void AppMenuModel::Build() {
IDS_CLEAR_BROWSING_DATA,
kTrashCanRefreshIcon);
- AddSeparator(features::IsChromeRefresh2023() ? ui::NORMAL_SEPARATOR
- : ui::LOWER_SEPARATOR);
- CreateZoomMenu();
- AddSeparator(features::IsChromeRefresh2023() ? ui::NORMAL_SEPARATOR
- : ui::UPPER_SEPARATOR);
+ if (IsCommandIdVisible(IDC_ZOOM_MENU)) {
+ AddSeparator(features::IsChromeRefresh2023() ? ui::NORMAL_SEPARATOR
+ : ui::LOWER_SEPARATOR);
+ CreateZoomMenu();
+ AddSeparator(features::IsChromeRefresh2023() ? ui::NORMAL_SEPARATOR
+ : ui::UPPER_SEPARATOR);
+ } else {
+ AddSeparator(ui::NORMAL_SEPARATOR);
AddSeparator(ui::NORMAL_SEPARATOR);
CreateZoomMenu();
+ }
AddSeparator(ui::NORMAL_SEPARATOR);
AddItemWithStringId(IDC_PRINT, IDS_PRINT);
@@ -1852,9 +1931,13 @@ void AppMenuModel::Build() {
kMoreToolsMenuItem);
if (!features::IsChromeRefresh2023()) {
- AddSeparator(ui::LOWER_SEPARATOR);
- CreateCutCopyPasteMenu();
- AddSeparator(ui::UPPER_SEPARATOR);
+ if (IsCommandIdVisible(IDC_EDIT_MENU)) {
+ AddSeparator(ui::LOWER_SEPARATOR);
+ CreateCutCopyPasteMenu();
+ AddSeparator(ui::UPPER_SEPARATOR);
+ } else {
+ AddSeparator(ui::NORMAL_SEPARATOR);
+ }
}
if (!features::IsChromeRefresh2023()) {
@@ -1943,6 +2026,11 @@ void AppMenuModel::Build() {
SetCommandIcon(this, IDC_EXIT, kExitMenuIcon);
AddItemWithStringIdAndVectorIcon(this, IDC_PRINT, IDS_PRINT, kPrintMenuIcon);
@@ -1883,6 +1960,11 @@ void AppMenuModel::Build() {
}
#endif // !BUILDFLAG(IS_CHROMEOS_ASH)
+#if BUILDFLAG(ENABLE_CEF)
+ FilterMenuModel(this, base::BindRepeating(&AppMenuModel::IsCommandIdVisible,
@ -193,10 +166,10 @@ index fc51015c70183..52de604f96d9e 100644
}
diff --git chrome/browser/ui/toolbar/app_menu_model.h chrome/browser/ui/toolbar/app_menu_model.h
index c477fba63fd1a..3b9eaad8e1906 100644
index 0824a0b655cde..507021a7c1b66 100644
--- chrome/browser/ui/toolbar/app_menu_model.h
+++ chrome/browser/ui/toolbar/app_menu_model.h
@@ -218,6 +218,7 @@ class AppMenuModel : public ui::SimpleMenuModel,
@@ -225,6 +225,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;
@ -204,9 +177,9 @@ index c477fba63fd1a..3b9eaad8e1906 100644
bool IsCommandIdAlerted(int command_id) const override;
bool IsElementIdAlerted(ui::ElementIdentifier element_id) const override;
bool GetAcceleratorForCommandId(int command_id,
@@ -259,6 +260,8 @@ class AppMenuModel : public ui::SimpleMenuModel,
safety_hub::SafetyHubModuleType sh_module,
int event_flags);
@@ -265,6 +266,8 @@ class AppMenuModel : public ui::SimpleMenuModel,
void LogSafetyHubInteractionMetrics(safety_hub::SafetyHubModuleType sh_module,
int event_flags);
+ bool IsCommandIdEnabledInternal(int command_id) const;
+
@ -411,10 +384,10 @@ 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 110812d2874d7..6ac4f560d7c27 100644
index 4b52ce3877855..7dae2a6b1b151 100644
--- chrome/browser/ui/views/frame/browser_view.cc
+++ chrome/browser/ui/views/frame/browser_view.cc
@@ -346,11 +346,10 @@ using content::NativeWebKeyboardEvent;
@@ -353,11 +353,10 @@ using content::NativeWebKeyboardEvent;
using content::WebContents;
using web_modal::WebContentsModalDialogHost;
@ -429,7 +402,7 @@ index 110812d2874d7..6ac4f560d7c27 100644
#if BUILDFLAG(IS_CHROMEOS_ASH)
// UMA histograms that record animation smoothness for tab loading animation.
@@ -683,6 +682,14 @@ class BrowserViewLayoutDelegateImpl : public BrowserViewLayoutDelegate {
@@ -690,6 +689,14 @@ class BrowserViewLayoutDelegateImpl : public BrowserViewLayoutDelegate {
return browser_view_->frame()->GetTopInset() - browser_view_->y();
}
@ -444,7 +417,7 @@ index 110812d2874d7..6ac4f560d7c27 100644
bool IsToolbarVisible() const override {
return browser_view_->IsToolbarVisible();
}
@@ -834,11 +841,21 @@ class BrowserView::AccessibilityModeObserver : public ui::AXModeObserver {
@@ -841,11 +848,21 @@ class BrowserView::AccessibilityModeObserver : public ui::AXModeObserver {
///////////////////////////////////////////////////////////////////////////////
// BrowserView, public:
@ -467,7 +440,7 @@ index 110812d2874d7..6ac4f560d7c27 100644
// Store the actions so that the access is available for other classes.
if (features::IsSidePanelPinningEnabled()) {
browser_->SetUserData(BrowserActions::UserDataKey(),
@@ -939,8 +956,15 @@ BrowserView::BrowserView(std::unique_ptr<Browser> browser)
@@ -946,8 +963,15 @@ BrowserView::BrowserView(std::unique_ptr<Browser> browser)
contents_container->SetLayoutManager(std::make_unique<ContentsLayoutManager>(
devtools_web_view_, contents_web_view_, watermark_view_));
@ -485,7 +458,7 @@ index 110812d2874d7..6ac4f560d7c27 100644
contents_separator_ =
top_container_->AddChildView(std::make_unique<ContentsSeparator>());
@@ -1017,7 +1041,9 @@ BrowserView::~BrowserView() {
@@ -1021,7 +1045,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.
@ -495,7 +468,7 @@ index 110812d2874d7..6ac4f560d7c27 100644
// Stop the animation timer explicitly here to avoid running it in a nested
// message loop, which may run by Browser destructor.
@@ -1026,17 +1052,18 @@ BrowserView::~BrowserView() {
@@ -1030,17 +1056,18 @@ BrowserView::~BrowserView() {
// Immersive mode may need to reparent views before they are removed/deleted.
immersive_mode_controller_.reset();
@ -518,7 +491,7 @@ index 110812d2874d7..6ac4f560d7c27 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.
@@ -1060,7 +1087,9 @@ BrowserView::~BrowserView() {
@@ -1064,7 +1091,9 @@ BrowserView::~BrowserView() {
// `SidePanelUI::RemoveSidePanelUIForBrowser()` deletes the
// SidePanelCoordinator.
@ -528,7 +501,7 @@ index 110812d2874d7..6ac4f560d7c27 100644
}
// static
@@ -1621,6 +1650,13 @@ gfx::Point BrowserView::GetThemeOffsetFromBrowserView() const {
@@ -1625,6 +1654,13 @@ gfx::Point BrowserView::GetThemeOffsetFromBrowserView() const {
ThemeProperties::kFrameHeightAboveTabs - browser_view_origin.y());
}
@ -542,7 +515,7 @@ index 110812d2874d7..6ac4f560d7c27 100644
// static:
BrowserView::DevToolsDockedPlacement BrowserView::GetDevToolsDockedPlacement(
const gfx::Rect& contents_webview_bounds,
@@ -2032,9 +2068,14 @@ void BrowserView::OnExclusiveAccessUserInput() {
@@ -2029,9 +2065,14 @@ void BrowserView::OnExclusiveAccessUserInput() {
bool BrowserView::ShouldHideUIForFullscreen() const {
// Immersive mode needs UI for the slide-down top panel.
@ -558,7 +531,7 @@ index 110812d2874d7..6ac4f560d7c27 100644
return frame_->GetFrameView()->ShouldHideTopUIForFullscreen();
}
@@ -3170,7 +3211,8 @@ DownloadShelf* BrowserView::GetDownloadShelf() {
@@ -3173,7 +3214,8 @@ DownloadShelf* BrowserView::GetDownloadShelf() {
}
DownloadBubbleUIController* BrowserView::GetDownloadBubbleUIController() {
@ -568,7 +541,7 @@ index 110812d2874d7..6ac4f560d7c27 100644
if (auto* download_button = toolbar_button_provider_->GetDownloadButton())
return download_button->bubble_controller();
return nullptr;
@@ -3725,7 +3767,8 @@ void BrowserView::ReparentTopContainerForEndOfImmersive() {
@@ -3728,7 +3770,8 @@ void BrowserView::ReparentTopContainerForEndOfImmersive() {
if (top_container()->parent() == this)
return;
@ -578,7 +551,7 @@ index 110812d2874d7..6ac4f560d7c27 100644
top_container()->DestroyLayer();
AddChildViewAt(top_container(), 0);
EnsureFocusOrder();
@@ -4207,11 +4250,38 @@ void BrowserView::GetAccessiblePanes(std::vector<views::View*>* panes) {
@@ -4210,11 +4253,38 @@ void BrowserView::GetAccessiblePanes(std::vector<views::View*>* panes) {
bool BrowserView::ShouldDescendIntoChildForEventHandling(
gfx::NativeView child,
const gfx::Point& location) {
@ -619,7 +592,7 @@ index 110812d2874d7..6ac4f560d7c27 100644
// Draggable regions are defined relative to the web contents.
gfx::Point point_in_contents_web_view_coords(location);
views::View::ConvertPointToTarget(GetWidget()->GetRootView(),
@@ -4220,7 +4290,7 @@ bool BrowserView::ShouldDescendIntoChildForEventHandling(
@@ -4223,7 +4293,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.
@ -628,7 +601,7 @@ index 110812d2874d7..6ac4f560d7c27 100644
point_in_contents_web_view_coords.x(),
point_in_contents_web_view_coords.y()) ||
WidgetOwnedByAnchorContainsPoint(point_in_contents_web_view_coords);
@@ -4331,8 +4401,10 @@ void BrowserView::Layout(PassKey) {
@@ -4334,8 +4404,10 @@ void BrowserView::Layout(PassKey) {
// TODO(jamescook): Why was this in the middle of layout code?
toolbar_->location_bar()->omnibox_view()->SetFocusBehavior(
@ -641,7 +614,7 @@ index 110812d2874d7..6ac4f560d7c27 100644
// Some of the situations when the BrowserView is laid out are:
// - Enter/exit immersive fullscreen mode.
@@ -4398,6 +4470,11 @@ void BrowserView::AddedToWidget() {
@@ -4401,6 +4473,11 @@ void BrowserView::AddedToWidget() {
SetThemeProfileForWindow(GetNativeWindow(), browser_->profile());
#endif
@ -653,7 +626,7 @@ index 110812d2874d7..6ac4f560d7c27 100644
toolbar_->Init();
// TODO(pbos): Investigate whether the side panels should be creatable when
@@ -4445,13 +4522,9 @@ void BrowserView::AddedToWidget() {
@@ -4448,13 +4525,9 @@ void BrowserView::AddedToWidget() {
EnsureFocusOrder();
@ -669,7 +642,7 @@ index 110812d2874d7..6ac4f560d7c27 100644
using_native_frame_ = frame_->ShouldUseNativeFrame();
MaybeInitializeWebUITabStrip();
@@ -4882,7 +4955,8 @@ void BrowserView::ProcessFullscreen(bool fullscreen,
@@ -4828,7 +4901,8 @@ void BrowserView::ProcessFullscreen(bool fullscreen,
// Undo our anti-jankiness hacks and force a re-layout.
in_process_fullscreen_ = false;
ToolbarSizeChanged(false);
@ -678,8 +651,8 @@ index 110812d2874d7..6ac4f560d7c27 100644
+ frame_->GetFrameView()->OnFullscreenStateChanged();
}
bool BrowserView::ShouldUseImmersiveFullscreenForUrl(const GURL& url) const {
@@ -5304,6 +5378,8 @@ Profile* BrowserView::GetProfile() {
void BrowserView::RequestFullscreen(bool fullscreen, int64_t display_id) {
@@ -5312,6 +5386,8 @@ Profile* BrowserView::GetProfile() {
}
void BrowserView::UpdateUIForTabFullscreen() {
@ -688,7 +661,7 @@ index 110812d2874d7..6ac4f560d7c27 100644
frame()->GetFrameView()->UpdateFullscreenTopUI();
}
@@ -5326,6 +5402,8 @@ void BrowserView::HideDownloadShelf() {
@@ -5334,6 +5410,8 @@ void BrowserView::HideDownloadShelf() {
}
bool BrowserView::CanUserExitFullscreen() const {
@ -698,10 +671,10 @@ index 110812d2874d7..6ac4f560d7c27 100644
}
diff --git chrome/browser/ui/views/frame/browser_view.h chrome/browser/ui/views/frame/browser_view.h
index 46cdfe23b1234..4f3b2b7650b72 100644
index e7337adf73caf..6130a2eb8fb5c 100644
--- chrome/browser/ui/views/frame/browser_view.h
+++ chrome/browser/ui/views/frame/browser_view.h
@@ -138,11 +138,16 @@ class BrowserView : public BrowserWindow,
@@ -143,11 +143,16 @@ class BrowserView : public BrowserWindow,
METADATA_HEADER(BrowserView, views::ClientView)
public:
@ -739,7 +712,7 @@ index 46cdfe23b1234..4f3b2b7650b72 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 07bc84fe5ed23..9d05d8918fa3d 100644
index a7f0ff7ce857e..0ee1c61503204 100644
--- chrome/browser/ui/views/frame/browser_view_layout.cc
+++ chrome/browser/ui/views/frame/browser_view_layout.cc
@@ -48,6 +48,10 @@
@ -812,8 +785,8 @@ index 07bc84fe5ed23..9d05d8918fa3d 100644
+ }
}
// Return the preferred size which is the size required to give each
@@ -583,6 +601,13 @@ int BrowserViewLayout::LayoutWebUITabStrip(int top) {
gfx::Size BrowserViewLayout::GetPreferredSize(
@@ -589,6 +607,13 @@ int BrowserViewLayout::LayoutWebUITabStrip(int top) {
int BrowserViewLayout::LayoutToolbar(int top) {
TRACE_EVENT0("ui", "BrowserViewLayout::LayoutToolbar");
@ -857,10 +830,10 @@ 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 b1662191f0967..245895ab7bd37 100644
index 636be129ccfd6..dbb19d94c1ef9 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
@@ -610,6 +610,11 @@ PictureInPictureBrowserFrameView::PictureInPictureBrowserFrameView(
@@ -604,6 +604,11 @@ PictureInPictureBrowserFrameView::PictureInPictureBrowserFrameView(
frame->GetNativeWindow()->SetEventTargeter(
std::make_unique<chromeos::InteriorResizeHandleTargeter>());
#endif
@ -872,7 +845,7 @@ index b1662191f0967..245895ab7bd37 100644
}
PictureInPictureBrowserFrameView::~PictureInPictureBrowserFrameView() {
@@ -737,18 +742,42 @@ gfx::Rect PictureInPictureBrowserFrameView::GetWindowBoundsForClientBounds(
@@ -731,18 +736,42 @@ gfx::Rect PictureInPictureBrowserFrameView::GetWindowBoundsForClientBounds(
int PictureInPictureBrowserFrameView::NonClientHitTest(
const gfx::Point& point) {
@ -923,7 +896,7 @@ index b1662191f0967..245895ab7bd37 100644
// Allow dragging and resizing the window.
int window_component = GetHTComponentForFrame(
@@ -817,7 +846,8 @@ void PictureInPictureBrowserFrameView::Layout(PassKey) {
@@ -811,7 +840,8 @@ void PictureInPictureBrowserFrameView::Layout(PassKey) {
gfx::Rect content_area = GetLocalBounds();
content_area.Inset(FrameBorderInsets());
gfx::Rect top_bar = content_area;
@ -933,7 +906,7 @@ index b1662191f0967..245895ab7bd37 100644
top_bar_container_view_->SetBoundsRect(top_bar);
#if !BUILDFLAG(IS_ANDROID)
if (auto_pip_setting_overlay_) {
@@ -1309,7 +1339,8 @@ gfx::Insets PictureInPictureBrowserFrameView::ResizeBorderInsets() const {
@@ -1298,7 +1328,8 @@ gfx::Insets PictureInPictureBrowserFrameView::ResizeBorderInsets() const {
}
int PictureInPictureBrowserFrameView::GetTopAreaHeight() const {
@ -958,10 +931,10 @@ 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 db003cd7f8329..9ba9064ef0563 100644
index ad0147f9b8fe8..80aea21bb605a 100644
--- chrome/browser/ui/views/page_action/page_action_icon_controller.cc
+++ chrome/browser/ui/views/page_action/page_action_icon_controller.cc
@@ -95,6 +95,12 @@ void PageActionIconController::Init(const PageActionIconParams& params,
@@ -96,6 +96,12 @@ void PageActionIconController::Init(const PageActionIconParams& params,
};
for (PageActionIconType type : params.types_enabled) {
@ -1021,10 +994,10 @@ index 880d83324cfa6..a6a80cd0b3def 100644
}
diff --git chrome/browser/ui/views/toolbar/toolbar_view.cc chrome/browser/ui/views/toolbar/toolbar_view.cc
index e97342ef97514..03b140c9fc7c6 100644
index e02fe5d5e6290..9e893b2ff1727 100644
--- chrome/browser/ui/views/toolbar/toolbar_view.cc
+++ chrome/browser/ui/views/toolbar/toolbar_view.cc
@@ -191,7 +191,7 @@ class TabstripLikeBackground : public views::Background {
@@ -192,7 +192,7 @@ class TabstripLikeBackground : public views::Background {
void Paint(gfx::Canvas* canvas, views::View* view) const override {
bool painted = TopContainerBackground::PaintThemeCustomImage(canvas, view,
browser_view_);
@ -1033,7 +1006,7 @@ index e97342ef97514..03b140c9fc7c6 100644
SkColor frame_color =
browser_view_->frame()->GetFrameView()->GetFrameColor(
BrowserFrameActiveState::kUseCurrent);
@@ -221,12 +221,13 @@ END_METADATA
@@ -222,12 +222,13 @@ END_METADATA
////////////////////////////////////////////////////////////////////////////////
// ToolbarView, public:
@ -1049,7 +1022,7 @@ index e97342ef97514..03b140c9fc7c6 100644
SetID(VIEW_ID_TOOLBAR);
container_view_ = AddChildView(std::make_unique<ContainerView>());
@@ -248,9 +249,24 @@ ToolbarView::~ToolbarView() {
@@ -251,9 +252,24 @@ ToolbarView::~ToolbarView() {
for (const auto& view_and_command : GetViewCommandMap())
chrome::RemoveCommandObserver(browser_, view_and_command.second, this);
@ -1074,7 +1047,7 @@ index e97342ef97514..03b140c9fc7c6 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
@@ -275,12 +291,12 @@ void ToolbarView::Init() {
@@ -278,12 +294,12 @@ void ToolbarView::Init() {
auto location_bar = std::make_unique<LocationBarView>(
browser_, browser_->profile(), browser_->command_controller(), this,
@ -1089,7 +1062,7 @@ index e97342ef97514..03b140c9fc7c6 100644
download_button =
std::make_unique<DownloadToolbarButtonView>(browser_view_);
}
@@ -362,8 +378,10 @@ void ToolbarView::Init() {
@@ -365,8 +381,10 @@ void ToolbarView::Init() {
}
}
std::unique_ptr<media_router::CastToolbarButton> cast;
@ -1101,7 +1074,7 @@ index e97342ef97514..03b140c9fc7c6 100644
std::unique_ptr<MediaToolbarButtonView> media_button;
if (base::FeatureList::IsEnabled(media::kGlobalMediaControls)) {
@@ -373,7 +391,8 @@ void ToolbarView::Init() {
@@ -376,7 +394,8 @@ void ToolbarView::Init() {
std::unique_ptr<send_tab_to_self::SendTabToSelfToolbarIconView>
send_tab_to_self_button;
@ -1111,7 +1084,7 @@ index e97342ef97514..03b140c9fc7c6 100644
send_tab_to_self_button =
std::make_unique<send_tab_to_self::SendTabToSelfToolbarIconView>(
browser_view_);
@@ -452,7 +471,7 @@ void ToolbarView::Init() {
@@ -461,7 +480,7 @@ void ToolbarView::Init() {
send_tab_to_self_button_ =
container_view_->AddChildView(std::move(send_tab_to_self_button));
@ -1120,7 +1093,7 @@ index e97342ef97514..03b140c9fc7c6 100644
if (companion::IsCompanionFeatureEnabled()) {
side_panel_container_ = container_view_->AddChildView(
std::make_unique<SidePanelToolbarContainer>(browser_view_));
@@ -818,7 +837,7 @@ void ToolbarView::Layout(PassKey) {
@@ -828,7 +847,7 @@ void ToolbarView::Layout(PassKey) {
if (display_mode_ == DisplayMode::NORMAL) {
LayoutCommon();
@ -1130,10 +1103,10 @@ index e97342ef97514..03b140c9fc7c6 100644
}
}
diff --git chrome/browser/ui/views/toolbar/toolbar_view.h chrome/browser/ui/views/toolbar/toolbar_view.h
index 1163e52e738ce..e70ebde66fb25 100644
index 2437b17ffab96..24ac297165db1 100644
--- chrome/browser/ui/views/toolbar/toolbar_view.h
+++ chrome/browser/ui/views/toolbar/toolbar_view.h
@@ -93,7 +93,8 @@ class ToolbarView : public views::AccessiblePaneView,
@@ -94,7 +94,8 @@ class ToolbarView : public views::AccessiblePaneView,
// needs to be displayed.
};
@ -1143,3 +1116,16 @@ index 1163e52e738ce..e70ebde66fb25 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 chrome/utility/chrome_content_utility_client.cc chrome/utility/chrome_content_utility_client.cc
index c15d1fa6d6e25..f7356f7c1ef64 100644
index 8a498ddd2c563..1a96939d54079 100644
--- chrome/utility/chrome_content_utility_client.cc
+++ chrome/utility/chrome_content_utility_client.cc
@@ -13,6 +13,7 @@
@@ -14,6 +14,7 @@
#include "base/path_service.h"
#include "base/task/single_thread_task_runner.h"
#include "build/build_config.h"
@ -10,7 +10,7 @@ index c15d1fa6d6e25..f7356f7c1ef64 100644
#include "chrome/common/chrome_paths.h"
#include "chrome/common/profiler/thread_profiler.h"
#include "chrome/common/profiler/thread_profiler_configuration.h"
@@ -54,7 +55,11 @@ void ChromeContentUtilityClient::UtilityThreadStarted() {
@@ -55,7 +56,11 @@ void ChromeContentUtilityClient::UtilityThreadStarted() {
command_line->GetSwitchValueASCII(switches::kProcessType);
// An in-process utility thread may run in other processes, only set up
// collector in a utility process.
@ -20,6 +20,6 @@ index c15d1fa6d6e25..f7356f7c1ef64 100644
+ && !cef::IsAlloyRuntimeEnabled()
+#endif
+ ) {
const auto* heap_profiler_controller =
heap_profiling::HeapProfilerController::GetInstance();
// The HeapProfilerController should have been created in
// ChromeMainDelegate::PostEarlyInitialization.
using HeapProfilerController = heap_profiling::HeapProfilerController;

View File

@ -1,5 +1,5 @@
diff --git ui/color/color_provider_manager.cc ui/color/color_provider_manager.cc
index a0933fab35037..7a381e24a8816 100644
index 452f80c94d684..671f36923741d 100644
--- ui/color/color_provider_manager.cc
+++ ui/color/color_provider_manager.cc
@@ -46,6 +46,15 @@ std::optional<GlobalManager>& GetGlobalManager() {

View File

@ -1,5 +1,5 @@
diff --git content/browser/devtools/devtools_instrumentation.h content/browser/devtools/devtools_instrumentation.h
index 7c7589a393254..573c11adc21c7 100644
index c16e81b7d357f..2e74fc89de36f 100644
--- content/browser/devtools/devtools_instrumentation.h
+++ content/browser/devtools/devtools_instrumentation.h
@@ -115,7 +115,7 @@ bool ApplyUserAgentMetadataOverrides(
@ -68,7 +68,7 @@ index 6af484f35f576..2462700b6d1fb 100644
blink::mojom::V8CacheOptions GetV8CacheOptions();
diff --git third_party/blink/renderer/controller/BUILD.gn third_party/blink/renderer/controller/BUILD.gn
index 6af8af9ed5f95..4cf7b7a56f07a 100644
index 47e37a2aaa79c..7a65e0654453a 100644
--- third_party/blink/renderer/controller/BUILD.gn
+++ third_party/blink/renderer/controller/BUILD.gn
@@ -38,6 +38,7 @@ component("controller") {
@ -79,7 +79,7 @@ index 6af8af9ed5f95..4cf7b7a56f07a 100644
"//third_party/blink/renderer:config",
"//third_party/blink/renderer:inside_blink",
"//third_party/blink/renderer:non_test_config",
@@ -65,6 +66,8 @@ component("controller") {
@@ -67,6 +68,8 @@ component("controller") {
"performance_manager/v8_detailed_memory_reporter_impl.h",
"performance_manager/v8_worker_memory_reporter.cc",
"performance_manager/v8_worker_memory_reporter.h",

View File

@ -1,5 +1,5 @@
diff --git content/browser/devtools/devtools_http_handler.cc content/browser/devtools/devtools_http_handler.cc
index 724be962f293c..88260e45c55ad 100644
index 2068552edfba8..6ef07a0a5b7fa 100644
--- content/browser/devtools/devtools_http_handler.cc
+++ content/browser/devtools/devtools_http_handler.cc
@@ -591,7 +591,7 @@ void DevToolsHttpHandler::OnJsonRequest(
@ -12,10 +12,10 @@ index 724be962f293c..88260e45c55ad 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 7bd47c28bab3e..38258cbd9641a 100644
index eef1951861e8b..4800ef3400623 100644
--- content/browser/loader/navigation_url_loader_impl.cc
+++ content/browser/loader/navigation_url_loader_impl.cc
@@ -849,7 +849,7 @@ NavigationURLLoaderImpl::CreateNonNetworkLoaderFactory(
@@ -850,7 +850,7 @@ NavigationURLLoaderImpl::CreateNonNetworkLoaderFactory(
mojo::PendingRemote<network::mojom::URLLoaderFactory>
terminal_external_protocol;
bool handled = GetContentClient()->browser()->HandleExternalProtocol(
@ -24,7 +24,7 @@ index 7bd47c28bab3e..38258cbd9641a 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,
@@ -861,6 +861,21 @@ NavigationURLLoaderImpl::CreateNonNetworkLoaderFactory(
@@ -862,6 +862,21 @@ NavigationURLLoaderImpl::CreateNonNetworkLoaderFactory(
*request_info.initiator_document_token)
: nullptr,
&terminal_external_protocol);
@ -47,10 +47,10 @@ index 7bd47c28bab3e..38258cbd9641a 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 d2975a6c36e2c..70040d91977ca 100644
index 62fed61bd87f1..7a4631e9fb6b7 100644
--- content/public/browser/content_browser_client.cc
+++ content/public/browser/content_browser_client.cc
@@ -1090,7 +1090,7 @@ ContentBrowserClient::CreateURLLoaderHandlerForServiceWorkerNavigationPreload(
@@ -1100,7 +1100,7 @@ ContentBrowserClient::CreateURLLoaderHandlerForServiceWorkerNavigationPreload(
void ContentBrowserClient::OnNetworkServiceCreated(
network::mojom::NetworkService* network_service) {}
@ -59,7 +59,7 @@ index d2975a6c36e2c..70040d91977ca 100644
BrowserContext* context,
bool in_memory,
const base::FilePath& relative_partition_path,
@@ -1099,6 +1099,7 @@ void ContentBrowserClient::ConfigureNetworkContextParams(
@@ -1109,6 +1109,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 d2975a6c36e2c..70040d91977ca 100644
std::vector<base::FilePath>
diff --git content/public/browser/content_browser_client.h content/public/browser/content_browser_client.h
index 6aea068af5ab0..82f40ed3b70fb 100644
index 406607bd32563..e32e445aa8923 100644
--- content/public/browser/content_browser_client.h
+++ content/public/browser/content_browser_client.h
@@ -2061,7 +2061,7 @@ class CONTENT_EXPORT ContentBrowserClient {
@@ -2079,7 +2079,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 6aea068af5ab0..82f40ed3b70fb 100644
BrowserContext* context,
bool in_memory,
const base::FilePath& relative_partition_path,
@@ -2282,6 +2282,21 @@ class CONTENT_EXPORT ContentBrowserClient {
@@ -2300,6 +2300,21 @@ class CONTENT_EXPORT ContentBrowserClient {
RenderFrameHost* initiator_document,
mojo::PendingRemote<network::mojom::URLLoaderFactory>* out_factory);
@ -102,7 +102,7 @@ index 6aea068af5ab0..82f40ed3b70fb 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.
@@ -2339,6 +2354,10 @@ class CONTENT_EXPORT ContentBrowserClient {
@@ -2357,6 +2372,10 @@ class CONTENT_EXPORT ContentBrowserClient {
// Used as part of the user agent string.
virtual std::string GetProduct();
@ -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 d38d1cbd515be..7ac2dfe95fdd0 100644
index da4a8410a6c5d..41cb281d271dd 100644
--- content/renderer/render_thread_impl.cc
+++ content/renderer/render_thread_impl.cc
@@ -548,6 +548,8 @@ void RenderThreadImpl::Init() {
@@ -549,6 +549,8 @@ void RenderThreadImpl::Init() {
GetContentClient()->renderer()->CreateURLLoaderThrottleProvider(
blink::URLLoaderThrottleProviderType::kFrame);
@ -152,10 +152,10 @@ index d38d1cbd515be..7ac2dfe95fdd0 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 81b4ff933b5d9..859ad94d4c224 100644
index c053926291ea4..6edf384e53cd8 100644
--- content/renderer/renderer_blink_platform_impl.cc
+++ content/renderer/renderer_blink_platform_impl.cc
@@ -1001,6 +1001,15 @@ SkBitmap* RendererBlinkPlatformImpl::GetSadPageBitmap() {
@@ -989,6 +989,15 @@ SkBitmap* RendererBlinkPlatformImpl::GetSadPageBitmap() {
//------------------------------------------------------------------------------
@ -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 5f2cc5ce07558..8e3324ebefc12 100644
index d8a569dde0012..d3e755f66e4ec 100644
--- content/shell/browser/shell_content_browser_client.cc
+++ content/shell/browser/shell_content_browser_client.cc
@@ -734,7 +734,7 @@ void ShellContentBrowserClient::OnNetworkServiceCreated(
@@ -749,7 +749,7 @@ void ShellContentBrowserClient::OnNetworkServiceCreated(
#endif
}
@ -198,7 +198,7 @@ index 5f2cc5ce07558..8e3324ebefc12 100644
BrowserContext* context,
bool in_memory,
const base::FilePath& relative_partition_path,
@@ -743,6 +743,7 @@ void ShellContentBrowserClient::ConfigureNetworkContextParams(
@@ -758,6 +758,7 @@ void ShellContentBrowserClient::ConfigureNetworkContextParams(
cert_verifier_creation_params) {
ConfigureNetworkContextParamsForShell(context, network_context_params,
cert_verifier_creation_params);
@ -207,10 +207,10 @@ index 5f2cc5ce07558..8e3324ebefc12 100644
std::vector<base::FilePath>
diff --git content/shell/browser/shell_content_browser_client.h content/shell/browser/shell_content_browser_client.h
index f73d9b1264238..145052c3cadd4 100644
index 810c7adb1e2b9..1827d957ed012 100644
--- content/shell/browser/shell_content_browser_client.h
+++ content/shell/browser/shell_content_browser_client.h
@@ -146,7 +146,7 @@ class ShellContentBrowserClient : public ContentBrowserClient {
@@ -151,7 +151,7 @@ class ShellContentBrowserClient : public ContentBrowserClient {
GetGeolocationSystemPermissionManager() override;
void OnNetworkServiceCreated(
network::mojom::NetworkService* network_service) override;
@ -220,10 +220,10 @@ index f73d9b1264238..145052c3cadd4 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 9e6c52dab9abb..e5c3bc53e27d3 100644
index e4be49f9cccf8..6132a90e5ee93 100644
--- headless/lib/browser/headless_content_browser_client.cc
+++ headless/lib/browser/headless_content_browser_client.cc
@@ -297,7 +297,7 @@ bool HeadlessContentBrowserClient::IsSharedStorageSelectURLAllowed(
@@ -301,7 +301,7 @@ bool HeadlessContentBrowserClient::IsSharedStorageSelectURLAllowed(
return true;
}
@ -232,7 +232,7 @@ index 9e6c52dab9abb..e5c3bc53e27d3 100644
content::BrowserContext* context,
bool in_memory,
const base::FilePath& relative_partition_path,
@@ -307,6 +307,7 @@ void HeadlessContentBrowserClient::ConfigureNetworkContextParams(
@@ -311,6 +311,7 @@ void HeadlessContentBrowserClient::ConfigureNetworkContextParams(
HeadlessBrowserContextImpl::From(context)->ConfigureNetworkContextParams(
in_memory, relative_partition_path, network_context_params,
cert_verifier_creation_params);
@ -241,12 +241,12 @@ index 9e6c52dab9abb..e5c3bc53e27d3 100644
std::string HeadlessContentBrowserClient::GetProduct() {
diff --git headless/lib/browser/headless_content_browser_client.h headless/lib/browser/headless_content_browser_client.h
index c5413f8d2979f..f323ff7843dc4 100644
index 90cc52b93e737..882f385844d59 100644
--- headless/lib/browser/headless_content_browser_client.h
+++ headless/lib/browser/headless_content_browser_client.h
@@ -83,7 +83,7 @@ class HeadlessContentBrowserClient : public content::ContentBrowserClient {
const url::Origin& accessing_origin,
std::string* out_debug_message = nullptr) override;
@@ -85,7 +85,7 @@ class HeadlessContentBrowserClient : public content::ContentBrowserClient {
std::string* out_debug_message,
bool* out_block_is_site_setting_specific) override;
- void ConfigureNetworkContextParams(
+ bool ConfigureNetworkContextParams(

View File

@ -0,0 +1,12 @@
diff --git content/browser/renderer_host/navigation_policy_container_builder.cc content/browser/renderer_host/navigation_policy_container_builder.cc
index e1ca048945905..db386eca4d8d3 100644
--- content/browser/renderer_host/navigation_policy_container_builder.cc
+++ content/browser/renderer_host/navigation_policy_container_builder.cc
@@ -43,7 +43,6 @@ std::unique_ptr<PolicyContainerPolicies> GetInitiatorPolicies(
RenderFrameHostImpl::GetPolicyContainerHost(
frame_token, initiator_process_id, storage_partition);
- DCHECK(initiator_policy_container_host);
if (!initiator_policy_container_host) {
// Guard against wrong tokens being passed accidentally.
return nullptr;

View File

@ -12,7 +12,7 @@ index 79ba3ac1913f8..46bcb4366d2f8 100644
if (main_argv)
setproctitle_init(main_argv);
diff --git content/app/content_main.cc content/app/content_main.cc
index 91feb21f4249e..88643fdeb4c4c 100644
index 96c28a7ce3183..3d60ab170e9a5 100644
--- content/app/content_main.cc
+++ content/app/content_main.cc
@@ -174,11 +174,8 @@ ContentMainParams::~ContentMainParams() = default;
@ -39,14 +39,14 @@ index 91feb21f4249e..88643fdeb4c4c 100644
// A flag to indicate whether Main() has been called before. On Android, we
// may re-run Main() without restarting the browser process. This flag
@@ -274,20 +268,13 @@ RunContentProcess(ContentMainParams params,
@@ -274,14 +268,6 @@ RunContentProcess(ContentMainParams params,
#endif
#if BUILDFLAG(IS_MAC)
- // We need this pool for all the objects created before we get to the event
- // loop, but we don't want to leave them hanging around until the app quits.
- // Each "main" needs to flush this pool right before it goes into its main
- // event loop to get rid of the cruft. TODO(https://crbug.com/1424190): This
- // event loop to get rid of the cruft. TODO(crbug.com/40260311): This
- // is not safe. Each main loop should create and destroy its own pool; it
- // should not be flushing the pool at the base of the autorelease pool
- // stack.
@ -54,43 +54,7 @@ index 91feb21f4249e..88643fdeb4c4c 100644
InitializeMac();
#endif
+ base::CommandLine* command_line = base::CommandLine::ForCurrentProcess();
+
#if BUILDFLAG(IS_IOS)
base::ConditionVariable::InitializeFeatures();
- base::CommandLine* command_line = base::CommandLine::ForCurrentProcess();
command_line->AppendSwitch(switches::kEnableViewport);
command_line->AppendSwitch(switches::kUseMobileUserAgent);
#endif
@@ -304,19 +291,19 @@ RunContentProcess(ContentMainParams params,
}
#if BUILDFLAG(IS_WIN)
- base::CommandLine* command_line = base::CommandLine::ForCurrentProcess();
- if (command_line->HasSwitch(switches::kHeadless)) {
- // When running in headless mode we want stdio routed however if
- // console does not exist we should not create one.
- base::RouteStdioToConsole(/*create_console_if_not_found*/ false);
- } else if (command_line->HasSwitch(switches::kEnableLogging)) {
+ if (command_line->HasSwitch(switches::kEnableLogging)) {
+ // Don't route to console for "handle" type in child processes.
+ if (command_line->GetSwitchValueASCII(switches::kEnableLogging) !=
+ "handle") {
+ base::RouteStdioToConsole(/*create_console_if_not_found*/ true);
+ }
+ } else if (command_line->HasSwitch(switches::kHeadless)) {
// Route stdio to parent console (if any) or create one.
base::RouteStdioToConsole(/*create_console_if_not_found*/ true);
}
#endif
- if (base::CommandLine::ForCurrentProcess()->HasSwitch(
- ::switches::kTraceToConsole)) {
+ if (command_line->HasSwitch(::switches::kTraceToConsole)) {
base::trace_event::TraceConfig trace_config =
tracing::GetConfigForTraceToConsole();
base::trace_event::TraceLog::GetInstance()->SetEnabled(
@@ -326,12 +313,46 @@ RunContentProcess(ContentMainParams params,
@@ -329,12 +315,46 @@ RunContentProcess(ContentMainParams params,
if (IsSubprocess())
CommonSubprocessInit();
@ -139,7 +103,7 @@ index 91feb21f4249e..88643fdeb4c4c 100644
}
diff --git content/app/content_main_runner_impl.cc content/app/content_main_runner_impl.cc
index faa4e5ced67f3..946f26d2c5fe7 100644
index 5e4c1f8d6c872..6df7bdba1cff7 100644
--- content/app/content_main_runner_impl.cc
+++ content/app/content_main_runner_impl.cc
@@ -47,6 +47,7 @@
@ -150,7 +114,7 @@ index faa4e5ced67f3..946f26d2c5fe7 100644
#include "base/time/time.h"
#include "base/trace_event/trace_event.h"
#include "build/build_config.h"
@@ -1338,6 +1339,11 @@ void ContentMainRunnerImpl::Shutdown() {
@@ -1349,6 +1350,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 1dcae1e41f4dc..43951c1c55f1a 100644
index 83defaaaad55d..76486ceed16e5 100644
--- content/browser/renderer_host/render_process_host_impl.cc
+++ content/browser/renderer_host/render_process_host_impl.cc
@@ -1624,7 +1624,8 @@ bool RenderProcessHostImpl::Init() {
@@ -1628,7 +1628,8 @@ bool RenderProcessHostImpl::Init() {
// initialized because in tests the factory may never have been initialized.
if (!GetBrowserContext()->IsOffTheRecord() &&
!base::CommandLine::ForCurrentProcess()->HasSwitch(

View File

@ -81,19 +81,19 @@ index 30a2c1adc4509..b60a7afaf1e5e 100644
g_crash_helper_enabled = true;
return true;
diff --git chrome/common/crash_keys.cc chrome/common/crash_keys.cc
index 81fb33468431c..9b0d500e37452 100644
index a29f22161328a..4de56b81683f3 100644
--- chrome/common/crash_keys.cc
+++ chrome/common/crash_keys.cc
@@ -6,6 +6,8 @@
@@ -7,6 +7,8 @@
#include <deque>
#include <string_view>
+#include <iterator>
+
#include "base/base_switches.h"
#include "base/command_line.h"
#include "base/format_macros.h"
@@ -99,8 +101,10 @@ void HandleEnableDisableFeatures(const base::CommandLine& command_line) {
@@ -100,8 +102,10 @@ void HandleEnableDisableFeatures(const base::CommandLine& command_line) {
"commandline-disabled-feature");
}
@ -105,7 +105,7 @@ index 81fb33468431c..9b0d500e37452 100644
static const char* const kIgnoreSwitches[] = {
switches::kEnableLogging,
switches::kFlagSwitchesBegin,
@@ -159,11 +163,9 @@ bool IsBoringSwitch(const std::string& flag) {
@@ -160,11 +164,9 @@ bool IsBoringSwitch(const std::string& flag) {
return false;
}
@ -270,7 +270,7 @@ index a604df7a5ea6a..618fbde10a65c 100644
} // namespace crash_reporter
diff --git components/crash/core/app/crashpad.cc components/crash/core/app/crashpad.cc
index 4a25417a565fd..a7a1d451b56f9 100644
index 874ade6000ded..31fffc23197fc 100644
--- components/crash/core/app/crashpad.cc
+++ components/crash/core/app/crashpad.cc
@@ -137,7 +137,8 @@ bool InitializeCrashpadImpl(bool initial_client,
@ -462,10 +462,10 @@ index eb5bcfe0234c3..8963b26806922 100644
handler_path, *database_path, metrics_path, url,
GetProcessSimpleAnnotations(), arguments, true, false);
diff --git components/crash/core/app/crashpad_win.cc components/crash/core/app/crashpad_win.cc
index 15addd5c5e663..f30027b9b6f3c 100644
index 0e00d26f79231..fdd2b4bc73f8e 100644
--- components/crash/core/app/crashpad_win.cc
+++ components/crash/core/app/crashpad_win.cc
@@ -36,8 +36,8 @@ void GetPlatformCrashpadAnnotations(
@@ -37,8 +37,8 @@ void GetPlatformCrashpadAnnotations(
std::wstring product_name, version, special_build, channel_name;
crash_reporter_client->GetProductNameAndVersion(
exe_file, &product_name, &version, &special_build, &channel_name);
@ -476,7 +476,7 @@ index 15addd5c5e663..f30027b9b6f3c 100644
#if BUILDFLAG(GOOGLE_CHROME_BRANDING)
// Empty means stable.
const bool allow_empty_channel = true;
@@ -54,9 +54,11 @@ void GetPlatformCrashpadAnnotations(
@@ -55,9 +55,11 @@ void GetPlatformCrashpadAnnotations(
if (!special_build.empty())
(*annotations)["special"] = base::WideToUTF8(special_build);
#if defined(ARCH_CPU_X86)
@ -490,7 +490,7 @@ index 15addd5c5e663..f30027b9b6f3c 100644
#endif
}
@@ -71,7 +73,9 @@ bool PlatformCrashpadInitialization(
@@ -72,7 +74,9 @@ bool PlatformCrashpadInitialization(
base::FilePath metrics_path; // Only valid in the browser process.
const char kPipeNameVar[] = "CHROME_CRASHPAD_PIPE_NAME";
@ -500,7 +500,7 @@ index 15addd5c5e663..f30027b9b6f3c 100644
std::unique_ptr<base::Environment> env(base::Environment::Create());
CrashReporterClient* crash_reporter_client = GetCrashReporterClient();
@@ -94,9 +98,11 @@ bool PlatformCrashpadInitialization(
@@ -95,9 +99,11 @@ bool PlatformCrashpadInitialization(
std::string url = crash_reporter_client->GetUploadUrl();
@ -512,7 +512,7 @@ index 15addd5c5e663..f30027b9b6f3c 100644
base::FilePath exe_file(exe_path);
if (exe_file.empty()) {
@@ -107,13 +113,14 @@ bool PlatformCrashpadInitialization(
@@ -108,13 +114,14 @@ bool PlatformCrashpadInitialization(
exe_file = base::FilePath(exe_file_path);
}
@ -533,7 +533,7 @@ index 15addd5c5e663..f30027b9b6f3c 100644
start_arguments.push_back(std::string("--user-data-dir=") +
user_data_dir);
@@ -124,9 +131,12 @@ bool PlatformCrashpadInitialization(
start_arguments.push_back("/prefetch:4");
app_launch_prefetch::SubprocessType::kCrashpad)));
} else {
base::FilePath exe_dir = exe_file.DirName();
- exe_file = exe_dir.Append(FILE_PATH_LITERAL("crashpad_handler.exe"));

View File

@ -1,5 +1,5 @@
diff --git components/embedder_support/user_agent_utils.cc components/embedder_support/user_agent_utils.cc
index 1a388cf3b3c0b..f570a2e1f396b 100644
index fe76e8806f05f..30b184844a5b5 100644
--- components/embedder_support/user_agent_utils.cc
+++ components/embedder_support/user_agent_utils.cc
@@ -18,6 +18,7 @@

View File

@ -1,5 +1,5 @@
diff --git chrome/browser/extensions/api/streams_private/streams_private_api.cc chrome/browser/extensions/api/streams_private/streams_private_api.cc
index 96a290eef86ca..bee0f9eaad71e 100644
index b9b147c8c11df..1e3acf4e679ae 100644
--- chrome/browser/extensions/api/streams_private/streams_private_api.cc
+++ chrome/browser/extensions/api/streams_private/streams_private_api.cc
@@ -6,6 +6,7 @@
@ -10,7 +10,7 @@ index 96a290eef86ca..bee0f9eaad71e 100644
#include "chrome/browser/extensions/extension_tab_util.h"
#include "chrome/browser/preloading/prefetch/no_state_prefetch/chrome_no_state_prefetch_contents_delegate.h"
#include "components/no_state_prefetch/browser/no_state_prefetch_contents.h"
@@ -27,6 +28,10 @@
@@ -26,6 +27,10 @@
#include "pdf/pdf_features.h"
#endif // BUILDFLAG(ENABLE_PDF)
@ -21,7 +21,7 @@ index 96a290eef86ca..bee0f9eaad71e 100644
namespace extensions {
void StreamsPrivateAPI::SendExecuteMimeTypeHandlerEvent(
@@ -44,6 +49,9 @@ void StreamsPrivateAPI::SendExecuteMimeTypeHandlerEvent(
@@ -43,6 +48,9 @@ void StreamsPrivateAPI::SendExecuteMimeTypeHandlerEvent(
if (!web_contents)
return;
@ -31,7 +31,7 @@ index 96a290eef86ca..bee0f9eaad71e 100644
// If the request was for NoStatePrefetch, abort the prefetcher and do not
// continue. This is because plugins cancel NoStatePrefetch, see
// http://crbug.com/343590.
@@ -54,6 +62,9 @@ void StreamsPrivateAPI::SendExecuteMimeTypeHandlerEvent(
@@ -53,6 +61,9 @@ void StreamsPrivateAPI::SendExecuteMimeTypeHandlerEvent(
no_state_prefetch_contents->Destroy(prerender::FINAL_STATUS_DOWNLOAD);
return;
}
@ -41,7 +41,7 @@ index 96a290eef86ca..bee0f9eaad71e 100644
auto* browser_context = web_contents->GetBrowserContext();
@@ -80,9 +91,18 @@ void StreamsPrivateAPI::SendExecuteMimeTypeHandlerEvent(
@@ -79,9 +90,18 @@ void StreamsPrivateAPI::SendExecuteMimeTypeHandlerEvent(
// forms of zooming won't work).
// TODO(crbug.com/40114809): Present a coherent representation of a tab id for
// portal contents.
@ -64,7 +64,7 @@ index 96a290eef86ca..bee0f9eaad71e 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 5a0ba568bf30c..8ef4be85e038a 100644
index 2bf778dd0c85d..c75d693c6487b 100644
--- extensions/browser/extension_host.cc
+++ extensions/browser/extension_host.cc
@@ -142,12 +142,13 @@ ExtensionHost::ExtensionHost(const Extension* extension,
@ -203,10 +203,10 @@ index c3197eb4790fa..f558ff72bdbac 100644
}
diff --git extensions/browser/extensions_browser_client.h extensions/browser/extensions_browser_client.h
index 7e5c2918e273f..f00799f9e0dad 100644
index 8b515b7b8c353..f8e4106ac26d4 100644
--- extensions/browser/extensions_browser_client.h
+++ extensions/browser/extensions_browser_client.h
@@ -34,6 +34,7 @@
@@ -33,6 +33,7 @@
#include "url/gurl.h"
class ExtensionFunctionRegistry;
@ -214,7 +214,7 @@ index 7e5c2918e273f..f00799f9e0dad 100644
class PrefService;
namespace base {
@@ -82,6 +83,7 @@ class ComponentExtensionResourceManager;
@@ -81,6 +82,7 @@ class ComponentExtensionResourceManager;
class Extension;
class ExtensionCache;
class ExtensionError;
@ -238,7 +238,7 @@ index 7e5c2918e273f..f00799f9e0dad 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 b86a71429eb33..9f7d190975605 100644
index c9793db28037b..e5f017bf2f2f8 100644
--- extensions/browser/process_manager.cc
+++ extensions/browser/process_manager.cc
@@ -353,9 +353,17 @@ bool ProcessManager::CreateBackgroundHost(const Extension* extension,

View File

@ -12,7 +12,7 @@ index e6f5cbc9c49f9..f64ed7ae77ea1 100644
# https://crbug.com/474506.
"//clank/java/BUILD.gn",
diff --git BUILD.gn BUILD.gn
index 357f7117f8737..724ddd9d61110 100644
index 3ede70d5d17be..764ce45183919 100644
--- BUILD.gn
+++ BUILD.gn
@@ -20,6 +20,7 @@ import("//build/config/sanitizers/sanitizers.gni")
@ -76,7 +76,7 @@ index 1da479dd5eebc..ff9c7e467997c 100644
- visual_studio_runtime_dirs = []
}
diff --git chrome/chrome_paks.gni chrome/chrome_paks.gni
index 8acc61076fcf6..4887fe263669c 100644
index 87e4b167b6a55..6dafb9ac4ed94 100644
--- chrome/chrome_paks.gni
+++ chrome/chrome_paks.gni
@@ -5,6 +5,7 @@
@ -87,7 +87,7 @@ index 8acc61076fcf6..4887fe263669c 100644
import("//chrome/browser/buildflags.gni")
import("//chrome/common/features.gni")
import("//components/compose/features.gni")
@@ -80,6 +81,10 @@ template("chrome_repack_percent") {
@@ -82,6 +83,10 @@ template("chrome_repack_percent") {
"//ui/chromeos/resources",
]
}
@ -99,7 +99,7 @@ index 8acc61076fcf6..4887fe263669c 100644
sources += [ "$root_gen_dir/extensions/extensions_browser_resources_${percent}_percent.pak" ]
deps += [ "//extensions:extensions_browser_resources" ]
diff --git chrome/chrome_repack_locales.gni chrome/chrome_repack_locales.gni
index 064c39ffe307e..c430ab71419cb 100644
index 2f5fedb03bc6b..b3b7126aa0f42 100644
--- chrome/chrome_repack_locales.gni
+++ chrome/chrome_repack_locales.gni
@@ -6,6 +6,7 @@ import("//build/config/chrome_build.gni")
@ -110,7 +110,7 @@ index 064c39ffe307e..c430ab71419cb 100644
import("//extensions/buildflags/buildflags.gni")
import("//tools/grit/repack.gni")
@@ -107,6 +108,10 @@ template("chrome_repack_locales") {
@@ -105,6 +106,10 @@ template("chrome_repack_locales") {
source_patterns += [ "${root_gen_dir}/components/strings/search_engine_descriptions_strings_" ]
deps += [ "//components/strings:search_engine_descriptions_strings" ]
}
@ -122,7 +122,7 @@ index 064c39ffe307e..c430ab71419cb 100644
source_patterns +=
[ "${root_gen_dir}/extensions/strings/extensions_strings_" ]
diff --git chrome/installer/mini_installer/BUILD.gn chrome/installer/mini_installer/BUILD.gn
index b94944f6d5527..eecf0673e027e 100644
index 17c3d731e269b..e2caaf2934cdd 100644
--- chrome/installer/mini_installer/BUILD.gn
+++ chrome/installer/mini_installer/BUILD.gn
@@ -7,6 +7,7 @@ import("//build/config/features.gni")

View File

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

View File

@ -93,10 +93,10 @@ index f62df6eb7d12b..68f78b5e8bce0 100644
static bool kIsForcedHighContrast =
base::CommandLine::ForCurrentProcess()->HasSwitch(
diff --git ui/native_theme/native_theme.h ui/native_theme/native_theme.h
index 74b3f56ec91a8..78e548bbea4de 100644
index fc32dfb0de44f..44ca8103247b1 100644
--- ui/native_theme/native_theme.h
+++ ui/native_theme/native_theme.h
@@ -597,6 +597,9 @@ class NATIVE_THEME_EXPORT NativeTheme {
@@ -587,6 +587,9 @@ class NATIVE_THEME_EXPORT NativeTheme {
// Whether dark mode is forced via command-line flag.
static bool IsForcedDarkMode();
@ -129,7 +129,7 @@ index 9ca3120cfe3ac..c29c17330a7e5 100644
theme->NotifyOnNativeThemeUpdated();
}];
diff --git ui/native_theme/native_theme_win.cc ui/native_theme/native_theme_win.cc
index 4c922cce6fe89..196fc0a6c07b2 100644
index 547872076d126..14d0e817f3243 100644
--- ui/native_theme/native_theme_win.cc
+++ ui/native_theme/native_theme_win.cc
@@ -673,14 +673,17 @@ bool NativeThemeWin::ShouldUseDarkColors() const {

View File

@ -1,5 +1,5 @@
diff --git content/browser/child_process_launcher_helper_linux.cc content/browser/child_process_launcher_helper_linux.cc
index 8f4f33fd83ef6..be3c8f5ff50c1 100644
index add20a2f81d66..97071092ff768 100644
--- content/browser/child_process_launcher_helper_linux.cc
+++ content/browser/child_process_launcher_helper_linux.cc
@@ -191,7 +191,7 @@ ZygoteCommunication* ChildProcessLauncherHelper::GetZygoteForLaunch() {

View File

@ -1,8 +1,8 @@
diff --git ui/accessibility/platform/BUILD.gn ui/accessibility/platform/BUILD.gn
index fc99800e70eb2..23d38bf15155f 100644
index 3e295499c9ddf..f9109fecb2f49 100644
--- ui/accessibility/platform/BUILD.gn
+++ ui/accessibility/platform/BUILD.gn
@@ -290,6 +290,10 @@ component("platform") {
@@ -305,6 +305,10 @@ component("platform") {
if (use_gio) {
configs += [ "//build/linux:gio_config" ]
}

View File

@ -1,5 +1,5 @@
diff --git ui/gtk/gtk_ui.cc ui/gtk/gtk_ui.cc
index ab8f0d6b545b2..c4bd035f1cec4 100644
index 7b81a752ffad2..24297039e23d4 100644
--- ui/gtk/gtk_ui.cc
+++ ui/gtk/gtk_ui.cc
@@ -26,6 +26,7 @@
@ -27,7 +27,7 @@ index ab8f0d6b545b2..c4bd035f1cec4 100644
&GtkUi::OnCursorThemeNameChanged);
connect(settings, "notify::gtk-cursor-theme-size",
diff --git ui/ozone/platform/x11/ozone_platform_x11.cc ui/ozone/platform/x11/ozone_platform_x11.cc
index 417f9f92d4307..388510591d913 100644
index 39e18820db0d0..0971f5b63d23d 100644
--- ui/ozone/platform/x11/ozone_platform_x11.cc
+++ ui/ozone/platform/x11/ozone_platform_x11.cc
@@ -64,6 +64,8 @@ namespace ui {

View File

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

View File

@ -98,10 +98,10 @@ index aa43742055b04..e84f21ab963cc 100644
// it will get the locale that should be used potentially from other sources,
// depending on the platform (e.g. the OS locale on Mac).
diff --git ui/base/l10n/l10n_util.cc ui/base/l10n/l10n_util.cc
index efb5dd2cfe061..965106e026fa3 100644
index e7beb8277966b..63f2680128e72 100644
--- ui/base/l10n/l10n_util.cc
+++ ui/base/l10n/l10n_util.cc
@@ -501,25 +501,7 @@ bool CheckAndResolveLocale(const std::string& locale,
@@ -502,25 +502,7 @@ bool CheckAndResolveLocale(const std::string& locale,
return CheckAndResolveLocale(locale, resolved_locale, /*perform_io=*/true);
}
@ -128,7 +128,7 @@ index efb5dd2cfe061..965106e026fa3 100644
std::string resolved_locale;
std::vector<std::string> candidates;
@@ -584,15 +566,6 @@ std::string GetApplicationLocaleInternalNonMac(const std::string& pref_locale) {
@@ -585,15 +567,6 @@ std::string GetApplicationLocaleInternalNonMac(const std::string& pref_locale) {
return std::string();
}

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 3efb90bd0027a..e9b5110fe739c 100644
index b87138e45c207..4542996484462 100644
--- chrome/browser/ui/views/profiles/profile_menu_view_base.cc
+++ chrome/browser/ui/views/profiles/profile_menu_view_base.cc
@@ -1170,8 +1170,8 @@ int ProfileMenuViewBase::GetMaxHeight() const {
@@ -1167,8 +1167,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 0c9e9a86a0242..dc80361d0c9a0 100644
index 1cb6eb60ef419..b0bdc60cebc0d 100644
--- content/app_shim_remote_cocoa/render_widget_host_view_cocoa.mm
+++ content/app_shim_remote_cocoa/render_widget_host_view_cocoa.mm
@@ -165,6 +165,13 @@ void ExtractUnderlines(NSAttributedString* string,
@@ -166,6 +166,13 @@ void ExtractUnderlines(NSAttributedString* string,
// RenderWidgetHostViewCocoa ---------------------------------------------------
@ -16,7 +16,7 @@ index 0c9e9a86a0242..dc80361d0c9a0 100644
// Private methods:
@interface RenderWidgetHostViewCocoa ()
@@ -750,6 +757,14 @@ void ExtractUnderlines(NSAttributedString* string,
@@ -762,6 +769,15 @@ void ExtractUnderlines(NSAttributedString* string,
}
- (BOOL)acceptsFirstMouse:(NSEvent*)theEvent {
@ -28,6 +28,7 @@ index 0c9e9a86a0242..dc80361d0c9a0 100644
+ return NO;
+ }
+ }
return [self acceptsMouseEventsWhenInactive];
+
// Enable "click-through" if mouse clicks are accepted in inactive windows
return [self acceptsMouseEventsOption] > kAcceptMouseEventsInActiveWindow;
}

View File

@ -1,5 +1,5 @@
diff --git base/message_loop/message_pump_win.cc base/message_loop/message_pump_win.cc
index b136708121867..ee2ba2b731291 100644
index 5a48d5b098d86..95ebca554932f 100644
--- base/message_loop/message_pump_win.cc
+++ base/message_loop/message_pump_win.cc
@@ -2,6 +2,7 @@
@ -10,12 +10,12 @@ index b136708121867..ee2ba2b731291 100644
#include "base/message_loop/message_pump_win.h"
#include <winbase.h>
@@ -577,7 +578,17 @@ bool MessagePumpForUI::ProcessNextWindowsMessage() {
@@ -572,7 +573,17 @@ bool MessagePumpForUI::ProcessNextWindowsMessage() {
ctx.event()->set_chrome_message_pump();
msg_pump_data->set_sent_messages_in_queue(more_work_is_plausible);
});
- has_msg = ::PeekMessage(&msg, nullptr, 0, 0, PM_REMOVE) != FALSE;
+
+
+ // We should not process all window messages if we are in the context of an
+ // OS modal loop, i.e. in the context of a windows API call like MessageBox.
+ // This is to ensure that these messages are peeked out by the OS modal loop.
@ -30,7 +30,7 @@ index b136708121867..ee2ba2b731291 100644
}
if (has_msg)
diff --git base/task/current_thread.cc base/task/current_thread.cc
index a93ee7e4213cb..5550158d94de6 100644
index c4f8862b21ccf..c8c80509abc91 100644
--- base/task/current_thread.cc
+++ base/task/current_thread.cc
@@ -51,6 +51,8 @@ void CurrentThread::AddDestructionObserver(
@ -43,7 +43,7 @@ index a93ee7e4213cb..5550158d94de6 100644
current_->RemoveDestructionObserver(destruction_observer);
}
diff --git base/task/current_thread.h base/task/current_thread.h
index 22bf2c90f90a5..2b4b95c130745 100644
index 6e21e7299afbf..c9e12a6e701c2 100644
--- base/task/current_thread.h
+++ base/task/current_thread.h
@@ -163,6 +163,12 @@ class BASE_EXPORT CurrentThread {
@ -59,7 +59,7 @@ index 22bf2c90f90a5..2b4b95c130745 100644
// Enables nested task processing in scope of an upcoming native message loop.
// Some unwanted message loops may occur when using common controls or printer
// functions. Hence, nested task processing is disabled by default to avoid
@@ -227,6 +233,13 @@ class BASE_EXPORT CurrentThread {
@@ -232,6 +238,13 @@ class BASE_EXPORT CurrentThread {
friend class web::WebTaskEnvironment;
raw_ptr<sequence_manager::internal::SequenceManagerImpl> current_;

View File

@ -1,8 +1,8 @@
diff --git base/message_loop/message_pump_apple.mm base/message_loop/message_pump_apple.mm
index 5e9d5f082e2c4..6cc3a5981d55c 100644
index 570a7583512b0..9a38033880604 100644
--- base/message_loop/message_pump_apple.mm
+++ base/message_loop/message_pump_apple.mm
@@ -759,7 +759,8 @@ void MessagePumpUIApplication::Detach() {
@@ -764,7 +764,8 @@ void MessagePumpUIApplication::Detach() {
#else
ScopedPumpMessagesInPrivateModes::ScopedPumpMessagesInPrivateModes() {
@ -12,7 +12,7 @@ index 5e9d5f082e2c4..6cc3a5981d55c 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.
@@ -770,7 +771,8 @@ ScopedPumpMessagesInPrivateModes::ScopedPumpMessagesInPrivateModes() {
@@ -775,7 +776,8 @@ ScopedPumpMessagesInPrivateModes::ScopedPumpMessagesInPrivateModes() {
}
ScopedPumpMessagesInPrivateModes::~ScopedPumpMessagesInPrivateModes() {

View File

@ -1,8 +1,8 @@
diff --git components/metrics/persistent_system_profile.cc components/metrics/persistent_system_profile.cc
index f594c075834e3..2165b9196ce03 100644
index 768c933cd13c6..78d86b97e64bf 100644
--- components/metrics/persistent_system_profile.cc
+++ components/metrics/persistent_system_profile.cc
@@ -394,6 +394,10 @@ bool PersistentSystemProfile::GetSystemProfile(
@@ -395,6 +395,10 @@ bool PersistentSystemProfile::GetSystemProfile(
return true;
}
@ -14,7 +14,7 @@ index f594c075834e3..2165b9196ce03 100644
void PersistentSystemProfile::MergeUpdateRecords(
const base::PersistentMemoryAllocator& memory_allocator,
diff --git components/metrics/persistent_system_profile.h components/metrics/persistent_system_profile.h
index fc173051fb8c1..3fcc43880e89d 100644
index 5ef2afa1183a6..a2e00202f7b42 100644
--- components/metrics/persistent_system_profile.h
+++ components/metrics/persistent_system_profile.h
@@ -64,6 +64,10 @@ class PersistentSystemProfile {

View File

@ -1,5 +1,5 @@
diff --git content/browser/web_contents/web_contents_view.h content/browser/web_contents/web_contents_view.h
index 285dc38950991..326646bb585da 100644
index 0cc1db9645f04..ab2ae8c744278 100644
--- content/browser/web_contents/web_contents_view.h
+++ content/browser/web_contents/web_contents_view.h
@@ -26,7 +26,7 @@ struct DropData;
@ -12,10 +12,10 @@ index 285dc38950991..326646bb585da 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 bd8b5ddfd8659..767c0ec89ef7a 100644
index 8a77da73784c8..9ca31537809a3 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
@@ -205,6 +205,8 @@ void MimeHandlerViewGuest::CreateWebContents(
@@ -204,6 +204,8 @@ void MimeHandlerViewGuest::CreateWebContents(
WebContents::CreateParams params(browser_context(),
guest_site_instance.get());
params.guest_delegate = this;
@ -25,7 +25,7 @@ index bd8b5ddfd8659..767c0ec89ef7a 100644
WebContents::CreateWithSessionStorage(
params, owner_web_contents()
diff --git extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest_delegate.h extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest_delegate.h
index 7f59e7925084e..e3e69dc6d3a43 100644
index 2fb8a60c1f56d..edd275135e60d 100644
--- extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest_delegate.h
+++ extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest_delegate.h
@@ -7,6 +7,8 @@
@ -35,9 +35,9 @@ index 7f59e7925084e..e3e69dc6d3a43 100644
+#include "content/public/browser/web_contents.h"
+
namespace content {
class BrowserContext;
class RenderFrameHost;
struct ContextMenuParams;
@@ -25,6 +27,10 @@ class MimeHandlerViewGuestDelegate {
@@ -26,6 +28,10 @@ class MimeHandlerViewGuestDelegate {
virtual ~MimeHandlerViewGuestDelegate() {}

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 b7bc620562e32..0d1f7a049dc3b 100644
index be520e63b503c..74f842d07499c 100644
--- net/url_request/url_request_http_job.cc
+++ net/url_request/url_request_http_job.cc
@@ -1907,7 +1907,8 @@ bool URLRequestHttpJob::ShouldAddCookieHeader() const {
@@ -1905,7 +1905,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,10 +24,10 @@ index b7bc620562e32..0d1f7a049dc3b 100644
bool URLRequestHttpJob::ShouldRecordPartitionedCookieUsage() const {
diff --git services/network/public/cpp/resource_request.cc services/network/public/cpp/resource_request.cc
index 4e698635af5ac..2f1ffdcd34f3b 100644
index 3d4cc0dbf277e..eddba6b5a8471 100644
--- services/network/public/cpp/resource_request.cc
+++ services/network/public/cpp/resource_request.cc
@@ -325,7 +325,8 @@ bool ResourceRequest::EqualsForTesting(const ResourceRequest& request) const {
@@ -329,7 +329,8 @@ bool ResourceRequest::EqualsForTesting(const ResourceRequest& request) const {
}
bool ResourceRequest::SendsCookies() 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 cb651df6d5c67..bf2f7ef2b9319 100644
index a3ec8894015a8..eec36b0183bce 100644
--- net/test/embedded_test_server/embedded_test_server.cc
+++ net/test/embedded_test_server/embedded_test_server.cc
@@ -1020,7 +1020,7 @@ bool EmbeddedTestServer::PostTaskToIOThreadAndWait(base::OnceClosure closure) {
@@ -1041,7 +1041,7 @@ bool EmbeddedTestServer::PostTaskToIOThreadAndWait(base::OnceClosure closure) {
if (!base::CurrentThread::Get())
temporary_loop = std::make_unique<base::SingleThreadTaskExecutor>();
@ -11,7 +11,7 @@ index cb651df6d5c67..bf2f7ef2b9319 100644
if (!io_thread_->task_runner()->PostTaskAndReply(
FROM_HERE, std::move(closure), run_loop.QuitClosure())) {
return false;
@@ -1047,7 +1047,7 @@ bool EmbeddedTestServer::PostTaskToIOThreadAndWaitWithResult(
@@ -1068,7 +1068,7 @@ bool EmbeddedTestServer::PostTaskToIOThreadAndWaitWithResult(
if (!base::CurrentThread::Get())
temporary_loop = std::make_unique<base::SingleThreadTaskExecutor>();

View File

@ -13,10 +13,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 6902bb7ea90f7..c57b43fe0fce2 100644
index 7fba410705048..7ce1d8a5eeb7f 100644
--- content/browser/renderer_host/render_widget_host_impl.cc
+++ content/browser/renderer_host/render_widget_host_impl.cc
@@ -3216,6 +3216,11 @@ void RenderWidgetHostImpl::OnInvalidInputEventSource() {
@@ -3292,6 +3292,11 @@ void RenderWidgetHostImpl::OnInvalidInputEventSource() {
GetProcess(), bad_message::INPUT_ROUTER_INVALID_EVENT_SOURCE);
}
@ -29,10 +29,10 @@ index 6902bb7ea90f7..c57b43fe0fce2 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 b3218a69a1d9e..a7b8e6c20659a 100644
index dee4fb6b79285..fd3eaef2b6972 100644
--- content/browser/renderer_host/render_widget_host_impl.h
+++ content/browser/renderer_host/render_widget_host_impl.h
@@ -806,6 +806,7 @@ class CONTENT_EXPORT RenderWidgetHostImpl
@@ -811,6 +811,7 @@ class CONTENT_EXPORT RenderWidgetHostImpl
void ProgressFlingIfNeeded(base::TimeTicks current_time);
void StopFling();
@ -72,10 +72,10 @@ index e8ee63f3abc2e..765ea358e093a 100644
} // namespace content
diff --git content/common/input/render_input_router.h content/common/input/render_input_router.h
index 9e94dc720f9c9..c3ad0d7d2e6c2 100644
index cab10100a369d..d8f3be04bfeba 100644
--- content/common/input/render_input_router.h
+++ content/common/input/render_input_router.h
@@ -60,6 +60,7 @@ class CONTENT_EXPORT RenderInputRouter : public InputRouterImplClient {
@@ -61,6 +61,7 @@ class CONTENT_EXPORT RenderInputRouter : public InputRouterImplClient {
InputRouter* input_router() { return input_router_.get(); }
RenderInputRouterDelegate* delegate() { return delegate_; }

Some files were not shown because too many files have changed in this diff Show More