mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Update to Chromium version 92.0.4515.0 (#885287)
This commit is contained in:
@ -1,8 +1,8 @@
|
||||
diff --git chrome/browser/ui/browser_command_controller.cc chrome/browser/ui/browser_command_controller.cc
|
||||
index b0bde494f7b6f..19b11ac5766d0 100644
|
||||
index cfefe1f227283..402d848368269 100644
|
||||
--- chrome/browser/ui/browser_command_controller.cc
|
||||
+++ chrome/browser/ui/browser_command_controller.cc
|
||||
@@ -354,8 +354,10 @@ bool BrowserCommandController::ExecuteCommandWithDisposition(
|
||||
@@ -351,8 +351,10 @@ bool BrowserCommandController::ExecuteCommandWithDisposition(
|
||||
// CommandUpdaterDelegate and CommandUpdater declare this function so we
|
||||
// choose to not implement CommandUpdaterDelegate inside this class and
|
||||
// therefore command_updater_ doesn't have the delegate set).
|
||||
@ -14,7 +14,7 @@ index b0bde494f7b6f..19b11ac5766d0 100644
|
||||
|
||||
// No commands are enabled if there is not yet any selected tab.
|
||||
// TODO(pkasting): It seems like we should not need this, because either
|
||||
@@ -952,11 +954,13 @@ void BrowserCommandController::TabRestoreServiceLoaded(
|
||||
@@ -942,11 +944,13 @@ void BrowserCommandController::TabRestoreServiceLoaded(
|
||||
// BrowserCommandController, private:
|
||||
|
||||
bool BrowserCommandController::IsShowingMainUI() {
|
||||
@ -31,10 +31,10 @@ index b0bde494f7b6f..19b11ac5766d0 100644
|
||||
|
||||
void BrowserCommandController::InitCommandState() {
|
||||
diff --git chrome/browser/ui/views/frame/browser_frame.cc chrome/browser/ui/views/frame/browser_frame.cc
|
||||
index 5aff6e51d2186..55a95564fb826 100644
|
||||
index 3fca382fde67e..6adddf506bb16 100644
|
||||
--- chrome/browser/ui/views/frame/browser_frame.cc
|
||||
+++ chrome/browser/ui/views/frame/browser_frame.cc
|
||||
@@ -65,15 +65,23 @@ bool IsUsingGtkTheme(Profile* profile) {
|
||||
@@ -69,15 +69,23 @@ bool IsUsingGtkTheme(Profile* profile) {
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// BrowserFrame, public:
|
||||
|
||||
@ -60,7 +60,7 @@ index 5aff6e51d2186..55a95564fb826 100644
|
||||
}
|
||||
|
||||
BrowserFrame::~BrowserFrame() {}
|
||||
@@ -132,6 +140,12 @@ gfx::Rect BrowserFrame::GetBoundsForTabStripRegion(
|
||||
@@ -137,6 +145,12 @@ gfx::Rect BrowserFrame::GetBoundsForTabStripRegion(
|
||||
}
|
||||
|
||||
int BrowserFrame::GetTopInset() const {
|
||||
@ -73,7 +73,7 @@ index 5aff6e51d2186..55a95564fb826 100644
|
||||
return browser_frame_view_->GetTopInset(false);
|
||||
}
|
||||
|
||||
@@ -166,15 +180,21 @@ void BrowserFrame::GetWindowPlacement(gfx::Rect* bounds,
|
||||
@@ -171,15 +185,21 @@ void BrowserFrame::GetWindowPlacement(gfx::Rect* bounds,
|
||||
|
||||
content::KeyboardEventProcessingResult BrowserFrame::PreHandleKeyboardEvent(
|
||||
const content::NativeWebKeyboardEvent& event) {
|
||||
@ -95,21 +95,21 @@ index 5aff6e51d2186..55a95564fb826 100644
|
||||
browser_frame_view_->OnBrowserViewInitViewsComplete();
|
||||
}
|
||||
|
||||
@@ -207,7 +227,8 @@ const ui::ThemeProvider* BrowserFrame::GetThemeProvider() const {
|
||||
}
|
||||
@@ -341,7 +361,8 @@ void BrowserFrame::SelectNativeTheme() {
|
||||
// Select between regular, dark and GTK theme.
|
||||
ui::NativeTheme* native_theme = ui::NativeTheme::GetInstanceForNativeUi();
|
||||
|
||||
const ui::NativeTheme* BrowserFrame::GetNativeTheme() const {
|
||||
- if (browser_view_->browser()->profile()->IsIncognitoProfile() &&
|
||||
- if (browser_view_->browser()->profile()->IsIncognitoProfile()) {
|
||||
+ if (browser_view_ &&
|
||||
+ browser_view_->browser()->profile()->IsIncognitoProfile() &&
|
||||
ThemeServiceFactory::GetForProfile(browser_view_->browser()->profile())
|
||||
->UsingDefaultTheme()) {
|
||||
return ui::NativeTheme::GetInstanceForDarkUI();
|
||||
+ browser_view_->browser()->profile()->IsIncognitoProfile()) {
|
||||
// If the flag is enabled, then no matter if we are using the default theme
|
||||
// or not we always use the dark ui instance.
|
||||
if (base::FeatureList::IsEnabled(
|
||||
diff --git chrome/browser/ui/views/frame/browser_frame.h chrome/browser/ui/views/frame/browser_frame.h
|
||||
index 050c0e05e4e3b..0bbcf4af9a92a 100644
|
||||
index 0ce7abdeb7d9f..8197a6bb7da98 100644
|
||||
--- chrome/browser/ui/views/frame/browser_frame.h
|
||||
+++ chrome/browser/ui/views/frame/browser_frame.h
|
||||
@@ -53,7 +53,9 @@ enum class TabDragKind {
|
||||
@@ -54,7 +54,9 @@ enum class TabDragKind {
|
||||
// This is a virtual interface that allows system specific browser frames.
|
||||
class BrowserFrame : public views::Widget, public views::ContextMenuController {
|
||||
public:
|
||||
@ -120,10 +120,10 @@ index 050c0e05e4e3b..0bbcf4af9a92a 100644
|
||||
|
||||
// Initialize the frame (creates the underlying native window).
|
||||
diff --git chrome/browser/ui/views/frame/browser_view.cc chrome/browser/ui/views/frame/browser_view.cc
|
||||
index 7fc9e5493ca49..9cb598b648194 100644
|
||||
index e852eb7d20ed6..bb73d3055936d 100644
|
||||
--- chrome/browser/ui/views/frame/browser_view.cc
|
||||
+++ chrome/browser/ui/views/frame/browser_view.cc
|
||||
@@ -576,11 +576,22 @@ class BrowserView::AccessibilityModeObserver : public ui::AXModeObserver {
|
||||
@@ -586,11 +586,22 @@ class BrowserView::AccessibilityModeObserver : public ui::AXModeObserver {
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
// BrowserView, public:
|
||||
|
||||
@ -147,7 +147,7 @@ index 7fc9e5493ca49..9cb598b648194 100644
|
||||
SetShowIcon(::ShouldShowWindowIcon(browser_.get()));
|
||||
|
||||
// In forced app mode, all size controls are always disabled. Otherwise, use
|
||||
@@ -594,7 +605,6 @@ BrowserView::BrowserView(std::unique_ptr<Browser> browser)
|
||||
@@ -604,7 +615,6 @@ BrowserView::BrowserView(std::unique_ptr<Browser> browser)
|
||||
}
|
||||
|
||||
browser_->tab_strip_model()->AddObserver(this);
|
||||
@ -155,7 +155,7 @@ index 7fc9e5493ca49..9cb598b648194 100644
|
||||
|
||||
// Top container holds tab strip region and toolbar and lives at the front of
|
||||
// the view hierarchy.
|
||||
@@ -638,8 +648,15 @@ BrowserView::BrowserView(std::unique_ptr<Browser> browser)
|
||||
@@ -648,8 +658,15 @@ BrowserView::BrowserView(std::unique_ptr<Browser> browser)
|
||||
contents_container->SetLayoutManager(std::make_unique<ContentsLayoutManager>(
|
||||
devtools_web_view_, contents_web_view_));
|
||||
|
||||
@ -173,7 +173,7 @@ index 7fc9e5493ca49..9cb598b648194 100644
|
||||
|
||||
contents_separator_ =
|
||||
top_container_->AddChildView(std::make_unique<ContentsSeparator>());
|
||||
@@ -1407,6 +1424,8 @@ bool BrowserView::ShouldHideUIForFullscreen() const {
|
||||
@@ -1430,6 +1447,8 @@ bool BrowserView::ShouldHideUIForFullscreen() const {
|
||||
if (immersive_mode_controller_->IsEnabled())
|
||||
return false;
|
||||
|
||||
@ -182,7 +182,7 @@ index 7fc9e5493ca49..9cb598b648194 100644
|
||||
return frame_->GetFrameView()->ShouldHideTopUIForFullscreen();
|
||||
}
|
||||
|
||||
@@ -2427,7 +2446,8 @@ BrowserView::GetNativeViewHostsForTopControlsSlide() const {
|
||||
@@ -2423,7 +2442,8 @@ BrowserView::GetNativeViewHostsForTopControlsSlide() const {
|
||||
}
|
||||
|
||||
void BrowserView::ReparentTopContainerForEndOfImmersive() {
|
||||
@ -192,7 +192,7 @@ index 7fc9e5493ca49..9cb598b648194 100644
|
||||
top_container()->DestroyLayer();
|
||||
AddChildViewAt(top_container(), 0);
|
||||
EnsureFocusOrder();
|
||||
@@ -2889,8 +2909,10 @@ void BrowserView::Layout() {
|
||||
@@ -2878,8 +2898,10 @@ void BrowserView::Layout() {
|
||||
|
||||
// TODO(jamescook): Why was this in the middle of layout code?
|
||||
toolbar_->location_bar()->omnibox_view()->SetFocusBehavior(
|
||||
@ -205,7 +205,7 @@ index 7fc9e5493ca49..9cb598b648194 100644
|
||||
|
||||
// Some of the situations when the BrowserView is laid out are:
|
||||
// - Enter/exit immersive fullscreen mode.
|
||||
@@ -2947,6 +2969,11 @@ void BrowserView::AddedToWidget() {
|
||||
@@ -2942,6 +2964,11 @@ void BrowserView::AddedToWidget() {
|
||||
SetThemeProfileForWindow(GetNativeWindow(), browser_->profile());
|
||||
#endif
|
||||
|
||||
@ -217,7 +217,7 @@ index 7fc9e5493ca49..9cb598b648194 100644
|
||||
toolbar_->Init();
|
||||
|
||||
#if BUILDFLAG(IS_CHROMEOS_ASH) || BUILDFLAG(IS_CHROMEOS_LACROS)
|
||||
@@ -2987,13 +3014,9 @@ void BrowserView::AddedToWidget() {
|
||||
@@ -2977,13 +3004,9 @@ void BrowserView::AddedToWidget() {
|
||||
|
||||
EnsureFocusOrder();
|
||||
|
||||
@ -234,10 +234,10 @@ index 7fc9e5493ca49..9cb598b648194 100644
|
||||
|
||||
MaybeInitializeWebUITabStrip();
|
||||
diff --git chrome/browser/ui/views/frame/browser_view.h chrome/browser/ui/views/frame/browser_view.h
|
||||
index 59ddc0ac10f94..d5f04bfd7ca5f 100644
|
||||
index f6db8a6928831..a5302d7f73ba6 100644
|
||||
--- chrome/browser/ui/views/frame/browser_view.h
|
||||
+++ chrome/browser/ui/views/frame/browser_view.h
|
||||
@@ -112,7 +112,9 @@ class BrowserView : public BrowserWindow,
|
||||
@@ -114,7 +114,9 @@ class BrowserView : public BrowserWindow,
|
||||
public webapps::AppBannerManager::Observer {
|
||||
public:
|
||||
METADATA_HEADER(BrowserView);
|
||||
@ -247,7 +247,7 @@ index 59ddc0ac10f94..d5f04bfd7ca5f 100644
|
||||
BrowserView(const BrowserView&) = delete;
|
||||
BrowserView& operator=(const BrowserView&) = delete;
|
||||
~BrowserView() override;
|
||||
@@ -624,6 +626,12 @@ class BrowserView : public BrowserWindow,
|
||||
@@ -642,6 +644,12 @@ class BrowserView : public BrowserWindow,
|
||||
return accessibility_focus_highlight_.get();
|
||||
}
|
||||
|
||||
@ -261,10 +261,10 @@ index 59ddc0ac10f94..d5f04bfd7ca5f 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 56ef53cf379d9..f0f1057896bdb 100644
|
||||
index 0e810789a99d7..14d69bd755fa2 100644
|
||||
--- chrome/browser/ui/views/frame/browser_view_layout.cc
|
||||
+++ chrome/browser/ui/views/frame/browser_view_layout.cc
|
||||
@@ -415,6 +415,12 @@ int BrowserViewLayout::LayoutWebUITabStrip(int top) {
|
||||
@@ -420,6 +420,12 @@ int BrowserViewLayout::LayoutWebUITabStrip(int top) {
|
||||
|
||||
int BrowserViewLayout::LayoutToolbar(int top) {
|
||||
TRACE_EVENT0("ui", "BrowserViewLayout::LayoutToolbar");
|
||||
@ -278,10 +278,10 @@ index 56ef53cf379d9..f0f1057896bdb 100644
|
||||
bool toolbar_visible = delegate_->IsToolbarVisible();
|
||||
int height = toolbar_visible ? toolbar_->GetPreferredSize().height() : 0;
|
||||
diff --git chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc
|
||||
index 9220245ea195d..90dd93503b570 100644
|
||||
index 50c10d73b9102..46f375b11d82c 100644
|
||||
--- chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc
|
||||
+++ chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc
|
||||
@@ -571,37 +571,53 @@ gfx::Range BrowserTabStripController::ListTabsInGroup(
|
||||
@@ -582,37 +582,53 @@ gfx::Range BrowserTabStripController::ListTabsInGroup(
|
||||
}
|
||||
|
||||
bool BrowserTabStripController::IsFrameCondensed() const {
|
||||
@ -328,18 +328,18 @@ index 9220245ea195d..90dd93503b570 100644
|
||||
return GetFrameView()->GetToolbarTopSeparatorColor();
|
||||
}
|
||||
|
||||
base::Optional<int> BrowserTabStripController::GetCustomBackgroundId(
|
||||
absl::optional<int> BrowserTabStripController::GetCustomBackgroundId(
|
||||
BrowserFrameActiveState active_state) const {
|
||||
+ if (!GetFrameView())
|
||||
+ return base::nullopt;
|
||||
+ return absl::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 5f6e182d017d9..be85e6df707d1 100644
|
||||
index 650fb98f63b0b..fd3d28bd70aac 100644
|
||||
--- chrome/browser/ui/views/toolbar/toolbar_view.cc
|
||||
+++ chrome/browser/ui/views/toolbar/toolbar_view.cc
|
||||
@@ -156,12 +156,13 @@ auto& GetViewCommandMap() {
|
||||
@@ -160,12 +160,13 @@ auto& GetViewCommandMap() {
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// ToolbarView, public:
|
||||
|
||||
@ -355,7 +355,7 @@ index 5f6e182d017d9..be85e6df707d1 100644
|
||||
SetID(VIEW_ID_TOOLBAR);
|
||||
|
||||
UpgradeDetector::GetInstance()->AddObserver(this);
|
||||
@@ -194,7 +195,7 @@ void ToolbarView::Init() {
|
||||
@@ -198,7 +199,7 @@ void ToolbarView::Init() {
|
||||
#endif
|
||||
auto location_bar = std::make_unique<LocationBarView>(
|
||||
browser_, browser_->profile(), browser_->command_controller(), this,
|
||||
@ -365,10 +365,10 @@ index 5f6e182d017d9..be85e6df707d1 100644
|
||||
size_animation_.Reset(1);
|
||||
|
||||
diff --git chrome/browser/ui/views/toolbar/toolbar_view.h chrome/browser/ui/views/toolbar/toolbar_view.h
|
||||
index 99358217419a6..425a0741b55a3 100644
|
||||
index c232c1c703500..d3b1593be5496 100644
|
||||
--- chrome/browser/ui/views/toolbar/toolbar_view.h
|
||||
+++ chrome/browser/ui/views/toolbar/toolbar_view.h
|
||||
@@ -87,7 +87,8 @@ class ToolbarView : public views::AccessiblePaneView,
|
||||
@@ -91,7 +91,8 @@ class ToolbarView : public views::AccessiblePaneView,
|
||||
// needs to be displayed.
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user