mirror of
https://github.com/morgan9e/helium
synced 2026-04-15 00:44:06 +09:00
helium/cat: make common icons always stay unburgered
This commit is contained in:
@@ -163,7 +163,24 @@
|
||||
show_avatar_button_.Init(
|
||||
prefs::kShowAvatarButton, prefs,
|
||||
base::BindRepeating(&ToolbarView::OnShowAvatarButtonChanged,
|
||||
@@ -700,6 +723,24 @@ bool ToolbarView::IsRectInWindowCaption(
|
||||
@@ -564,10 +587,16 @@ void ToolbarView::Init() {
|
||||
|
||||
InitLayout();
|
||||
|
||||
+
|
||||
+ auto flex_preferred = views::FlexSpecification(
|
||||
+ views::MinimumFlexSizeRule::kPreferred,
|
||||
+ views::MaximumFlexSizeRule::kPreferred);
|
||||
+
|
||||
for (auto* button : std::array<views::Button*, 5>{back_, forward_, reload_,
|
||||
home_, avatar_}) {
|
||||
if (button) {
|
||||
button->set_tag(GetViewCommandMap().at(button->GetID()));
|
||||
+ button->SetProperty(views::kFlexBehaviorKey, flex_preferred);
|
||||
}
|
||||
}
|
||||
if (browser_view_->GetSupportsTabStrip()) {
|
||||
@@ -700,6 +729,24 @@ bool ToolbarView::IsRectInWindowCaption(
|
||||
return gfx::ToEnclosingRect(rect_in_target_coords_f);
|
||||
};
|
||||
|
||||
@@ -188,7 +205,7 @@
|
||||
// Check each child view in container_view_ to see if the rect intersects with
|
||||
// any clickable elements. If it does, check if the click is actually on that
|
||||
// element. False if on a clickable element, true if not on a clickable element.
|
||||
@@ -998,6 +1039,12 @@ void ToolbarView::InitLayout() {
|
||||
@@ -998,6 +1045,12 @@ void ToolbarView::InitLayout() {
|
||||
location_bar_->SetProperty(views::kMarginsKey,
|
||||
gfx::Insets::VH(0, location_bar_margin));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user