From 4a5c3740848c7c4241733768e69e9b3b82cc471d Mon Sep 17 00:00:00 2001 From: Timothy Flynn Date: Thu, 11 Sep 2025 07:45:57 -0400 Subject: [PATCH] UI/Qt: Place the "reset zoom" button to the left of the hamburger menu It feels a bit awkward having this button displace the menu. --- UI/Qt/Tab.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/UI/Qt/Tab.cpp b/UI/Qt/Tab.cpp index 9607ad18d5c..abf0668b134 100644 --- a/UI/Qt/Tab.cpp +++ b/UI/Qt/Tab.cpp @@ -99,9 +99,11 @@ Tab::Tab(BrowserWindow* window, RefPtr parent_client, m_toolbar->addAction(m_navigate_forward_action); m_toolbar->addAction(m_reload_action); m_toolbar->addWidget(m_location_edit); - m_toolbar->setSizePolicy(QSizePolicy::MinimumExpanding, QSizePolicy::Fixed); + m_toolbar->addAction(create_application_action(*m_toolbar, view().reset_zoom_action())); m_hamburger_button_action = m_toolbar->addWidget(m_hamburger_button); + m_toolbar->setIconSize({ 16, 16 }); + m_toolbar->setSizePolicy(QSizePolicy::MinimumExpanding, QSizePolicy::Fixed); // This is a little awkward, but without this Qt shrinks the button to the size of the icon. // Note: toolButtonStyle="0" -> ToolButtonIconOnly. m_toolbar->setStyleSheet("QToolButton[toolButtonStyle=\"0\"]{width:24px;height:24px}"); @@ -112,8 +114,6 @@ Tab::Tab(BrowserWindow* window, RefPtr parent_client, m_hamburger_button_action->setVisible(!show_menubar); }); - m_toolbar->addAction(create_application_action(*m_toolbar, view().reset_zoom_action())); - view().on_activate_tab = [this] { m_window->activate_tab(tab_index()); };