mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Update to Chromium version 122.0.6261.0 (#1250580)
Frame identifiers have changed from int64_t to string type. This is due to https://crbug.com/1502660 which removes access to frame routing IDs in the renderer process. New cross-process frame identifiers are 160-bit values (32-bit child process ID + 128-bit local frame token) and most easily represented as strings. All other frame-related expectations and behaviors remain the same.
This commit is contained in:
@ -1,5 +1,5 @@
|
||||
diff --git chrome/browser/ui/browser_command_controller.cc chrome/browser/ui/browser_command_controller.cc
|
||||
index 7d57988659286..576550dd75111 100644
|
||||
index 5664d44624283..e025126ed235f 100644
|
||||
--- chrome/browser/ui/browser_command_controller.cc
|
||||
+++ chrome/browser/ui/browser_command_controller.cc
|
||||
@@ -400,6 +400,7 @@ bool BrowserCommandController::ExecuteCommandWithDisposition(
|
||||
@ -41,10 +41,10 @@ index 7d57988659286..576550dd75111 100644
|
||||
|
||||
bool BrowserCommandController::IsWebAppOrCustomTab() const {
|
||||
diff --git chrome/browser/ui/toolbar/app_menu_model.cc chrome/browser/ui/toolbar/app_menu_model.cc
|
||||
index 6ce427cb564af..8a59dc84c75ec 100644
|
||||
index bb41ecd06518b..ab7d617e419ad 100644
|
||||
--- chrome/browser/ui/toolbar/app_menu_model.cc
|
||||
+++ chrome/browser/ui/toolbar/app_menu_model.cc
|
||||
@@ -596,6 +596,57 @@ SaveAndShareSubMenuModel::SaveAndShareSubMenuModel(
|
||||
@@ -604,6 +604,57 @@ SaveAndShareSubMenuModel::SaveAndShareSubMenuModel(
|
||||
}
|
||||
}
|
||||
|
||||
@ -102,7 +102,7 @@ index 6ce427cb564af..8a59dc84c75ec 100644
|
||||
} // namespace
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
@@ -1481,7 +1532,7 @@ bool AppMenuModel::IsCommandIdChecked(int command_id) const {
|
||||
@@ -1470,7 +1521,7 @@ bool AppMenuModel::IsCommandIdChecked(int command_id) const {
|
||||
return false;
|
||||
}
|
||||
|
||||
@ -111,7 +111,7 @@ index 6ce427cb564af..8a59dc84c75ec 100644
|
||||
GlobalError* error =
|
||||
GlobalErrorServiceFactory::GetForProfile(browser_->profile())
|
||||
->GetGlobalErrorByMenuItemCommandID(command_id);
|
||||
@@ -1496,6 +1547,30 @@ bool AppMenuModel::IsCommandIdEnabled(int command_id) const {
|
||||
@@ -1485,6 +1536,30 @@ bool AppMenuModel::IsCommandIdEnabled(int command_id) const {
|
||||
}
|
||||
}
|
||||
|
||||
@ -142,7 +142,7 @@ index 6ce427cb564af..8a59dc84c75ec 100644
|
||||
bool AppMenuModel::IsCommandIdAlerted(int command_id) const {
|
||||
if (command_id == IDC_VIEW_PASSWORDS ||
|
||||
command_id == IDC_SHOW_PASSWORD_MANAGER) {
|
||||
@@ -1689,11 +1764,15 @@ void AppMenuModel::Build() {
|
||||
@@ -1652,11 +1727,15 @@ void AppMenuModel::Build() {
|
||||
kDefaultIconSize));
|
||||
}
|
||||
|
||||
@ -163,7 +163,7 @@ index 6ce427cb564af..8a59dc84c75ec 100644
|
||||
|
||||
AddItemWithStringId(IDC_PRINT, IDS_PRINT);
|
||||
|
||||
@@ -1799,9 +1878,13 @@ void AppMenuModel::Build() {
|
||||
@@ -1762,9 +1841,13 @@ void AppMenuModel::Build() {
|
||||
kMoreToolsMenuItem);
|
||||
|
||||
if (!features::IsChromeRefresh2023()) {
|
||||
@ -180,7 +180,7 @@ index 6ce427cb564af..8a59dc84c75ec 100644
|
||||
}
|
||||
|
||||
if (!features::IsChromeRefresh2023()) {
|
||||
@@ -1889,6 +1972,11 @@ void AppMenuModel::Build() {
|
||||
@@ -1853,6 +1936,11 @@ void AppMenuModel::Build() {
|
||||
SetCommandIcon(this, IDC_EXIT, kExitMenuIcon);
|
||||
}
|
||||
|
||||
@ -193,7 +193,7 @@ index 6ce427cb564af..8a59dc84c75ec 100644
|
||||
}
|
||||
|
||||
diff --git chrome/browser/ui/toolbar/app_menu_model.h chrome/browser/ui/toolbar/app_menu_model.h
|
||||
index 55425f15d49fa..06cb8ed2acaa1 100644
|
||||
index d7c9df2e12df2..5dd6080454806 100644
|
||||
--- chrome/browser/ui/toolbar/app_menu_model.h
|
||||
+++ chrome/browser/ui/toolbar/app_menu_model.h
|
||||
@@ -215,6 +215,7 @@ class AppMenuModel : public ui::SimpleMenuModel,
|
||||
@ -205,8 +205,8 @@ index 55425f15d49fa..06cb8ed2acaa1 100644
|
||||
bool IsElementIdAlerted(ui::ElementIdentifier element_id) const override;
|
||||
bool GetAcceleratorForCommandId(int command_id,
|
||||
@@ -256,6 +257,8 @@ class AppMenuModel : public ui::SimpleMenuModel,
|
||||
absl::optional<safety_hub::SafetyHubModuleType> expected_module =
|
||||
absl::nullopt);
|
||||
safety_hub::SafetyHubModuleType sh_module,
|
||||
int event_flags);
|
||||
|
||||
+ bool IsCommandIdEnabledInternal(int command_id) const;
|
||||
+
|
||||
@ -231,7 +231,7 @@ index 59024587ef6b7..0c30aa71768cf 100644
|
||||
|
||||
void FindBarHost::RegisterAccelerators() {
|
||||
diff --git chrome/browser/ui/views/frame/browser_frame.cc chrome/browser/ui/views/frame/browser_frame.cc
|
||||
index bb4b3821bcfda..4014f61a7057f 100644
|
||||
index a52bb8913d37f..dd5030f9bfb74 100644
|
||||
--- chrome/browser/ui/views/frame/browser_frame.cc
|
||||
+++ chrome/browser/ui/views/frame/browser_frame.cc
|
||||
@@ -114,15 +114,23 @@ ui::ColorProviderKey::SchemeVariant GetSchemeVariant(
|
||||
@ -330,7 +330,7 @@ index bb4b3821bcfda..4014f61a7057f 100644
|
||||
chrome::SaveWindowWorkspace(browser_view_->browser(), GetWorkspace());
|
||||
chrome::SaveWindowVisibleOnAllWorkspaces(browser_view_->browser(),
|
||||
IsVisibleOnAllWorkspaces());
|
||||
@@ -478,6 +510,8 @@ void BrowserFrame::OnNativeThemeUpdated(ui::NativeTheme* observed_theme) {
|
||||
@@ -483,6 +515,8 @@ void BrowserFrame::OnNativeThemeUpdated(ui::NativeTheme* observed_theme) {
|
||||
|
||||
ui::ColorProviderKey BrowserFrame::GetColorProviderKey() const {
|
||||
auto key = Widget::GetColorProviderKey();
|
||||
@ -339,7 +339,7 @@ index bb4b3821bcfda..4014f61a7057f 100644
|
||||
|
||||
key.app_controller = browser_view_->browser()->app_controller();
|
||||
|
||||
@@ -632,5 +666,8 @@ bool BrowserFrame::RegenerateFrameOnThemeChange(
|
||||
@@ -637,5 +671,8 @@ bool BrowserFrame::RegenerateFrameOnThemeChange(
|
||||
}
|
||||
|
||||
bool BrowserFrame::IsIncognitoBrowser() const {
|
||||
@ -349,10 +349,10 @@ index bb4b3821bcfda..4014f61a7057f 100644
|
||||
return browser_view_->browser()->profile()->IsIncognitoProfile();
|
||||
}
|
||||
diff --git chrome/browser/ui/views/frame/browser_frame.h chrome/browser/ui/views/frame/browser_frame.h
|
||||
index 0c231b6ac5b01..6b5af98e18e42 100644
|
||||
index 2e973c9e279b0..12b62efb8071f 100644
|
||||
--- chrome/browser/ui/views/frame/browser_frame.h
|
||||
+++ chrome/browser/ui/views/frame/browser_frame.h
|
||||
@@ -61,7 +61,9 @@ enum class TabDragKind {
|
||||
@@ -58,7 +58,9 @@ enum class TabDragKind {
|
||||
// This is a virtual interface that allows system specific browser frames.
|
||||
class BrowserFrame : public views::Widget, public views::ContextMenuController {
|
||||
public:
|
||||
@ -363,10 +363,10 @@ index 0c231b6ac5b01..6b5af98e18e42 100644
|
||||
BrowserFrame(const BrowserFrame&) = delete;
|
||||
BrowserFrame& operator=(const BrowserFrame&) = delete;
|
||||
diff --git chrome/browser/ui/views/frame/browser_view.cc chrome/browser/ui/views/frame/browser_view.cc
|
||||
index c74a820ce00ad..0c3b3bd49e5b7 100644
|
||||
index e2827eb98518f..3e33205a91f1b 100644
|
||||
--- chrome/browser/ui/views/frame/browser_view.cc
|
||||
+++ chrome/browser/ui/views/frame/browser_view.cc
|
||||
@@ -342,11 +342,10 @@ using content::NativeWebKeyboardEvent;
|
||||
@@ -346,11 +346,10 @@ using content::NativeWebKeyboardEvent;
|
||||
using content::WebContents;
|
||||
using web_modal::WebContentsModalDialogHost;
|
||||
|
||||
@ -381,7 +381,7 @@ index c74a820ce00ad..0c3b3bd49e5b7 100644
|
||||
|
||||
#if BUILDFLAG(IS_CHROMEOS_ASH)
|
||||
// UMA histograms that record animation smoothness for tab loading animation.
|
||||
@@ -700,6 +699,14 @@ class BrowserViewLayoutDelegateImpl : public BrowserViewLayoutDelegate {
|
||||
@@ -677,6 +676,14 @@ class BrowserViewLayoutDelegateImpl : public BrowserViewLayoutDelegate {
|
||||
return browser_view_->frame()->GetTopInset() - browser_view_->y();
|
||||
}
|
||||
|
||||
@ -396,7 +396,7 @@ index c74a820ce00ad..0c3b3bd49e5b7 100644
|
||||
bool IsToolbarVisible() const override {
|
||||
return browser_view_->IsToolbarVisible();
|
||||
}
|
||||
@@ -861,11 +868,21 @@ class BrowserView::AccessibilityModeObserver : public ui::AXModeObserver {
|
||||
@@ -835,11 +842,21 @@ class BrowserView::AccessibilityModeObserver : public ui::AXModeObserver {
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
// BrowserView, public:
|
||||
|
||||
@ -417,9 +417,9 @@ index c74a820ce00ad..0c3b3bd49e5b7 100644
|
||||
+ browser_ = std::move(browser);
|
||||
+
|
||||
// Store the actions so that the access is available for other classes.
|
||||
if (base::FeatureList::IsEnabled(features::kSidePanelPinning)) {
|
||||
if (features::IsSidePanelPinningEnabled()) {
|
||||
browser_->SetUserData(BrowserActions::UserDataKey(),
|
||||
@@ -962,8 +979,15 @@ BrowserView::BrowserView(std::unique_ptr<Browser> browser)
|
||||
@@ -933,8 +950,15 @@ BrowserView::BrowserView(std::unique_ptr<Browser> browser)
|
||||
contents_container->SetLayoutManager(std::make_unique<ContentsLayoutManager>(
|
||||
devtools_web_view_, contents_web_view_));
|
||||
|
||||
@ -437,7 +437,7 @@ index c74a820ce00ad..0c3b3bd49e5b7 100644
|
||||
|
||||
contents_separator_ =
|
||||
top_container_->AddChildView(std::make_unique<ContentsSeparator>());
|
||||
@@ -1037,7 +1061,9 @@ BrowserView::~BrowserView() {
|
||||
@@ -1008,7 +1032,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.
|
||||
@ -447,7 +447,7 @@ index c74a820ce00ad..0c3b3bd49e5b7 100644
|
||||
|
||||
// Stop the animation timer explicitly here to avoid running it in a nested
|
||||
// message loop, which may run by Browser destructor.
|
||||
@@ -1051,12 +1077,14 @@ BrowserView::~BrowserView() {
|
||||
@@ -1022,12 +1048,14 @@ BrowserView::~BrowserView() {
|
||||
// child views and it is an observer for avatar toolbar button if any.
|
||||
autofill_bubble_handler_.reset();
|
||||
|
||||
@ -462,7 +462,7 @@ index c74a820ce00ad..0c3b3bd49e5b7 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.
|
||||
@@ -1074,7 +1102,9 @@ BrowserView::~BrowserView() {
|
||||
@@ -1045,7 +1073,9 @@ BrowserView::~BrowserView() {
|
||||
|
||||
// `SidePanelUI::RemoveSidePanelUIForBrowser()` deletes the
|
||||
// SidePanelCoordinator.
|
||||
@ -472,7 +472,7 @@ index c74a820ce00ad..0c3b3bd49e5b7 100644
|
||||
}
|
||||
|
||||
// static
|
||||
@@ -1949,9 +1979,14 @@ void BrowserView::OnExclusiveAccessUserInput() {
|
||||
@@ -1966,9 +1996,14 @@ void BrowserView::OnExclusiveAccessUserInput() {
|
||||
|
||||
bool BrowserView::ShouldHideUIForFullscreen() const {
|
||||
// Immersive mode needs UI for the slide-down top panel.
|
||||
@ -488,7 +488,7 @@ index c74a820ce00ad..0c3b3bd49e5b7 100644
|
||||
return frame_->GetFrameView()->ShouldHideTopUIForFullscreen();
|
||||
}
|
||||
|
||||
@@ -3060,7 +3095,8 @@ DownloadShelf* BrowserView::GetDownloadShelf() {
|
||||
@@ -3083,7 +3118,8 @@ DownloadShelf* BrowserView::GetDownloadShelf() {
|
||||
}
|
||||
|
||||
DownloadBubbleUIController* BrowserView::GetDownloadBubbleUIController() {
|
||||
@ -498,7 +498,7 @@ index c74a820ce00ad..0c3b3bd49e5b7 100644
|
||||
if (auto* download_button = toolbar_button_provider_->GetDownloadButton())
|
||||
return download_button->bubble_controller();
|
||||
return nullptr;
|
||||
@@ -3611,7 +3647,8 @@ void BrowserView::ReparentTopContainerForEndOfImmersive() {
|
||||
@@ -3642,7 +3678,8 @@ void BrowserView::ReparentTopContainerForEndOfImmersive() {
|
||||
if (top_container()->parent() == this)
|
||||
return;
|
||||
|
||||
@ -508,7 +508,7 @@ index c74a820ce00ad..0c3b3bd49e5b7 100644
|
||||
top_container()->DestroyLayer();
|
||||
AddChildViewAt(top_container(), 0);
|
||||
EnsureFocusOrder();
|
||||
@@ -4073,11 +4110,38 @@ void BrowserView::GetAccessiblePanes(std::vector<views::View*>* panes) {
|
||||
@@ -4123,11 +4160,38 @@ void BrowserView::GetAccessiblePanes(std::vector<views::View*>* panes) {
|
||||
bool BrowserView::ShouldDescendIntoChildForEventHandling(
|
||||
gfx::NativeView child,
|
||||
const gfx::Point& location) {
|
||||
@ -549,7 +549,7 @@ index c74a820ce00ad..0c3b3bd49e5b7 100644
|
||||
// Draggable regions are defined relative to the web contents.
|
||||
gfx::Point point_in_contents_web_view_coords(location);
|
||||
views::View::ConvertPointToTarget(GetWidget()->GetRootView(),
|
||||
@@ -4086,7 +4150,7 @@ bool BrowserView::ShouldDescendIntoChildForEventHandling(
|
||||
@@ -4136,7 +4200,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.
|
||||
@ -558,7 +558,7 @@ index c74a820ce00ad..0c3b3bd49e5b7 100644
|
||||
point_in_contents_web_view_coords.x(),
|
||||
point_in_contents_web_view_coords.y()) ||
|
||||
WidgetOwnedByAnchorContainsPoint(point_in_contents_web_view_coords);
|
||||
@@ -4194,8 +4258,10 @@ void BrowserView::Layout() {
|
||||
@@ -4247,8 +4311,10 @@ void BrowserView::Layout() {
|
||||
|
||||
// TODO(jamescook): Why was this in the middle of layout code?
|
||||
toolbar_->location_bar()->omnibox_view()->SetFocusBehavior(
|
||||
@ -569,9 +569,9 @@ index c74a820ce00ad..0c3b3bd49e5b7 100644
|
||||
+ if (frame()->GetFrameView())
|
||||
+ frame()->GetFrameView()->UpdateMinimumSize();
|
||||
|
||||
#if BUILDFLAG(IS_CHROMEOS_ASH)
|
||||
// In chromeOS ash we round the bottom two corners of the browser frame by
|
||||
@@ -4273,6 +4339,11 @@ void BrowserView::AddedToWidget() {
|
||||
// Some of the situations when the BrowserView is laid out are:
|
||||
// - Enter/exit immersive fullscreen mode.
|
||||
@@ -4314,6 +4380,11 @@ void BrowserView::AddedToWidget() {
|
||||
SetThemeProfileForWindow(GetNativeWindow(), browser_->profile());
|
||||
#endif
|
||||
|
||||
@ -583,7 +583,7 @@ index c74a820ce00ad..0c3b3bd49e5b7 100644
|
||||
toolbar_->Init();
|
||||
|
||||
// TODO(pbos): Investigate whether the side panels should be creatable when
|
||||
@@ -4321,13 +4392,9 @@ void BrowserView::AddedToWidget() {
|
||||
@@ -4362,13 +4433,9 @@ void BrowserView::AddedToWidget() {
|
||||
|
||||
EnsureFocusOrder();
|
||||
|
||||
@ -599,7 +599,7 @@ index c74a820ce00ad..0c3b3bd49e5b7 100644
|
||||
using_native_frame_ = frame_->ShouldUseNativeFrame();
|
||||
|
||||
MaybeInitializeWebUITabStrip();
|
||||
@@ -4744,7 +4811,8 @@ void BrowserView::ProcessFullscreen(bool fullscreen,
|
||||
@@ -4793,7 +4860,8 @@ void BrowserView::ProcessFullscreen(bool fullscreen,
|
||||
// Undo our anti-jankiness hacks and force a re-layout.
|
||||
in_process_fullscreen_ = false;
|
||||
ToolbarSizeChanged(false);
|
||||
@ -609,7 +609,7 @@ index c74a820ce00ad..0c3b3bd49e5b7 100644
|
||||
}
|
||||
|
||||
bool BrowserView::ShouldUseImmersiveFullscreenForUrl(const GURL& url) const {
|
||||
@@ -5133,6 +5201,8 @@ Profile* BrowserView::GetProfile() {
|
||||
@@ -5191,6 +5259,8 @@ Profile* BrowserView::GetProfile() {
|
||||
}
|
||||
|
||||
void BrowserView::UpdateUIForTabFullscreen() {
|
||||
@ -618,7 +618,7 @@ index c74a820ce00ad..0c3b3bd49e5b7 100644
|
||||
frame()->GetFrameView()->UpdateFullscreenTopUI();
|
||||
}
|
||||
|
||||
@@ -5155,6 +5225,8 @@ void BrowserView::HideDownloadShelf() {
|
||||
@@ -5213,6 +5283,8 @@ void BrowserView::HideDownloadShelf() {
|
||||
}
|
||||
|
||||
bool BrowserView::CanUserExitFullscreen() const {
|
||||
@ -628,13 +628,13 @@ index c74a820ce00ad..0c3b3bd49e5b7 100644
|
||||
}
|
||||
|
||||
diff --git chrome/browser/ui/views/frame/browser_view.h chrome/browser/ui/views/frame/browser_view.h
|
||||
index 2e4054890db75..1a518ba936fd1 100644
|
||||
index f3f5944785e5e..ec369e0fb2fe1 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,
|
||||
kUnknown
|
||||
};
|
||||
@@ -127,11 +127,16 @@ class BrowserView : public BrowserWindow,
|
||||
METADATA_HEADER(BrowserView, views::ClientView)
|
||||
|
||||
public:
|
||||
+ BrowserView();
|
||||
explicit BrowserView(std::unique_ptr<Browser> browser);
|
||||
+ void InitBrowser(std::unique_ptr<Browser> browser);
|
||||
@ -648,9 +648,9 @@ index 2e4054890db75..1a518ba936fd1 100644
|
||||
void set_frame(BrowserFrame* frame) {
|
||||
frame_ = frame;
|
||||
paint_as_active_subscription_ =
|
||||
@@ -832,6 +837,9 @@ class BrowserView : public BrowserWindow,
|
||||
// TopContainerBackground::PaintThemeCustomImage for details.
|
||||
gfx::Point GetThemeOffsetFromBrowserView() const;
|
||||
@@ -839,6 +844,9 @@ class BrowserView : public BrowserWindow,
|
||||
const gfx::Rect& contents_webview_bounds,
|
||||
const gfx::Rect& local_webview_container_bounds);
|
||||
|
||||
+ protected:
|
||||
+ virtual ToolbarView* OverrideCreateToolbar() { return nullptr; }
|
||||
@ -659,7 +659,7 @@ index 2e4054890db75..1a518ba936fd1 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 5e39a622e391e..1d4504370305f 100644
|
||||
index 0991a57cccfe8..3ed3d43497460 100644
|
||||
--- chrome/browser/ui/views/frame/browser_view_layout.cc
|
||||
+++ chrome/browser/ui/views/frame/browser_view_layout.cc
|
||||
@@ -48,6 +48,10 @@
|
||||
@ -760,13 +760,14 @@ index 29ad5517bd3c9..b0fe093467abc 100644
|
||||
virtual bool IsBookmarkBarVisible() const = 0;
|
||||
virtual bool IsContentsSeparatorEnabled() const = 0;
|
||||
diff --git chrome/browser/ui/views/frame/contents_web_view.cc chrome/browser/ui/views/frame/contents_web_view.cc
|
||||
index 8267a265a8e10..ee08f18e96a34 100644
|
||||
index 71445bfab1824..c77750ea2a820 100644
|
||||
--- chrome/browser/ui/views/frame/contents_web_view.cc
|
||||
+++ chrome/browser/ui/views/frame/contents_web_view.cc
|
||||
@@ -23,6 +23,11 @@
|
||||
ContentsWebView::ContentsWebView(content::BrowserContext* browser_context)
|
||||
@@ -28,6 +28,12 @@ ContentsWebView::ContentsWebView(content::BrowserContext* browser_context)
|
||||
: views::WebView(browser_context),
|
||||
status_bubble_(nullptr) {
|
||||
SetProperty(views::kElementIdentifierKey, kContentsWebViewElementId);
|
||||
+
|
||||
+ // Mouse events on draggable regions will not be handled by the WebView.
|
||||
+ // Avoid the resulting DCHECK in NativeViewHost::OnMousePressed by
|
||||
+ // configuring the NativeViewHost not to process events via the view
|
||||
@ -776,10 +777,10 @@ index 8267a265a8e10..ee08f18e96a34 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 84e2a84c15907..3f010beb931b6 100644
|
||||
index 8f8eae2b243b3..288d584c61548 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
|
||||
@@ -585,6 +585,11 @@ PictureInPictureBrowserFrameView::PictureInPictureBrowserFrameView(
|
||||
@@ -590,6 +590,11 @@ PictureInPictureBrowserFrameView::PictureInPictureBrowserFrameView(
|
||||
frame->GetNativeWindow()->SetEventTargeter(
|
||||
std::make_unique<chromeos::InteriorResizeHandleTargeter>());
|
||||
#endif
|
||||
@ -791,7 +792,7 @@ index 84e2a84c15907..3f010beb931b6 100644
|
||||
}
|
||||
|
||||
PictureInPictureBrowserFrameView::~PictureInPictureBrowserFrameView() {
|
||||
@@ -681,18 +686,42 @@ gfx::Rect PictureInPictureBrowserFrameView::GetWindowBoundsForClientBounds(
|
||||
@@ -686,18 +691,42 @@ gfx::Rect PictureInPictureBrowserFrameView::GetWindowBoundsForClientBounds(
|
||||
|
||||
int PictureInPictureBrowserFrameView::NonClientHitTest(
|
||||
const gfx::Point& point) {
|
||||
@ -842,7 +843,7 @@ index 84e2a84c15907..3f010beb931b6 100644
|
||||
|
||||
// Allow dragging and resizing the window.
|
||||
int window_component = GetHTComponentForFrame(
|
||||
@@ -759,7 +788,8 @@ void PictureInPictureBrowserFrameView::Layout() {
|
||||
@@ -764,7 +793,8 @@ void PictureInPictureBrowserFrameView::Layout() {
|
||||
gfx::Rect content_area = GetLocalBounds();
|
||||
content_area.Inset(FrameBorderInsets());
|
||||
gfx::Rect top_bar = content_area;
|
||||
@ -852,7 +853,7 @@ index 84e2a84c15907..3f010beb931b6 100644
|
||||
top_bar_container_view_->SetBoundsRect(top_bar);
|
||||
#if !BUILDFLAG(IS_ANDROID)
|
||||
if (auto_pip_setting_overlay_) {
|
||||
@@ -1234,7 +1264,8 @@ gfx::Insets PictureInPictureBrowserFrameView::ResizeBorderInsets() const {
|
||||
@@ -1236,7 +1266,8 @@ gfx::Insets PictureInPictureBrowserFrameView::ResizeBorderInsets() const {
|
||||
}
|
||||
|
||||
int PictureInPictureBrowserFrameView::GetTopAreaHeight() const {
|
||||
@ -877,7 +878,7 @@ index b862ceac7225d..9575440a77d67 100644
|
||||
LocationBarView* location_bar_view = browser_view_->GetLocationBarView();
|
||||
CHECK(location_bar_view);
|
||||
diff --git chrome/browser/ui/views/page_action/page_action_icon_controller.cc chrome/browser/ui/views/page_action/page_action_icon_controller.cc
|
||||
index 0e24efef68ace..f1cda2809f398 100644
|
||||
index b6e4a01ae450d..14b7fd84ed7df 100644
|
||||
--- chrome/browser/ui/views/page_action/page_action_icon_controller.cc
|
||||
+++ chrome/browser/ui/views/page_action/page_action_icon_controller.cc
|
||||
@@ -98,6 +98,12 @@ void PageActionIconController::Init(const PageActionIconParams& params,
|
||||
@ -894,7 +895,7 @@ index 0e24efef68ace..f1cda2809f398 100644
|
||||
case PageActionIconType::kPaymentsOfferNotification:
|
||||
add_page_action_icon(
|
||||
diff --git chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc
|
||||
index 9536b049aeb9d..30f3091939675 100644
|
||||
index c592f23b0c972..adca2e8db1cc6 100644
|
||||
--- chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc
|
||||
+++ chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc
|
||||
@@ -558,29 +558,41 @@ gfx::Range BrowserTabStripController::ListTabsInGroup(
|
||||
@ -932,18 +933,18 @@ index 9536b049aeb9d..30f3091939675 100644
|
||||
return GetFrameView()->GetFrameColor(active_state);
|
||||
}
|
||||
|
||||
absl::optional<int> BrowserTabStripController::GetCustomBackgroundId(
|
||||
std::optional<int> BrowserTabStripController::GetCustomBackgroundId(
|
||||
BrowserFrameActiveState active_state) const {
|
||||
+ if (!GetFrameView())
|
||||
+ return absl::nullopt;
|
||||
+ return std::nullopt;
|
||||
return GetFrameView()->GetCustomBackgroundId(active_state);
|
||||
}
|
||||
|
||||
diff --git chrome/browser/ui/views/toolbar/toolbar_view.cc chrome/browser/ui/views/toolbar/toolbar_view.cc
|
||||
index f7f763cac17f4..788185cc57cae 100644
|
||||
index 0cf2fbd962501..ccdc0a92ccde1 100644
|
||||
--- chrome/browser/ui/views/toolbar/toolbar_view.cc
|
||||
+++ chrome/browser/ui/views/toolbar/toolbar_view.cc
|
||||
@@ -190,7 +190,7 @@ class TabstripLikeBackground : public views::Background {
|
||||
@@ -191,7 +191,7 @@ class TabstripLikeBackground : public views::Background {
|
||||
void Paint(gfx::Canvas* canvas, views::View* view) const override {
|
||||
bool painted = TopContainerBackground::PaintThemeCustomImage(canvas, view,
|
||||
browser_view_);
|
||||
@ -952,7 +953,7 @@ index f7f763cac17f4..788185cc57cae 100644
|
||||
SkColor frame_color =
|
||||
browser_view_->frame()->GetFrameView()->GetFrameColor(
|
||||
BrowserFrameActiveState::kUseCurrent);
|
||||
@@ -219,12 +219,13 @@ END_METADATA
|
||||
@@ -220,12 +220,13 @@ END_METADATA
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// ToolbarView, public:
|
||||
|
||||
@ -968,7 +969,7 @@ index f7f763cac17f4..788185cc57cae 100644
|
||||
SetID(VIEW_ID_TOOLBAR);
|
||||
|
||||
container_view_ = AddChildView(std::make_unique<ContainerView>());
|
||||
@@ -249,6 +250,19 @@ ToolbarView::~ToolbarView() {
|
||||
@@ -250,6 +251,19 @@ ToolbarView::~ToolbarView() {
|
||||
}
|
||||
|
||||
void ToolbarView::Init() {
|
||||
@ -988,7 +989,7 @@ index f7f763cac17f4..788185cc57cae 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
|
||||
@@ -273,12 +287,12 @@ void ToolbarView::Init() {
|
||||
@@ -274,12 +288,12 @@ void ToolbarView::Init() {
|
||||
|
||||
auto location_bar = std::make_unique<LocationBarView>(
|
||||
browser_, browser_->profile(), browser_->command_controller(), this,
|
||||
@ -1003,7 +1004,7 @@ index f7f763cac17f4..788185cc57cae 100644
|
||||
download_button =
|
||||
std::make_unique<DownloadToolbarButtonView>(browser_view_);
|
||||
}
|
||||
@@ -360,8 +374,10 @@ void ToolbarView::Init() {
|
||||
@@ -361,8 +375,10 @@ void ToolbarView::Init() {
|
||||
}
|
||||
}
|
||||
std::unique_ptr<media_router::CastToolbarButton> cast;
|
||||
@ -1015,7 +1016,7 @@ index f7f763cac17f4..788185cc57cae 100644
|
||||
|
||||
std::unique_ptr<MediaToolbarButtonView> media_button;
|
||||
if (base::FeatureList::IsEnabled(media::kGlobalMediaControls)) {
|
||||
@@ -371,7 +387,8 @@ void ToolbarView::Init() {
|
||||
@@ -372,7 +388,8 @@ void ToolbarView::Init() {
|
||||
|
||||
std::unique_ptr<send_tab_to_self::SendTabToSelfToolbarIconView>
|
||||
send_tab_to_self_button;
|
||||
@ -1025,21 +1026,20 @@ index f7f763cac17f4..788185cc57cae 100644
|
||||
send_tab_to_self_button =
|
||||
std::make_unique<send_tab_to_self::SendTabToSelfToolbarIconView>(
|
||||
browser_view_);
|
||||
@@ -443,7 +460,8 @@ void ToolbarView::Init() {
|
||||
@@ -451,7 +468,7 @@ void ToolbarView::Init() {
|
||||
send_tab_to_self_button_ =
|
||||
container_view_->AddChildView(std::move(send_tab_to_self_button));
|
||||
|
||||
- if (!base::FeatureList::IsEnabled(features::kSidePanelPinning)) {
|
||||
+ if (!base::FeatureList::IsEnabled(features::kSidePanelPinning) &&
|
||||
+ BUTTON_VISIBLE(kSidePanel)) {
|
||||
- if (!features::IsSidePanelPinningEnabled()) {
|
||||
+ if (!features::IsSidePanelPinningEnabled() && BUTTON_VISIBLE(kSidePanel)) {
|
||||
if (companion::IsCompanionFeatureEnabled()) {
|
||||
side_panel_container_ = container_view_->AddChildView(
|
||||
std::make_unique<SidePanelToolbarContainer>(browser_view_));
|
||||
diff --git chrome/browser/ui/views/toolbar/toolbar_view.h chrome/browser/ui/views/toolbar/toolbar_view.h
|
||||
index 3bfe52cff3511..11373de4c2a3a 100644
|
||||
index ec3e34a86f4c5..c10866a7b1ace 100644
|
||||
--- chrome/browser/ui/views/toolbar/toolbar_view.h
|
||||
+++ chrome/browser/ui/views/toolbar/toolbar_view.h
|
||||
@@ -92,7 +92,8 @@ class ToolbarView : public views::AccessiblePaneView,
|
||||
@@ -93,7 +93,8 @@ class ToolbarView : public views::AccessiblePaneView,
|
||||
// needs to be displayed.
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user