helium/ui: merge two caption button bounds patches

and remove the windows (os) workaround cuz the new layout doesn't use it
This commit is contained in:
wukko
2025-12-03 20:19:01 +06:00
parent 1d218c894b
commit 3175ba89bd
3 changed files with 12 additions and 31 deletions

View File

@@ -1,3 +1,14 @@
--- a/chrome/browser/ui/views/frame/layout/browser_view_layout_delegate_impl.cc
+++ b/chrome/browser/ui/views/frame/layout/browser_view_layout_delegate_impl.cc
@@ -258,7 +258,7 @@ BrowserViewLayoutDelegateImpl::GetBounds
layout.trailing_exclusion.vertical_padding);
bounds_f.set_height(
std::max(max_bound, static_cast<float>(tabstrip_minimum_size.height())));
- const int tab_margin = TabStyle::Get()->GetBottomCornerRadius();
+ const int tab_margin = TabStyle::Get()->GetBottomCornerRadius() / 2;
bounds_f.Inset(gfx::InsetsF::TLBR(
0.0f,
layout.leading_exclusion.content.width() +
--- a/components/remote_cocoa/app_shim/browser_native_widget_window_mac.mm
+++ b/components/remote_cocoa/app_shim/browser_native_widget_window_mac.mm
@@ -63,13 +63,10 @@ const double kThinControllerHeight = 0.5

View File

@@ -1,29 +0,0 @@
--- a/chrome/browser/ui/views/frame/layout/browser_view_layout_delegate_impl.cc
+++ b/chrome/browser/ui/views/frame/layout/browser_view_layout_delegate_impl.cc
@@ -258,7 +258,7 @@ BrowserViewLayoutDelegateImpl::GetBounds
layout.trailing_exclusion.vertical_padding);
bounds_f.set_height(
std::max(max_bound, static_cast<float>(tabstrip_minimum_size.height())));
- const int tab_margin = TabStyle::Get()->GetBottomCornerRadius();
+ const int tab_margin = TabStyle::Get()->GetBottomCornerRadius() / 2;
bounds_f.Inset(gfx::InsetsF::TLBR(
0.0f,
layout.leading_exclusion.content.width() +
--- a/chrome/browser/ui/views/frame/browser_frame_view_win.cc
+++ b/chrome/browser/ui/views/frame/browser_frame_view_win.cc
@@ -258,10 +258,13 @@ bool BrowserFrameViewWin::CaptionButtons
gfx::Rect BrowserFrameViewWin::GetBoundsForTabStripRegion(
const gfx::Size& tabstrip_minimum_size) const {
- const int x = CaptionButtonsOnLeadingEdge() ? CaptionButtonsRegionWidth() : 0;
+ const int x = CaptionButtonsOnLeadingEdge() ?
+ CaptionButtonsRegionWidth() :
+ GetLayoutConstant(TOOLBAR_CORNER_RADIUS);
int end_x = width();
if (!CaptionButtonsOnLeadingEdge()) {
- end_x = std::min(width() - CaptionButtonsRegionWidth(), end_x);
+ end_x = std::min(width() - CaptionButtonsRegionWidth() -
+ GetLayoutConstant(TOOLBAR_CORNER_RADIUS), end_x);
}
return gfx::Rect(x, TopAreaHeight(false), std::max(0, end_x - x),
tabstrip_minimum_size.height());

View File

@@ -265,8 +265,7 @@ helium/ui/improve-flags-webui.patch
helium/ui/ublock-show-in-settings.patch
helium/ui/licenses-in-credits.patch
helium/ui/remove-autofill-link-to-password-manager.patch
helium/ui/fix-caption-button-tab-strip-align.patch
helium/ui/fix-caption-bounds.patch
helium/ui/fix-caption-button-bounds.patch
helium/ui/find-bar.patch
helium/ui/remove-zoom-action.patch
helium/ui/experiments/compact-action-toolbar.patch